Rocksolid Light

Welcome to RetroBBS

mail  files  register  newsreader  groups  login

Message-ID:  

Successful and fortunate crime is called virtue. -- Seneca


devel / comp.lang.tcl / Re: How to feed special keys to text widget programmatically?

SubjectAuthor
* How to feed special keys to text widget programmatically?Helmut Giese
+* Re: How to feed special keys to text widget programmatically?Robert Heller
|`* Re: How to feed special keys to text widget programmatically?Gerald Lester
| `- Re: How to feed special keys to text widget programmatically?Helmut Giese
`* Re: How to feed special keys to text widget programmatically?Rich
 `- Re: How to feed special keys to text widget programmatically?Helmut Giese

1
How to feed special keys to text widget programmatically?

<ic9c9h9f4n19vb5e743695pf09e8m1mklb@4ax.com>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=19430&group=comp.lang.tcl#19430

  copy link   Newsgroups: comp.lang.tcl
Path: i2pn2.org!rocksolid2!i2pn.org!eternal-september.org!reader02.eternal-september.org!.POSTED!not-for-mail
From: hgiese@ratiosoft.com (Helmut Giese)
Newsgroups: comp.lang.tcl
Subject: How to feed special keys to text widget programmatically?
Date: Tue, 31 May 2022 16:31:55 +0200
Organization: ratiosoft
Lines: 7
Message-ID: <ic9c9h9f4n19vb5e743695pf09e8m1mklb@4ax.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Injection-Info: reader02.eternal-september.org; posting-host="ff6abadadc9502505c497efb1165b287";
logging-data="19506"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX180q9iyJ3KSfhphSKXK9VXk"
Cancel-Lock: sha1:0ExU/3D86tTeOO7aIhTd+uefPzE=
X-Newsreader: Forte Free Agent 1.93/32.576 English (American)
 by: Helmut Giese - Tue, 31 May 2022 14:31 UTC

Hello out there,
I am writing a test program for a text widget and came across the
problem to test its behaviour wrt special keys (ctrl, up, down, etc.).
I have no idea how to feed those into my widget.
Any help or advice will be greatly appreciated.
Best regards
Helmut

Re: How to feed special keys to text widget programmatically?

<n-mdnQtIhM1hpwv_nZ2dnUU7-avNnZ2d@giganews.com>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=19431&group=comp.lang.tcl#19431

  copy link   Newsgroups: comp.lang.tcl
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!news.misty.com!border2.nntp.dca1.giganews.com!nntp.giganews.com!buffer2.nntp.dca1.giganews.com!news.giganews.com.POSTED!not-for-mail
NNTP-Posting-Date: Tue, 31 May 2022 10:57:48 -0500
MIME-Version: 1.0
From: heller@deepsoft.com (Robert Heller)
Organization: Deepwoods Software
X-Newsreader: TkNews 3.0 (1.2.12)
Subject: Re: How to feed special keys to text widget programmatically?
In-Reply-To: <ic9c9h9f4n19vb5e743695pf09e8m1mklb@4ax.com>
References: <ic9c9h9f4n19vb5e743695pf09e8m1mklb@4ax.com>
Newsgroups: comp.lang.tcl
Content-Type: text/plain;
charset="us-ascii"
Originator: heller@sharky4.deepsoft.com
Message-ID: <n-mdnQtIhM1hpwv_nZ2dnUU7-avNnZ2d@giganews.com>
Date: Tue, 31 May 2022 10:57:48 -0500
Lines: 30
X-Usenet-Provider: http://www.giganews.com
X-Trace: sv3-zF6+usSSv4DrM7ldHLobndxN6R34Z8QxaaMUFc0fqNTZ+2gpOv0AJ7jh5YeR7sKzXeu/Ng9x27eWTcm!dTYXJUDAQHapy8A1mM4XSFOKKTT70+NOODh1gyXCWz3SnNHQ759dzl52aLGy3PEeGiBDERs2vUvT!hDA=
X-Complaints-To: abuse@giganews.com
X-DMCA-Notifications: http://www.giganews.com/info/dmca.html
X-Abuse-and-DMCA-Info: Please be sure to forward a copy of ALL headers
X-Abuse-and-DMCA-Info: Otherwise we will be unable to process your complaint properly
X-Postfilter: 1.3.40
X-Original-Bytes: 2484
 by: Robert Heller - Tue, 31 May 2022 15:57 UTC

What do you mean by feed?

