Re: Control of Text Fields.

2021-11-10 Thread Richmond via use-livecode

It's a new one to me as well.

Richmond.

On 10.11.21 16:28, Alex Tweedly via use-livecode wrote:

"focusedObject" - wow, who knew ?  :-)

So it's been helpful for me.
(Some day I really will read the dictionary thoroughly).

Alex.

On 10/11/2021 03:38, Roger Guay via use-livecode wrote:

Alex and Richmond,

This discussion has been very helpful. Thank you! Please see my 
latest post on the forums where I offer my Formulator stack that 
seems to work, partly I think because I don’t lock the text of the 
multiple fields in my stack. Who woulda thunk?


https://forums.livecode.com/viewtopic.php?f=7=36444 



Cheers,

Roger


On Nov 7, 2021, at 5:51 PM, Alex Tweedly via use-livecode 
 wrote:



On 07/11/2021 11:36, Richmond via use-livecode wrote:

No hard feelings.

See what I have got up to over on the Forums, and

https://forums.livecode.com/viewtopic.php?f=7=36444

PLEASE, feel free to pull the thing to bits.

I don't want to "pull the thing to bits". Like you, I enjoy seeing 
"competing" multitude of ways to do things - I can learn from them all.


But I did have a quick look, so I'll just point out a small number 
of nitpicks.


1. the whole 'locktext' thing is weird, and causes various anomalies.
When I first open the stack, and click in the field, I can type 
digits and have them appear in the field, as you'd expect. But once 
I've clicked on an 'arrow-emulator' the field becomes locked and one 
can no longer type in characters. Clicking *outside* the field will 
then free it up again, so typing becomes possible.


2. disappearing iBeam.

If I position the ibeam in the middle of the text in the field, and 
use one of the arrow emulator buttons, the iBeam moves properly - 
but then disappears (perhaps when the 'locktext' is set true).


3. incorrect entry position.

As in 2 above, although the ibeam was last seen in the correct place 
after using the ">" button to move it to the right, if I then click 
on a digit button, that digit appears at the end of the field, not 
where it should have gone


4. Incorrect arrow key emulation (same problem as I mentioned in the 
previous email).


If you select a chunk of text in the field, then use the left-arrow 
emulator button, the ibeam is positioned before the *last* character 
of the selection, instead of before the first.



There were a couple of others, omitted for brevity. I've created a 
modified version your stack with my suggested handlers, and will 
attempt to upload it to the forum later.


Then there was another issue which I haven't tackled - it would mean 
changing lots of very similar tiny scripts, and is too tedious.


5. character input should replace any selection

Just like in a regular field, if there is an active selection, 
typing a character (or clicking a digit button, should *replace* it, 
not simply add the newly typed (or clicked) digit.



I've taken my earlier handler suggestion, and broken the bits of 
code out into individual button scripts, which removes the apparent 
complexity that you disliked earlier. As far as I know, no problems 
have yet been found with that approach. As one example, the code for 
left-arrow emulator would be



  on mouseUp
    focus on field "fWORK"
    put word 2 of the selectedchunk into tFirst
    put word 4 of the selectedchunk into tLast
    select before char (min(tFirst, tLast)) of fld "fWORK"
end mouseUp

I've uploaded this revised version on the forum thread.

Best wishes,  Alex



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your 
subscription preferences:

http://lists.runrev.com/mailman/listinfo/use-livecode

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your 
subscription preferences:

http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your 
subscription preferences:

http://lists.runrev.com/mailman/listinfo/use-livecode



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-10 Thread Alex Tweedly via use-livecode

"focusedObject" - wow, who knew ?  :-)

So it's been helpful for me.
(Some day I really will read the dictionary thoroughly).

Alex.

On 10/11/2021 03:38, Roger Guay via use-livecode wrote:

Alex and Richmond,

This discussion has been very helpful. Thank you! Please see my latest post on 
the forums where I offer my Formulator stack that seems to work, partly I think 
because I don’t lock the text of the multiple fields in my stack. Who woulda 
thunk?

https://forums.livecode.com/viewtopic.php?f=7=36444 


Cheers,

Roger



On Nov 7, 2021, at 5:51 PM, Alex Tweedly via use-livecode 
 wrote:


On 07/11/2021 11:36, Richmond via use-livecode wrote:

No hard feelings.

See what I have got up to over on the Forums, and

https://forums.livecode.com/viewtopic.php?f=7=36444

PLEASE, feel free to pull the thing to bits.


I don't want to "pull the thing to bits". Like you, I enjoy seeing "competing" 
multitude of ways to do things - I can learn from them all.

But I did have a quick look, so I'll just point out a small number of nitpicks.

1. the whole 'locktext' thing is weird, and causes various anomalies.
When I first open the stack, and click in the field, I can type digits and have 
them appear in the field, as you'd expect. But once I've clicked on an 
'arrow-emulator' the field becomes locked and one can no longer type in 
characters.  Clicking *outside* the field will then free it up again, so typing 
becomes possible.

2. disappearing iBeam.

If I position the ibeam in the middle of the text in the field, and use one of 
the arrow emulator buttons, the iBeam  moves properly - but then disappears 
(perhaps when the 'locktext' is set true).

3. incorrect entry position.

As in 2 above, although the ibeam was last seen in the correct place after using the 
">" button to move it to the right, if I then click on a digit button, that 
digit appears at the end of the field, not where it should have gone

4. Incorrect arrow key emulation (same problem as I mentioned in the previous 
email).

If you select a chunk of text in the field, then use the left-arrow emulator 
button, the ibeam is positioned before the *last* character of the selection, 
instead of before the first.


There were a couple of others, omitted for brevity. I've created a modified 
version your stack with my suggested handlers, and will attempt to upload it to 
the forum later.

Then there was another issue which I haven't tackled - it would mean changing 
lots of very similar tiny scripts, and is too tedious.

5. character input should replace any selection

Just like in a regular field, if there is an active selection, typing a 
character (or clicking a digit button, should *replace* it, not simply add the 
newly typed (or clicked) digit.


I've taken my earlier handler suggestion, and broken the bits of code out into 
individual button scripts, which removes the apparent complexity that you 
disliked earlier. As far as I know, no problems have yet been found with that 
approach. As one example, the code for left-arrow emulator would be


  on mouseUp
focus on field "fWORK"
put word 2 of the selectedchunk into tFirst
put word 4 of the selectedchunk into tLast
select before char (min(tFirst, tLast)) of fld "fWORK"
end mouseUp

I've uploaded this revised version on the forum thread.

Best wishes,  Alex



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-09 Thread Roger Guay via use-livecode
Alex and Richmond,

This discussion has been very helpful. Thank you! Please see my latest post on 
the forums where I offer my Formulator stack that seems to work, partly I think 
because I don’t lock the text of the multiple fields in my stack. Who woulda 
thunk?

https://forums.livecode.com/viewtopic.php?f=7=36444 


Cheers,

Roger


> On Nov 7, 2021, at 5:51 PM, Alex Tweedly via use-livecode 
>  wrote:
> 
> 
> On 07/11/2021 11:36, Richmond via use-livecode wrote:
>> No hard feelings.
>> 
>> See what I have got up to over on the Forums, and
>> 
>> https://forums.livecode.com/viewtopic.php?f=7=36444
>> 
>> PLEASE, feel free to pull the thing to bits.
>> 
> I don't want to "pull the thing to bits". Like you, I enjoy seeing 
> "competing" multitude of ways to do things - I can learn from them all.
> 
> But I did have a quick look, so I'll just point out a small number of 
> nitpicks.
> 
> 1. the whole 'locktext' thing is weird, and causes various anomalies.
> When I first open the stack, and click in the field, I can type digits and 
> have them appear in the field, as you'd expect. But once I've clicked on an 
> 'arrow-emulator' the field becomes locked and one can no longer type in 
> characters.  Clicking *outside* the field will then free it up again, so 
> typing becomes possible.
> 
> 2. disappearing iBeam.
> 
> If I position the ibeam in the middle of the text in the field, and use one 
> of the arrow emulator buttons, the iBeam  moves properly - but then 
> disappears (perhaps when the 'locktext' is set true).
> 
> 3. incorrect entry position.
> 
> As in 2 above, although the ibeam was last seen in the correct place after 
> using the ">" button to move it to the right, if I then click on a digit 
> button, that digit appears at the end of the field, not where it should have 
> gone
> 
> 4. Incorrect arrow key emulation (same problem as I mentioned in the previous 
> email).
> 
> If you select a chunk of text in the field, then use the left-arrow emulator 
> button, the ibeam is positioned before the *last* character of the selection, 
> instead of before the first.
> 
> 
> There were a couple of others, omitted for brevity. I've created a modified 
> version your stack with my suggested handlers, and will attempt to upload it 
> to the forum later.
> 
> Then there was another issue which I haven't tackled - it would mean changing 
> lots of very similar tiny scripts, and is too tedious.
> 
> 5. character input should replace any selection
> 
> Just like in a regular field, if there is an active selection, typing a 
> character (or clicking a digit button, should *replace* it, not simply add 
> the newly typed (or clicked) digit.
> 
> 
> I've taken my earlier handler suggestion, and broken the bits of code out 
> into individual button scripts, which removes the apparent complexity that 
> you disliked earlier. As far as I know, no problems have yet been found with 
> that approach. As one example, the code for left-arrow emulator would be
> 
>>  on mouseUp
>>focus on field "fWORK"
>>put word 2 of the selectedchunk into tFirst
>>put word 4 of the selectedchunk into tLast
>>select before char (min(tFirst, tLast)) of fld "fWORK"
>> end mouseUp
> I've uploaded this revised version on the forum thread.
> 
> Best wishes,  Alex
> 
> 
> 
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-07 Thread Alex Tweedly via use-livecode


On 07/11/2021 11:36, Richmond via use-livecode wrote:

No hard feelings.

See what I have got up to over on the Forums, and

https://forums.livecode.com/viewtopic.php?f=7=36444

PLEASE, feel free to pull the thing to bits.

I don't want to "pull the thing to bits". Like you, I enjoy seeing 
"competing" multitude of ways to do things - I can learn from them all.


But I did have a quick look, so I'll just point out a small number of 
nitpicks.


1. the whole 'locktext' thing is weird, and causes various anomalies.
When I first open the stack, and click in the field, I can type digits 
and have them appear in the field, as you'd expect. But once I've 
clicked on an 'arrow-emulator' the field becomes locked and one can no 
longer type in characters.  Clicking *outside* the field will then free 
it up again, so typing becomes possible.


2. disappearing iBeam.

If I position the ibeam in the middle of the text in the field, and use 
one of the arrow emulator buttons, the iBeam  moves properly - but then 
disappears (perhaps when the 'locktext' is set true).


3. incorrect entry position.

As in 2 above, although the ibeam was last seen in the correct place 
after using the ">" button to move it to the right, if I then click on a 
digit button, that digit appears at the end of the field, not where it 
should have gone


4. Incorrect arrow key emulation (same problem as I mentioned in the 
previous email).


If you select a chunk of text in the field, then use the left-arrow 
emulator button, the ibeam is positioned before the *last* character of 
the selection, instead of before the first.



There were a couple of others, omitted for brevity. I've created a 
modified version your stack with my suggested handlers, and will attempt 
to upload it to the forum later.


Then there was another issue which I haven't tackled - it would mean 
changing lots of very similar tiny scripts, and is too tedious.


5. character input should replace any selection

Just like in a regular field, if there is an active selection, typing a 
character (or clicking a digit button, should *replace* it, not simply 
add the newly typed (or clicked) digit.



I've taken my earlier handler suggestion, and broken the bits of code 
out into individual button scripts, which removes the apparent 
complexity that you disliked earlier. As far as I know, no problems have 
yet been found with that approach. As one example, the code for 
left-arrow emulator would be



 on mouseUp
   focus on field "fWORK"
   put word 2 of the selectedchunk into tFirst
   put word 4 of the selectedchunk into tLast
   select before char (min(tFirst, tLast)) of fld "fWORK"
end mouseUp

I've uploaded this revised version on the forum thread.

Best wishes,  Alex



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-07 Thread Richmond via use-livecode

No hard feelings.

See what I have got up to over on the Forums, and

https://forums.livecode.com/viewtopic.php?f=7=36444

PLEASE, feel free to pull the thing to bits.

Love, Richmond.

On 7.11.21 13:20, Alex Tweedly via use-livecode wrote:


On 07/11/2021 09:01, Richmond via use-livecode wrote:
I did not mean "competing" in the sense of "b*gger you", I meant it 
in the

sense of healthy competition.


Yeah, so did I.

And if it came across any other way, then I wholeheartedly apologise.

Sorry Richmond.

Alex.


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your 
subscription preferences:

http://lists.runrev.com/mailman/listinfo/use-livecode



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-07 Thread Alex Tweedly via use-livecode



On 07/11/2021 09:01, Richmond via use-livecode wrote:
I did not mean "competing" in the sense of "b*gger you", I meant it in 
the

sense of healthy competition.


Yeah, so did I.

And if it came across any other way, then I wholeheartedly apologise.

Sorry Richmond.

Alex.


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-07 Thread Richmond via use-livecode

I did not mean "competing" in the sense of "b*gger you", I meant it in the
sense of healthy competition.

"But having said that:  your "left-arrow' emulation gets it wrong if 
there is a chunk selection active."


Quite possible as I spent about 15 minutes on that yesterday between 
raking up dead leaves,
drilling through the metal head of a broken rake to screw it onto a 
wooden handle, and a whole
slew of other things such as talking to my son in Lilongwe re setting up 
discarded PCs out
there (Malawi) with Xubuntu and a programming suite that has recently 
been effectively abandoned.


I have a sackload of kids writing that has just arrived via Viber that 
has to be addressed:
after which I'll have a look at my "half cock job" and see if I can 
tweak it.


Richmond.

On 7.11.21 2:44, Alex Tweedly via use-livecode wrote:


On 06/11/2021 19:04, Richmond via use-livecode wrote:

My competing version is now "up":

https://forums.livecode.com/viewtopic.php?f=7=36444=210241#p210241

Richmond.


Don't you mean "my cooperating version ..."; surely the use-list is 
about helpful cooperatin and collaborative suggestions, not about 
competing :-)



But having said that:  your "left-arrow' emulation gets it wrong if 
there is a chunk selection active.


left-arrow should position the iBeam to the left of the selection, 
while this code positions it to the left of the rightmost character of 
the selection.


Alex.



On 5.11.21 23:08, Alex Tweedly via use-livecode wrote:


On 05/11/2021 20:18, Roger Guay via use-livecode wrote:
Alex, I did not see that and it is not in my mailbox. Would you 
please send it again?


Thanks,
Roger


Here it is again, below.

Or download the sample stack at 
https://tweedly.org/downloads/calcbuttons.livecode


 - not as pretty as Richmond's, doesn't even have all the digits ...)

Previously I said:

Here's an expanded snippet. The input is in a field called "fInput", 
the buttons are all in a group, and handled by the group script 
(saves having many tiny almost identical scripts).


The script  uses the name of the target - but since I would never, 
ever have a control named as a number, the digit buttons use their 
label instead.


If the user cannot select a chunk of text then some of this could be 
shortened.




on mouseup
   if the target = me then
  -- click in the background in the group
  exit mouseup
   end if
   local tChunk
   focus on fld "fInput"
   put the selectedchunk into tChunk
   if the label of the target is a number then
  put the label of the target into the selectedchunk
  exit mouseUp
   end if
   local tFirst, tLast
   put word 2 of tChunk into tFirst
   put word 4 of tChunk into tLast
   switch the short name of the target
  case "go left"
 select before char (min(tFirst, tLast)) of fld "fInput"
 break
  case  "go right"
 select after char (max(tFirst, tLast)) of fld "fInput"
 break
  case "Del"
 -- remove the selection, or the char *after* the ibeam
 if tFirst <= tLast then
    put empty into char tFirst to tLast of fld "fInput"
 else
    put empty into char (tFirst) of fld "fInput"
 end if
 break
  case "BS"
 -- remove the selection, or the char *before* the ibeam
 if tFirst <= tLast then
    put empty into char tFirst to tLast of fld "fInput"
 else
    put empty into char (tFirst-1) of fld "fInput"
 end if
 break
 -- all the other keys !!
  default
   end switch
end mouseup


Alex.

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your 
subscription preferences:

http://lists.runrev.com/mailman/listinfo/use-livecode



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your 
subscription preferences:

http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your 
subscription preferences:

http://lists.runrev.com/mailman/listinfo/use-livecode



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-06 Thread Alex Tweedly via use-livecode


On 06/11/2021 19:04, Richmond via use-livecode wrote:

My competing version is now "up":

https://forums.livecode.com/viewtopic.php?f=7=36444=210241#p210241

Richmond.


Don't you mean "my cooperating version ..."; surely the use-list is 
about helpful cooperatin and collaborative suggestions, not about 
competing :-)