The keys you list (ctrl, up, down) are either modifiers or else have special
bindings (eg movement). The Control modifier key when applied to regular keys
has special bindings (like movement or some other function, like Copy or
Paste). What exactly are you trying to test?

There is a file in the Tk library (on my Ubuntu system is is in
/usr/share/tcltk/tk8.6/) named text.tcl which contains all of the default
bindings for the text widget, along with the helper functions that they use.

At Tue, 31 May 2022 16:31:55 +0200 Helmut Giese <hgiese@ratiosoft.com> wrote:

>
> Hello out there,
> I am writing a test program for a text widget and came across the
> problem to test its behaviour wrt special keys (ctrl, up, down, etc.).
> I have no idea how to feed those into my widget.
> Any help or advice will be greatly appreciated.
> Best regards
> Helmut
>
>

--
Robert Heller -- Cell: 413-658-7953 GV: 978-633-5364
Deepwoods Software -- Custom Software Services
http://www.deepsoft.com/ -- Linux Administration Services
heller@deepsoft.com -- Webhosting Services

Re: How to feed special keys to text widget programmatically?

<t75fpi$ae2$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=19432&group=comp.lang.tcl#19432

  copy link   Newsgroups: comp.lang.tcl
Path: i2pn2.org!i2pn.org!eternal-september.org!reader02.eternal-september.org!.POSTED!not-for-mail
From: rich@example.invalid (Rich)
Newsgroups: comp.lang.tcl
Subject: Re: How to feed special keys to text widget programmatically?
Date: Tue, 31 May 2022 16:29:38 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 9
Message-ID: <t75fpi$ae2$1@dont-email.me>
References: <ic9c9h9f4n19vb5e743695pf09e8m1mklb@4ax.com>
Injection-Date: Tue, 31 May 2022 16:29:38 -0000 (UTC)
Injection-Info: reader02.eternal-september.org; posting-host="72b671a62dd6038cf280bd29c70f0e36";
logging-data="10690"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+dp36F1hRytWx/KHUH/3bQ"
User-Agent: tin/2.0.1-20111224 ("Achenvoir") (UNIX) (Linux/3.10.17 (x86_64))
Cancel-Lock: sha1:p+7ntfkrmMnqQvxfgKqPTsYnv+Y=
 by: Rich - Tue, 31 May 2022 16:29 UTC

Helmut Giese <hgiese@ratiosoft.com> wrote:
> Hello out there,
> I am writing a test program for a text widget and came across the
> problem to test its behaviour wrt special keys (ctrl, up, down, etc.).
> I have no idea how to feed those into my widget.
> Any help or advice will be greatly appreciated.

Perhaps via "event generate"?

Re: How to feed special keys to text widget programmatically?

<t75iec$6sv$1@gioia.aioe.org>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=19435&group=comp.lang.tcl#19435

  copy link   Newsgroups: comp.lang.tcl
Path: i2pn2.org!i2pn.org!aioe.org!5uRJWBT0+b/8E5m0YLLMCQ.user.46.165.242.75.POSTED!not-for-mail
From: Gerald.Lester@KnG-Consulting.net (Gerald Lester)
Newsgroups: comp.lang.tcl
Subject: Re: How to feed special keys to text widget programmatically?
Date: Tue, 31 May 2022 12:14:52 -0500
Organization: KnG Consulting, LLC
Message-ID: <t75iec$6sv$1@gioia.aioe.org>
References: <ic9c9h9f4n19vb5e743695pf09e8m1mklb@4ax.com>
<n-mdnQtIhM1hpwv_nZ2dnUU7-avNnZ2d@giganews.com>
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Info: gioia.aioe.org; logging-data="7071"; posting-host="5uRJWBT0+b/8E5m0YLLMCQ.user.gioia.aioe.org"; mail-complaints-to="abuse@aioe.org";
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101
Thunderbird/91.8.1
X-Notice: Filtered by postfilter v. 0.9.2
Content-Language: en-US
 by: Gerald Lester - Tue, 31 May 2022 17:14 UTC

On 5/31/22 10:57, Robert Heller wrote:
> What do you mean by feed?

I think he is looking for the [event generate] command.

>
> The keys you list (ctrl, up, down) are either modifiers or else have special
> bindings (eg movement). The Control modifier key when applied to regular keys
> has special bindings (like movement or some other function, like Copy or
> Paste). What exactly are you trying to test?
>
> There is a file in the Tk library (on my Ubuntu system is is in
> /usr/share/tcltk/tk8.6/) named text.tcl which contains all of the default
> bindings for the text widget, along with the helper functions that they use.
>
> At Tue, 31 May 2022 16:31:55 +0200 Helmut Giese <hgiese@ratiosoft.com> wrote:
>
>>
>> Hello out there,
>> I am writing a test program for a text widget and came across the
>> problem to test its behaviour wrt special keys (ctrl, up, down, etc.).
>> I have no idea how to feed those into my widget.
>> Any help or advice will be greatly appreciated.
>> Best regards
>> Helmut
>>
>>
>