But having said that:  your "left-arrow' emulation gets it wrong if 
there is a chunk selection active.


left-arrow should position the iBeam to the left of the selection, while 
this code positions it to the left of the rightmost character of the 
selection.


Alex.



On 5.11.21 23:08, Alex Tweedly via use-livecode wrote:


On 05/11/2021 20:18, Roger Guay via use-livecode wrote:
Alex, I did not see that and it is not in my mailbox. Would you 
please send it again?


Thanks,
Roger


Here it is again, below.

Or download the sample stack at 
https://tweedly.org/downloads/calcbuttons.livecode


 - not as pretty as Richmond's, doesn't even have all the digits ...)

Previously I said:

Here's an expanded snippet. The input is in a field called "fInput", 
the buttons are all in a group, and handled by the group script 
(saves having many tiny almost identical scripts).


The script  uses the name of the target - but since I would never, 
ever have a control named as a number, the digit buttons use their 
label instead.


If the user cannot select a chunk of text then some of this could be 
shortened.




on mouseup
   if the target = me then
  -- click in the background in the group
  exit mouseup
   end if
   local tChunk
   focus on fld "fInput"
   put the selectedchunk into tChunk
   if the label of the target is a number then
  put the label of the target into the selectedchunk
  exit mouseUp
   end if
   local tFirst, tLast
   put word 2 of tChunk into tFirst
   put word 4 of tChunk into tLast
   switch the short name of the target
  case "go left"
 select before char (min(tFirst, tLast)) of fld "fInput"
 break
  case  "go right"
 select after char (max(tFirst, tLast)) of fld "fInput"
 break
  case "Del"
 -- remove the selection, or the char *after* the ibeam
 if tFirst <= tLast then
    put empty into char tFirst to tLast of fld "fInput"
 else
    put empty into char (tFirst) of fld "fInput"
 end if
 break
  case "BS"
 -- remove the selection, or the char *before* the ibeam
 if tFirst <= tLast then
    put empty into char tFirst to tLast of fld "fInput"
 else
    put empty into char (tFirst-1) of fld "fInput"
 end if
 break
 -- all the other keys !!
  default
   end switch
end mouseup


Alex.

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your 
subscription preferences:

http://lists.runrev.com/mailman/listinfo/use-livecode



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your 
subscription preferences:

http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-06 Thread Richmond via use-livecode

My competing version is now "up":

https://forums.livecode.com/viewtopic.php?f=7=36444=210241#p210241

Richmond.

On 5.11.21 23:08, Alex Tweedly via use-livecode wrote:


On 05/11/2021 20:18, Roger Guay via use-livecode wrote:
Alex, I did not see that and it is not in my mailbox. Would you 
please send it again?


Thanks,
Roger


Here it is again, below.

Or download the sample stack at 
https://tweedly.org/downloads/calcbuttons.livecode


 - not as pretty as Richmond's, doesn't even have all the digits ...)

Previously I said:

Here's an expanded snippet. The input is in a field called "fInput", 
the buttons are all in a group, and handled by the group script (saves 
having many tiny almost identical scripts).


The script  uses the name of the target - but since I would never, 
ever have a control named as a number, the digit buttons use their 
label instead.


If the user cannot select a chunk of text then some of this could be 
shortened.




on mouseup
   if the target = me then
  -- click in the background in the group
  exit mouseup
   end if
   local tChunk
   focus on fld "fInput"
   put the selectedchunk into tChunk
   if the label of the target is a number then
  put the label of the target into the selectedchunk
  exit mouseUp
   end if
   local tFirst, tLast
   put word 2 of tChunk into tFirst
   put word 4 of tChunk into tLast
   switch the short name of the target
  case "go left"
 select before char (min(tFirst, tLast)) of fld "fInput"
 break
  case  "go right"
 select after char (max(tFirst, tLast)) of fld "fInput"
 break
  case "Del"
 -- remove the selection, or the char *after* the ibeam
 if tFirst <= tLast then
    put empty into char tFirst to tLast of fld "fInput"
 else
    put empty into char (tFirst) of fld "fInput"
 end if
 break
  case "BS"
 -- remove the selection, or the char *before* the ibeam
 if tFirst <= tLast then
    put empty into char tFirst to tLast of fld "fInput"
 else
    put empty into char (tFirst-1) of fld "fInput"
 end if
 break
 -- all the other keys !!
  default
   end switch
end mouseup


Alex.

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your 
subscription preferences:

http://lists.runrev.com/mailman/listinfo/use-livecode



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-05 Thread Roger Guay via use-livecode
Thank you so much, Alex. This indeed does the trick. And thanks also to 
Richmond and Klaus for spending time on this.

Roger





> On Nov 5, 2021, at 2:08 PM, Alex Tweedly via use-livecode 
>  wrote:
> 
> 
> On 05/11/2021 20:18, Roger Guay via use-livecode wrote:
>> Alex, I did not see that and it is not in my mailbox. Would you please send 
>> it again?
>> 
>> Thanks,
>> Roger
> 
> Here it is again, below.
> 
> Or download the sample stack at 
> https://tweedly.org/downloads/calcbuttons.livecode
> 
>  - not as pretty as Richmond's, doesn't even have all the digits ...)
> 
> Previously I said:
> 
> Here's an expanded snippet. The input is in a field called "fInput", the 
> buttons are all in a group, and handled by the group script (saves having 
> many tiny almost identical scripts).
> 
> The script  uses the name of the target - but since I would never, ever have 
> a control named as a number, the digit buttons use their label instead.
> 
> If the user cannot select a chunk of text then some of this could be 
> shortened.
> 
> 
>> on mouseup
>>if the target = me then
>>   -- click in the background in the group
>>   exit mouseup
>>end if
>>local tChunk
>>focus on fld "fInput"
>>put the selectedchunk into tChunk
>>if the label of the target is a number then
>>   put the label of the target into the selectedchunk
>>   exit mouseUp
>>end if
>>local tFirst, tLast
>>put word 2 of tChunk into tFirst
>>put word 4 of tChunk into tLast
>>switch the short name of the target
>>   case "go left"
>>  select before char (min(tFirst, tLast)) of fld "fInput"
>>  break
>>   case  "go right"
>>  select after char (max(tFirst, tLast)) of fld "fInput"
>>  break
>>   case "Del"
>>  -- remove the selection, or the char *after* the ibeam
>>  if tFirst <= tLast then
>> put empty into char tFirst to tLast of fld "fInput"
>>  else
>> put empty into char (tFirst) of fld "fInput"
>>  end if
>>  break
>>   case "BS"
>>  -- remove the selection, or the char *before* the ibeam
>>  if tFirst <= tLast then
>> put empty into char tFirst to tLast of fld "fInput"
>>  else
>> put empty into char (tFirst-1) of fld "fInput"
>>  end if
>>  break
>>  -- all the other keys !!
>>   default
>>end switch
>> end mouseup
> 
> Alex.
> 
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-05 Thread Klaus major-k via use-livecode
Hi Roger,

> Am 05.11.2021 um 21:58 schrieb Roger Guay via use-livecode 
> :
> 
> Is that unicode? If so how do I use it? Never done that before.

no, that is the RAWKEY code for that erm. key. :-)
Use it in a "rawkeydown/up" handler.

> Roger
> 
>> On Nov 5, 2021, at 12:02 PM, Richmond via use-livecode 
>>  wrote:
>> Then, surely you want to implement the FORWARD delete key: 65535

Best

Klaus

--
Klaus Major
https://www.major-k.de
https://www.major-k.de/bass
kl...@major-k.de


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-05 Thread Alex Tweedly via use-livecode


On 05/11/2021 20:18, Roger Guay via use-livecode wrote:

Alex, I did not see that and it is not in my mailbox. Would you please send it 
again?

Thanks,
Roger


Here it is again, below.

Or download the sample stack at 
https://tweedly.org/downloads/calcbuttons.livecode


 - not as pretty as Richmond's, doesn't even have all the digits ...)

Previously I said:

Here's an expanded snippet. The input is in a field called "fInput", the 
buttons are all in a group, and handled by the group script (saves 
having many tiny almost identical scripts).


The script  uses the name of the target - but since I would never, ever 
have a control named as a number, the digit buttons use their label 
instead.


If the user cannot select a chunk of text then some of this could be 
shortened.




on mouseup
   if the target = me then
  -- click in the background in the group
  exit mouseup
   end if
   local tChunk
   focus on fld "fInput"
   put the selectedchunk into tChunk
   if the label of the target is a number then
  put the label of the target into the selectedchunk
  exit mouseUp
   end if
   local tFirst, tLast
   put word 2 of tChunk into tFirst
   put word 4 of tChunk into tLast
   switch the short name of the target
  case "go left"
 select before char (min(tFirst, tLast)) of fld "fInput"
 break
  case  "go right"
 select after char (max(tFirst, tLast)) of fld "fInput"
 break
  case "Del"
 -- remove the selection, or the char *after* the ibeam
 if tFirst <= tLast then
    put empty into char tFirst to tLast of fld "fInput"
 else
    put empty into char (tFirst) of fld "fInput"
 end if
 break
  case "BS"
 -- remove the selection, or the char *before* the ibeam
 if tFirst <= tLast then
    put empty into char tFirst to tLast of fld "fInput"
 else
    put empty into char (tFirst-1) of fld "fInput"
 end if
 break
 -- all the other keys !!
  default
   end switch
end mouseup


Alex.

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-05 Thread Roger Guay via use-livecode
Is that unicode? If so how do I use it? Never done that before.

Roger

> On Nov 5, 2021, at 12:02 PM, Richmond via use-livecode 
>  wrote:
> 
> Then, surely you want to implement the FORWARD delete key: 65535

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-05 Thread Roger Guay via use-livecode
Alex, I did not see that and it is not in my mailbox. Would you please send it 
again?

Thanks,
Roger

> On Nov 5, 2021, at 12:49 PM, Alex Tweedly via use-livecode 
>  wrote:
> 
> Hi Roger. Don't know if you've seen the script I posted around 6 hour ago 
> ("expanded snippet").
> 
> It does the correct forward / backward key movements, and also implements 
> both "backspace" (delete the char to the left of the iBeam) and "delete" 
> (remove the char to the right of the ibeam) as well as properly handling the 
> case where there is a text selection rather than just an ibeam (i.e. both 
> delete the selection, but not any characters outside that selection).
> 
> Alex..
> 
> 
> On 05/11/2021 18:37, Roger Guay via use-livecode wrote:
>> Very good, Richmond. It’s impressive how quickly you piss around! And, it’s 
>> close but no cigar . The arrow keys on the keyboard move the ibeam in a 
>> field w/o highlighting any text. And, the Delete key deletes the char in 
>> front of the iBeam. I thought this would be easy to duplicate in LC, but 
>> maybe not??.
>> 
>> Why do I want to emulate these keys? Well at this point, It has become a 
>> challenge and I like challenges. BTW, the calculator that I am inspired to 
>> replicate is found in Mac Good Grapher which is bundled with the Mac. The 
>> Good Grapher Calculator has back and forward buttons and a Delete button 
>> that operate exactly as the keyboard ones
>> 
>> Thanks for playing with this,
>> 
>> Roger
>> 
>>> On Nov 5, 2021, at 10:15 AM, Richmond via use-livecode 
>>>  wrote:
>>> 
>>> Pissed around a bit:
>>> 
>>> https://forums.livecode.com/viewtopic.php?f=7=36444
>>> 
>>> Love, Richmond.
>>> 
>>> On 5.11.21 15:59, Roger Guay via use-livecode wrote:
 I want them to do exactly the same thing that the keyboard keys do!! IOW, 
 I want to emulate the delete key and the back and forward keys.
 
 Roger
 
> On Nov 5, 2021, at 12:33 AM, Richmond Mathewson via use-livecode 
>  wrote:
> 
> Surely the script depends on what you want those buttons to do.
> 
> On Fri, 5 Nov 2021 03:41 Roger Guay via use-livecode, <
> use-livecode@lists.runrev.com> wrote:
> 
>> Thanks, Alex. Sorry I didn’t make myself clear. I’m building a calculator
>> stack with forward and back arrow buttons and a Delete button. What's the
>> script for these buttons?
>> 
>> Roger
>> 
>>> On Nov 4, 2021, at 5:53 PM, Alex Tweedly via use-livecode <
>> use-livecode@lists.runrev.com> wrote:
>>> Hi Roger,
>>> 
>>> I'm not sure I properly understand your question.
>>> 
>>> here's a code snippet the moves the insertion point (in this sample,
>> typing an 'f' moves it forward, 'b' moves it back). (Note this also works
>> if there is some text selected - it moves the insertion to just after the
>> selection, just like the arrow key does).
 on keydown p
   local t
   switch p
  case  "f"
 put word 4 of the selectedchunk into t
 select after char (t+1) of me
 break
  case "b"
 put word 2 of the selectedchunk into t
 select before char (t-1) of me
 break
   end  switch
 end keydown
>>> To then delete the char in front of it, you'd do something like
>>> 
>>>   put empty into char (t+1) of me
>>> 
>>> Hope that's close enough to what you were asking, or at least gives you
>> a starting place  :-),
>>> Alex.
>>> 
>>> On 04/11/2021 20:49, Roger Guay via use-livecode wrote:
 I simply want to be able to move the insertion iBeam in a focused field
>> left and right, one char at a time (just like the left and right arrows
>> keys), and then to delete the char in front of it (just like the Delete
>> key). The dictionary was again of no use to me. Can someone please 
>> provide
>> sample scripts?
 Thanks,
 Roger
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your
>> subscription preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode
>>> ___
>>> use-livecode mailing list
>>> use-livecode@lists.runrev.com
>>> Please visit this url to subscribe, unsubscribe and manage your
>> subscription preferences:
>>> http://lists.runrev.com/mailman/listinfo/use-livecode
>> ___
>> use-livecode mailing list
>> use-livecode@lists.runrev.com
>> Please visit this url to subscribe, unsubscribe and manage your
>> subscription preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
>> 
> ___
> use-livecode mailing 

Re: Control of Text Fields.

2021-11-05 Thread Alex Tweedly via use-livecode
Hi Roger. Don't know if you've seen the script I posted around 6 hour 
ago ("expanded snippet").