--
+----------------------------------------------------------------------+
| Gerald W. Lester, President, KNG Consulting LLC |
| Email: Gerald.Lester@kng-consulting.net |
+----------------------------------------------------------------------+

Re: How to feed special keys to text widget programmatically?

<atpc9hlaaeklttcdt6u2knj82jv5q3mq16@4ax.com>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=19439&group=comp.lang.tcl#19439

  copy link   Newsgroups: comp.lang.tcl
Path: i2pn2.org!i2pn.org!eternal-september.org!reader02.eternal-september.org!.POSTED!not-for-mail
From: hgiese@ratiosoft.com (Helmut Giese)
Newsgroups: comp.lang.tcl
Subject: Re: How to feed special keys to text widget programmatically?
Date: Tue, 31 May 2022 21:10:47 +0200
Organization: ratiosoft
Lines: 9
Message-ID: <atpc9hlaaeklttcdt6u2knj82jv5q3mq16@4ax.com>
References: <ic9c9h9f4n19vb5e743695pf09e8m1mklb@4ax.com> <n-mdnQtIhM1hpwv_nZ2dnUU7-avNnZ2d@giganews.com> <t75iec$6sv$1@gioia.aioe.org>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Injection-Info: reader02.eternal-september.org; posting-host="ff6abadadc9502505c497efb1165b287";
logging-data="22727"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18qYnrdO+Mk4pV0Zqs+c5kB"
Cancel-Lock: sha1:/8cjGnnP4sEDOZuS0I7WTBxeyCE=
X-Newsreader: Forte Free Agent 1.93/32.576 English (American)
 by: Helmut Giese - Tue, 31 May 2022 19:10 UTC

Gerald Lester <Gerald.Lester@KnG-Consulting.net> schrieb:

>On 5/31/22 10:57, Robert Heller wrote:
>> What do you mean by feed?
>
>I think he is looking for the [event generate] command.
>
but I didn't know it :)

Re: How to feed special keys to text widget programmatically?

<52qc9hh6am2l330qc0ieq3b5199e7o4rh4@4ax.com>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=19440&group=comp.lang.tcl#19440

  copy link   Newsgroups: comp.lang.tcl
Path: i2pn2.org!i2pn.org!eternal-september.org!reader02.eternal-september.org!.POSTED!not-for-mail
From: hgiese@ratiosoft.com (Helmut Giese)
Newsgroups: comp.lang.tcl
Subject: Re: How to feed special keys to text widget programmatically?
Date: Tue, 31 May 2022 21:16:01 +0200
Organization: ratiosoft
Lines: 18
Message-ID: <52qc9hh6am2l330qc0ieq3b5199e7o4rh4@4ax.com>
References: <ic9c9h9f4n19vb5e743695pf09e8m1mklb@4ax.com> <t75fpi$ae2$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Injection-Info: reader02.eternal-september.org; posting-host="ff6abadadc9502505c497efb1165b287";
logging-data="29268"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19G5ZGL5/z+InyeotRy62Iz"
Cancel-Lock: sha1:TDRVYdOsarApmmbcAP/DmoE5nOg=
X-Newsreader: Forte Free Agent 1.93/32.576 English (American)
 by: Helmut Giese - Tue, 31 May 2022 19:16 UTC

Rich <rich@example.invalid> schrieb:

>Helmut Giese <hgiese@ratiosoft.com> wrote:
>> Hello out there,
>> I am writing a test program for a text widget and came across the
>> problem to test its behaviour wrt special keys (ctrl, up, down, etc.).
>> I have no idea how to feed those into my widget.
>> Any help or advice will be greatly appreciated.
>
>Perhaps via "event generate"?

Hello Rich,
yes, this seems to make it. It is a bit unfortunate that (from the
manual): Certain events, such as key events, require that the window
has focus to receive the event properly.
But with a bit of juggling with 'after' I think I will get it to work.
Many thanks to all who responded.
Helmut


devel / comp.lang.tcl / Re: How to feed special keys to text widget programmatically?

1
server_pubkey.txt

rocksolid light 0.9.81
clearnet tor