It does the correct forward / backward key movements, and also 
implements both "backspace" (delete the char to the left of the iBeam) 
and "delete" (remove the char to the right of the ibeam) as well as 
properly handling the case where there is a text selection rather than 
just an ibeam (i.e. both delete the selection, but not any characters 
outside that selection).


Alex..


On 05/11/2021 18:37, Roger Guay via use-livecode wrote:

Very good, Richmond. It’s impressive how quickly you piss around! And, it’s 
close but no cigar . The arrow keys on the keyboard move the ibeam in a field 
w/o highlighting any text. And, the Delete key deletes the char in front of the 
iBeam. I thought this would be easy to duplicate in LC, but maybe not??.

Why do I want to emulate these keys? Well at this point, It has become a 
challenge and I like challenges. BTW, the calculator that I am inspired to 
replicate is found in Mac Good Grapher which is bundled with the Mac. The Good 
Grapher Calculator has back and forward buttons and a Delete button that 
operate exactly as the keyboard ones

Thanks for playing with this,

Roger


On Nov 5, 2021, at 10:15 AM, Richmond via use-livecode 
 wrote:

Pissed around a bit:

https://forums.livecode.com/viewtopic.php?f=7=36444

Love, Richmond.

On 5.11.21 15:59, Roger Guay via use-livecode wrote:

I want them to do exactly the same thing that the keyboard keys do!! IOW, I 
want to emulate the delete key and the back and forward keys.

Roger


On Nov 5, 2021, at 12:33 AM, Richmond Mathewson via use-livecode 
 wrote:

Surely the script depends on what you want those buttons to do.

On Fri, 5 Nov 2021 03:41 Roger Guay via use-livecode, <
use-livecode@lists.runrev.com> wrote:


Thanks, Alex. Sorry I didn’t make myself clear. I’m building a calculator
stack with forward and back arrow buttons and a Delete button. What's the
script for these buttons?

Roger


On Nov 4, 2021, at 5:53 PM, Alex Tweedly via use-livecode <

use-livecode@lists.runrev.com> wrote:

Hi Roger,

I'm not sure I properly understand your question.

here's a code snippet the moves the insertion point (in this sample,

typing an 'f' moves it forward, 'b' moves it back). (Note this also works
if there is some text selected - it moves the insertion to just after the
selection, just like the arrow key does).

on keydown p
   local t
   switch p
  case  "f"
 put word 4 of the selectedchunk into t
 select after char (t+1) of me
 break
  case "b"
 put word 2 of the selectedchunk into t
 select before char (t-1) of me
 break
   end  switch
end keydown

To then delete the char in front of it, you'd do something like

   put empty into char (t+1) of me

Hope that's close enough to what you were asking, or at least gives you

a starting place  :-),

Alex.

On 04/11/2021 20:49, Roger Guay via use-livecode wrote:

I simply want to be able to move the insertion iBeam in a focused field

left and right, one char at a time (just like the left and right arrows
keys), and then to delete the char in front of it (just like the Delete
key). The dictionary was again of no use to me. Can someone please provide
sample scripts?

Thanks,
Roger
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your

subscription preferences:

http://lists.runrev.com/mailman/listinfo/use-livecode

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your

subscription preferences:

http://lists.runrev.com/mailman/listinfo/use-livecode

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your
subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your 

Re: Control of Text Fields.

2021-11-05 Thread Richmond via use-livecode



On 5.11.21 20:37, Roger Guay via use-livecode wrote:

Very good, Richmond. It’s impressive how quickly you piss around! And, it’s 
close but no cigar . The arrow keys on the keyboard move the ibeam in a field 
w/o highlighting any text. And, the Delete key deletes the char in front of the 
iBeam.


Then, surely you want to implement the FORWARD delete key: 65535

I thought this would be easy to duplicate in LC, but maybe not??.

Why do I want to emulate these keys? Well at this point, It has become a 
challenge and I like challenges. BTW, the calculator that I am inspired to 
replicate is found in Mac Good Grapher which is bundled with the Mac. The Good 
Grapher Calculator has back and forward buttons and a Delete button that 
operate exactly as the keyboard ones

Thanks for playing with this,

Roger


On Nov 5, 2021, at 10:15 AM, Richmond via use-livecode 
 wrote:

Pissed around a bit:

https://forums.livecode.com/viewtopic.php?f=7=36444

Love, Richmond.

On 5.11.21 15:59, Roger Guay via use-livecode wrote:

I want them to do exactly the same thing that the keyboard keys do!! IOW, I 
want to emulate the delete key and the back and forward keys.

Roger


On Nov 5, 2021, at 12:33 AM, Richmond Mathewson via use-livecode 
 wrote:

Surely the script depends on what you want those buttons to do.

On Fri, 5 Nov 2021 03:41 Roger Guay via use-livecode, <
use-livecode@lists.runrev.com> wrote:


Thanks, Alex. Sorry I didn’t make myself clear. I’m building a calculator
stack with forward and back arrow buttons and a Delete button. What's the
script for these buttons?

Roger


On Nov 4, 2021, at 5:53 PM, Alex Tweedly via use-livecode <

use-livecode@lists.runrev.com> wrote:

Hi Roger,

I'm not sure I properly understand your question.

here's a code snippet the moves the insertion point (in this sample,

typing an 'f' moves it forward, 'b' moves it back). (Note this also works
if there is some text selected - it moves the insertion to just after the
selection, just like the arrow key does).

on keydown p
   local t
   switch p
  case  "f"
 put word 4 of the selectedchunk into t
 select after char (t+1) of me
 break
  case "b"
 put word 2 of the selectedchunk into t
 select before char (t-1) of me
 break
   end  switch
end keydown

To then delete the char in front of it, you'd do something like

   put empty into char (t+1) of me

Hope that's close enough to what you were asking, or at least gives you

a starting place  :-),

Alex.

On 04/11/2021 20:49, Roger Guay via use-livecode wrote:

I simply want to be able to move the insertion iBeam in a focused field

left and right, one char at a time (just like the left and right arrows
keys), and then to delete the char in front of it (just like the Delete
key). The dictionary was again of no use to me. Can someone please provide
sample scripts?

Thanks,
Roger
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your

subscription preferences:

http://lists.runrev.com/mailman/listinfo/use-livecode

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your

subscription preferences:

http://lists.runrev.com/mailman/listinfo/use-livecode

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your
subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-05 Thread Roger Guay via use-livecode
Very good, Richmond. It’s impressive how quickly you piss around! And, it’s 
close but no cigar . The arrow keys on the keyboard move the ibeam in a field 
w/o highlighting any text. And, the Delete key deletes the char in front of the 
iBeam. I thought this would be easy to duplicate in LC, but maybe not??.

Why do I want to emulate these keys? Well at this point, It has become a 
challenge and I like challenges. BTW, the calculator that I am inspired to 
replicate is found in Mac Good Grapher which is bundled with the Mac. The Good 
Grapher Calculator has back and forward buttons and a Delete button that 
operate exactly as the keyboard ones

Thanks for playing with this,

Roger

> On Nov 5, 2021, at 10:15 AM, Richmond via use-livecode 
>  wrote:
> 
> Pissed around a bit:
> 
> https://forums.livecode.com/viewtopic.php?f=7=36444
> 
> Love, Richmond.
> 
> On 5.11.21 15:59, Roger Guay via use-livecode wrote:
>> I want them to do exactly the same thing that the keyboard keys do!! IOW, I 
>> want to emulate the delete key and the back and forward keys.
>> 
>> Roger
>> 
>>> On Nov 5, 2021, at 12:33 AM, Richmond Mathewson via use-livecode 
>>>  wrote:
>>> 
>>> Surely the script depends on what you want those buttons to do.
>>> 
>>> On Fri, 5 Nov 2021 03:41 Roger Guay via use-livecode, <
>>> use-livecode@lists.runrev.com> wrote:
>>> 
 Thanks, Alex. Sorry I didn’t make myself clear. I’m building a calculator
 stack with forward and back arrow buttons and a Delete button. What's the
 script for these buttons?
 
 Roger
 
> On Nov 4, 2021, at 5:53 PM, Alex Tweedly via use-livecode <
 use-livecode@lists.runrev.com> wrote:
> Hi Roger,
> 
> I'm not sure I properly understand your question.
> 
> here's a code snippet the moves the insertion point (in this sample,
 typing an 'f' moves it forward, 'b' moves it back). (Note this also works
 if there is some text selected - it moves the insertion to just after the
 selection, just like the arrow key does).
>> on keydown p
>>   local t
>>   switch p
>>  case  "f"
>> put word 4 of the selectedchunk into t
>> select after char (t+1) of me
>> break
>>  case "b"
>> put word 2 of the selectedchunk into t
>> select before char (t-1) of me
>> break
>>   end  switch
>> end keydown
> To then delete the char in front of it, you'd do something like
> 
>   put empty into char (t+1) of me
> 
> Hope that's close enough to what you were asking, or at least gives you
 a starting place  :-),
> Alex.
> 
> On 04/11/2021 20:49, Roger Guay via use-livecode wrote:
>> I simply want to be able to move the insertion iBeam in a focused field
 left and right, one char at a time (just like the left and right arrows
 keys), and then to delete the char in front of it (just like the Delete
 key). The dictionary was again of no use to me. Can someone please provide
 sample scripts?
>> Thanks,
>> Roger
>> ___
>> use-livecode mailing list
>> use-livecode@lists.runrev.com
>> Please visit this url to subscribe, unsubscribe and manage your
 subscription preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your
 subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your
 subscription preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode
 
>>> ___
>>> use-livecode mailing list
>>> use-livecode@lists.runrev.com
>>> Please visit this url to subscribe, unsubscribe and manage your 
>>> subscription preferences:
>>> http://lists.runrev.com/mailman/listinfo/use-livecode
>> 
>> ___
>> use-livecode mailing list
>> use-livecode@lists.runrev.com
>> Please visit this url to subscribe, unsubscribe and manage your subscription 
>> preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
> 
> 
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:

Re: Control of Text Fields.

2021-11-05 Thread Richmond via use-livecode

Pissed around a bit:

https://forums.livecode.com/viewtopic.php?f=7=36444

Love, Richmond.

On 5.11.21 15:59, Roger Guay via use-livecode wrote:

I want them to do exactly the same thing that the keyboard keys do!! IOW, I 
want to emulate the delete key and the back and forward keys.

Roger


On Nov 5, 2021, at 12:33 AM, Richmond Mathewson via use-livecode 
 wrote:

Surely the script depends on what you want those buttons to do.

On Fri, 5 Nov 2021 03:41 Roger Guay via use-livecode, <
use-livecode@lists.runrev.com> wrote:


Thanks, Alex. Sorry I didn’t make myself clear. I’m building a calculator
stack with forward and back arrow buttons and a Delete button. What's the
script for these buttons?

Roger


On Nov 4, 2021, at 5:53 PM, Alex Tweedly via use-livecode <

use-livecode@lists.runrev.com> wrote:

Hi Roger,

I'm not sure I properly understand your question.

here's a code snippet the moves the insertion point (in this sample,

typing an 'f' moves it forward, 'b' moves it back). (Note this also works
if there is some text selected - it moves the insertion to just after the
selection, just like the arrow key does).

on keydown p
   local t
   switch p
  case  "f"
 put word 4 of the selectedchunk into t
 select after char (t+1) of me
 break
  case "b"
 put word 2 of the selectedchunk into t
 select before char (t-1) of me
 break
   end  switch
end keydown

To then delete the char in front of it, you'd do something like

   put empty into char (t+1) of me

Hope that's close enough to what you were asking, or at least gives you

a starting place  :-),

Alex.

On 04/11/2021 20:49, Roger Guay via use-livecode wrote:

I simply want to be able to move the insertion iBeam in a focused field

left and right, one char at a time (just like the left and right arrows
keys), and then to delete the char in front of it (just like the Delete
key). The dictionary was again of no use to me. Can someone please provide
sample scripts?

Thanks,
Roger
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your

subscription preferences:

http://lists.runrev.com/mailman/listinfo/use-livecode

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your

subscription preferences:

http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your
subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-05 Thread Richmond via use-livecode

Why do you need to emulate them?

Will you NOT have access to a physical keyboard?

Here's the script of a stupid button to DELETE one number in
a calculator read-out:



Richmond.



On 5.11.21 15:59, Roger Guay via use-livecode wrote:

I want them to do exactly the same thing that the keyboard keys do!! IOW, I 
want to emulate the delete key and the back and forward keys.

Roger


On Nov 5, 2021, at 12:33 AM, Richmond Mathewson via use-livecode 
 wrote:

Surely the script depends on what you want those buttons to do.

On Fri, 5 Nov 2021 03:41 Roger Guay via use-livecode, <
use-livecode@lists.runrev.com> wrote:


Thanks, Alex. Sorry I didn’t make myself clear. I’m building a calculator
stack with forward and back arrow buttons and a Delete button. What's the
script for these buttons?

Roger


On Nov 4, 2021, at 5:53 PM, Alex Tweedly via use-livecode <

use-livecode@lists.runrev.com> wrote:

Hi Roger,

I'm not sure I properly understand your question.

here's a code snippet the moves the insertion point (in this sample,

typing an 'f' moves it forward, 'b' moves it back). (Note this also works
if there is some text selected - it moves the insertion to just after the
selection, just like the arrow key does).

on keydown p
   local t
   switch p
  case  "f"
 put word 4 of the selectedchunk into t
 select after char (t+1) of me
 break
  case "b"
 put word 2 of the selectedchunk into t
 select before char (t-1) of me
 break
   end  switch
end keydown

To then delete the char in front of it, you'd do something like

   put empty into char (t+1) of me

Hope that's close enough to what you were asking, or at least gives you

a starting place  :-),

Alex.

On 04/11/2021 20:49, Roger Guay via use-livecode wrote:

I simply want to be able to move the insertion iBeam in a focused field

left and right, one char at a time (just like the left and right arrows
keys), and then to delete the char in front of it (just like the Delete
key). The dictionary was again of no use to me. Can someone please provide
sample scripts?

Thanks,
Roger
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your

subscription preferences:

http://lists.runrev.com/mailman/listinfo/use-livecode

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your

subscription preferences:

http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your
subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-05 Thread Richmond via use-livecode

I am sorry for that misunderstanding: I had a fairly fixed idea of what
constituted a calculator in my head, and what you seem to want with your 
back, forward and delete keys seems more

"word-processory".

Richmond.

On 5.11.21 15:59, Roger Guay via use-livecode wrote:

I want them to do exactly the same thing that the keyboard keys do!! IOW, I 
want to emulate the delete key and the back and forward keys.

Roger


On Nov 5, 2021, at 12:33 AM, Richmond Mathewson via use-livecode 
 wrote:

Surely the script depends on what you want those buttons to do.

On Fri, 5 Nov 2021 03:41 Roger Guay via use-livecode, <
use-livecode@lists.runrev.com> wrote:


Thanks, Alex. Sorry I didn’t make myself clear. I’m building a calculator
stack with forward and back arrow buttons and a Delete button. What's the
script for these buttons?

Roger


On Nov 4, 2021, at 5:53 PM, Alex Tweedly via use-livecode <

use-livecode@lists.runrev.com> wrote:

Hi Roger,

I'm not sure I properly understand your question.

here's a code snippet the moves the insertion point (in this sample,

typing an 'f' moves it forward, 'b' moves it back). (Note this also works
if there is some text selected - it moves the insertion to just after the
selection, just like the arrow key does).

on keydown p
   local t
   switch p
  case  "f"
 put word 4 of the selectedchunk into t
 select after char (t+1) of me
 break
  case "b"
 put word 2 of the selectedchunk into t
 select before char (t-1) of me
 break
   end  switch
end keydown

To then delete the char in front of it, you'd do something like

   put empty into char (t+1) of me

Hope that's close enough to what you were asking, or at least gives you

a starting place  :-),

Alex.

On 04/11/2021 20:49, Roger Guay via use-livecode wrote:

I simply want to be able to move the insertion iBeam in a focused field

left and right, one char at a time (just like the left and right arrows
keys), and then to delete the char in front of it (just like the Delete
key). The dictionary was again of no use to me. Can someone please provide
sample scripts?

Thanks,
Roger
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your

subscription preferences:

http://lists.runrev.com/mailman/listinfo/use-livecode

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your

subscription preferences:

http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your
subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-05 Thread Roger Guay via use-livecode
I want them to do exactly the same thing that the keyboard keys do!! IOW, I 
want to emulate the delete key and the back and forward keys.

Roger

> On Nov 5, 2021, at 12:33 AM, Richmond Mathewson via use-livecode 
>  wrote:
> 
> Surely the script depends on what you want those buttons to do.
> 
> On Fri, 5 Nov 2021 03:41 Roger Guay via use-livecode, <
> use-livecode@lists.runrev.com> wrote:
> 
>> Thanks, Alex. Sorry I didn’t make myself clear. I’m building a calculator
>> stack with forward and back arrow buttons and a Delete button. What's the
>> script for these buttons?
>> 
>> Roger
>> 
>>> On Nov 4, 2021, at 5:53 PM, Alex Tweedly via use-livecode <
>> use-livecode@lists.runrev.com> wrote:
>>> 
>>> Hi Roger,
>>> 
>>> I'm not sure I properly understand your question.
>>> 
>>> here's a code snippet the moves the insertion point (in this sample,
>> typing an 'f' moves it forward, 'b' moves it back). (Note this also works
>> if there is some text selected - it moves the insertion to just after the
>> selection, just like the arrow key does).
>>> 
 on keydown p
   local t
   switch p
  case  "f"
 put word 4 of the selectedchunk into t
 select after char (t+1) of me
 break
  case "b"
 put word 2 of the selectedchunk into t
 select before char (t-1) of me
 break
   end  switch
 end keydown
>>> To then delete the char in front of it, you'd do something like
>>> 
>>>   put empty into char (t+1) of me
>>> 
>>> Hope that's close enough to what you were asking, or at least gives you
>> a starting place  :-),
>>> 
>>> Alex.
>>> 
>>> On 04/11/2021 20:49, Roger Guay via use-livecode wrote:
 I simply want to be able to move the insertion iBeam in a focused field
>> left and right, one char at a time (just like the left and right arrows
>> keys), and then to delete the char in front of it (just like the Delete
>> key). The dictionary was again of no use to me. Can someone please provide
>> sample scripts?
 
 Thanks,
 Roger
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your
>> subscription preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode
>>> 
>>> ___
>>> use-livecode mailing list
>>> use-livecode@lists.runrev.com
>>> Please visit this url to subscribe, unsubscribe and manage your
>> subscription preferences:
>>> http://lists.runrev.com/mailman/listinfo/use-livecode
>> 
>> 
>> ___
>> use-livecode mailing list
>> use-livecode@lists.runrev.com
>> Please visit this url to subscribe, unsubscribe and manage your
>> subscription preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
>> 
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-05 Thread Alex Tweedly via use-livecode

OK, so I was close, but didn't get the cigar.

Here's an expanded snippet. The input is in a field called "fInput", the 
buttons are all in a group, and handled by the group script (saves 
having many tiny almost identical scripts).


The script  uses the name of the target - but since I would never, ever 
have a control named as a number, the digit buttons use their label instead.


If the user cannot select a chunk of text then some of this could be 
shortened.




on mouseup
   if the target = me then
  -- click in the background in the group
  exit mouseup
   end if
   local tChunk
   focus on fld "fInput"
   put the selectedchunk into tChunk
   if the label of the target is a number then
  put the label of the target into the selectedchunk
  exit mouseUp
   end if
   local tFirst, tLast
   put word 2 of tChunk into tFirst
   put word 4 of tChunk into tLast
   switch the short name of the target
  case "go left"
 select before char (min(tFirst, tLast)) of fld "fInput"
 break
  case  "go right"
 select after char (max(tFirst, tLast)) of fld "fInput"
 break
  case "Del"
 -- remove the selection, or the char *after* the ibeam
 if tFirst <= tLast then
    put empty into char tFirst to tLast of fld "fInput"
 else
    put empty into char (tFirst) of fld "fInput"
 end if
 break
  case "BS"
 -- remove the selection, or the char *before* the ibeam
 if tFirst <= tLast then
    put empty into char tFirst to tLast of fld "fInput"
 else
    put empty into char (tFirst-1) of fld "fInput"
 end if
 break
 -- all the other keys !!
  default
   end switch
end mouseup


Alex.


On 05/11/2021 01:39, Roger Guay via use-livecode wrote:

Thanks, Alex. Sorry I didn’t make myself clear. I’m building a calculator stack 
with forward and back arrow buttons and a Delete button. What's the script for 
these buttons?

Roger


On Nov 4, 2021, at 5:53 PM, Alex Tweedly via use-livecode 
 wrote:

Hi Roger,

I'm not sure I properly understand your question.

here's a code snippet the moves the insertion point (in this sample, typing an 
'f' moves it forward, 'b' moves it back). (Note this also works if there is 
some text selected - it moves the insertion to just after the selection, just 
like the arrow key does).


on keydown p
local t
switch p
   case  "f"
  put word 4 of the selectedchunk into t
  select after char (t+1) of me
  break
   case "b"
  put word 2 of the selectedchunk into t
  select before char (t-1) of me
  break
end  switch
end keydown

To then delete the char in front of it, you'd do something like

put empty into char (t+1) of me

Hope that's close enough to what you were asking, or at least gives you a 
starting place  :-),

Alex.

On 04/11/2021 20:49, Roger Guay via use-livecode wrote:

I simply want to be able to move the insertion iBeam in a focused field left 
and right, one char at a time (just like the left and right arrows keys), and 
then to delete the char in front of it (just like the Delete key). The 
dictionary was again of no use to me. Can someone please provide sample scripts?

Thanks,
Roger
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-05 Thread Richmond Mathewson via use-livecode
Surely the script depends on what you want those buttons to do.

On Fri, 5 Nov 2021 03:41 Roger Guay via use-livecode, <
use-livecode@lists.runrev.com> wrote:

> Thanks, Alex. Sorry I didn’t make myself clear. I’m building a calculator
> stack with forward and back arrow buttons and a Delete button. What's the
> script for these buttons?
>
> Roger
>
> > On Nov 4, 2021, at 5:53 PM, Alex Tweedly via use-livecode <
> use-livecode@lists.runrev.com> wrote:
> >
> > Hi Roger,
> >
> > I'm not sure I properly understand your question.
> >
> > here's a code snippet the moves the insertion point (in this sample,
> typing an 'f' moves it forward, 'b' moves it back). (Note this also works
> if there is some text selected - it moves the insertion to just after the
> selection, just like the arrow key does).
> >
> >> on keydown p
> >>local t
> >>switch p
> >>   case  "f"
> >>  put word 4 of the selectedchunk into t
> >>  select after char (t+1) of me
> >>  break
> >>   case "b"
> >>  put word 2 of the selectedchunk into t
> >>  select before char (t-1) of me
> >>  break
> >>end  switch
> >> end keydown
> > To then delete the char in front of it, you'd do something like
> >
> >put empty into char (t+1) of me
> >
> > Hope that's close enough to what you were asking, or at least gives you
> a starting place  :-),
> >
> > Alex.
> >
> > On 04/11/2021 20:49, Roger Guay via use-livecode wrote:
> >> I simply want to be able to move the insertion iBeam in a focused field
> left and right, one char at a time (just like the left and right arrows
> keys), and then to delete the char in front of it (just like the Delete
> key). The dictionary was again of no use to me. Can someone please provide
> sample scripts?
> >>
> >> Thanks,
> >> Roger
> >> ___
> >> use-livecode mailing list
> >> use-livecode@lists.runrev.com
> >> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> >> http://lists.runrev.com/mailman/listinfo/use-livecode
> >
> > ___
> > use-livecode mailing list
> > use-livecode@lists.runrev.com
> > Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> > http://lists.runrev.com/mailman/listinfo/use-livecode
>
>
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
>
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-04 Thread Roger Guay via use-livecode
Thanks, Alex. Sorry I didn’t make myself clear. I’m building a calculator stack 
with forward and back arrow buttons and a Delete button. What's the script for 
these buttons?

Roger

> On Nov 4, 2021, at 5:53 PM, Alex Tweedly via use-livecode 
>  wrote:
> 
> Hi Roger,
> 
> I'm not sure I properly understand your question.
> 
> here's a code snippet the moves the insertion point (in this sample, typing 
> an 'f' moves it forward, 'b' moves it back). (Note this also works if there 
> is some text selected - it moves the insertion to just after the selection, 
> just like the arrow key does).
> 
>> on keydown p
>>local t
>>switch p
>>   case  "f"
>>  put word 4 of the selectedchunk into t
>>  select after char (t+1) of me
>>  break
>>   case "b"
>>  put word 2 of the selectedchunk into t
>>  select before char (t-1) of me
>>  break
>>end  switch
>> end keydown
> To then delete the char in front of it, you'd do something like
> 
>put empty into char (t+1) of me
> 
> Hope that's close enough to what you were asking, or at least gives you a 
> starting place  :-),
> 
> Alex.
> 
> On 04/11/2021 20:49, Roger Guay via use-livecode wrote:
>> I simply want to be able to move the insertion iBeam in a focused field left 
>> and right, one char at a time (just like the left and right arrows keys), 
>> and then to delete the char in front of it (just like the Delete key). The 
>> dictionary was again of no use to me. Can someone please provide sample 
>> scripts?
>> 
>> Thanks,
>> Roger
>> ___
>> use-livecode mailing list
>> use-livecode@lists.runrev.com
>> Please visit this url to subscribe, unsubscribe and manage your subscription 
>> preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
> 
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-04 Thread Alex Tweedly via use-livecode

Hi Roger,

I'm not sure I properly understand your question.

here's a code snippet the moves the insertion point (in this sample, 
typing an 'f' moves it forward, 'b' moves it back). (Note this also 
works if there is some text selected - it moves the insertion to just 
after the selection, just like the arrow key does).



on keydown p
   local t
   switch p
  case  "f"
 put word 4 of the selectedchunk into t
 select after char (t+1) of me
 break
  case "b"
 put word 2 of the selectedchunk into t
 select before char (t-1) of me
 break
   end  switch
end keydown

To then delete the char in front of it, you'd do something like

   put empty into char (t+1) of me

Hope that's close enough to what you were asking, or at least gives you 
a starting place  :-),


Alex.

On 04/11/2021 20:49, Roger Guay via use-livecode wrote:

I simply want to be able to move the insertion iBeam in a focused field left 
and right, one char at a time (just like the left and right arrows keys), and 
then to delete the char in front of it (just like the Delete key). The 
dictionary was again of no use to me. Can someone please provide sample scripts?

Thanks,
Roger
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-04 Thread Roger Guay via use-livecode
I think you guys have accidentally hijacked my thread.

Roger

> On Nov 4, 2021, at 3:53 PM, Richard Gaskin via use-livecode 
>  wrote:
> 
> Possibly memory corruption, but unlikely.  More likely a plugin or IDE 
> element with test code hanging around.
> 
> If only there was a way to trace message handlers so you could see where the 
> culprit lies...
> 
> http://lists.runrev.com/pipermail/use-livecode/2021-October/266125.html
> 
> :)
> 
> -- 
> Richard Gaskin
> Fourth World Systemsaccidentally
> 
> 
> Bob Sneidar wrote:
> 
>> I just searched for Carol in ANYTHING in ALL OBJECTS in my stack. The word 
>> Carol is in nothing. Memory corruption anyone???
>> Bob S
>>> On Nov 4, 2021, at 15:22 , Bob Sneidar via use-livecode >> lists.runrev.com> wrote:
>>> OK I tried sending put the selectedChunk in one second in an openField 
>>> handler in a field. What I get... (you may want to sit down for this...) 
>>> is: Bob
>>> Carol
>>> That exists precicely NO WHERE IN MY APPLICATION! Bob S
> 
> 
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-04 Thread Richard Gaskin via use-livecode
Possibly memory corruption, but unlikely.  More likely a plugin or IDE 
element with test code hanging around.


If only there was a way to trace message handlers so you could see where 
the culprit lies...


http://lists.runrev.com/pipermail/use-livecode/2021-October/266125.html

:)

--
Richard Gaskin
Fourth World Systems


Bob Sneidar wrote:


I just searched for Carol in ANYTHING in ALL OBJECTS in my stack. The word 
Carol is in nothing. Memory corruption anyone???

Bob S



On Nov 4, 2021, at 15:22 , Bob Sneidar via use-livecode  wrote:

OK I tried sending put the selectedChunk in one second in an openField handler in a field. What I get... (you may want to sit down for this...) is: 


Bob
Carol

That exists precicely NO WHERE IN MY APPLICATION! 


Bob S



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-04 Thread Bob Sneidar via use-livecode
I just searched for Carol in ANYTHING in ALL OBJECTS in my stack. The word 
Carol is in nothing. Memory corruption anyone???

Bob S


> On Nov 4, 2021, at 15:22 , Bob Sneidar via use-livecode 
>  wrote:
> 
> OK I tried sending put the selectedChunk in one second in an openField 
> handler in a field. What I get... (you may want to sit down for this...) is: 
> 
> Bob
> Carol
> 
> That exists precicely NO WHERE IN MY APPLICATION! 
> 
> Bob S
> 
> 
>> On Nov 4, 2021, at 13:49 , Roger Guay via use-livecode 
>>  wrote:
>> 
>> I simply want to be able to move the insertion iBeam in a focused field left 
>> and right, one char at a time (just like the left and right arrows keys), 
>> and then to delete the char in front of it (just like the Delete key). The 
>> dictionary was again of no use to me. Can someone please provide sample 
>> scripts?
>> 
>> Thanks,
>> Roger
> 
> 
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: Control of Text Fields.

2021-11-04 Thread Bob Sneidar via use-livecode
OK I tried sending put the selectedChunk in one second in an openField handler 
in a field. What I get... (you may want to sit down for this...) is: 

Bob
Carol

That exists precicely NO WHERE IN MY APPLICATION! 

Bob S


> On Nov 4, 2021, at 13:49 , Roger Guay via use-livecode 
>  wrote:
> 
> I simply want to be able to move the insertion iBeam in a focused field left 
> and right, one char at a time (just like the left and right arrows keys), and 
> then to delete the char in front of it (just like the Delete key). The 
> dictionary was again of no use to me. Can someone please provide sample 
> scripts?
> 
> Thanks,
> Roger


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Control of Text Fields.

2021-11-04 Thread Roger Guay via use-livecode
I simply want to be able to move the insertion iBeam in a focused field left 
and right, one char at a time (just like the left and right arrows keys), and 
then to delete the char in front of it (just like the Delete key). The 
dictionary was again of no use to me. Can someone please provide sample scripts?

Thanks,
Roger
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode