Hi Ken,
This took me by surprise so I just did a test. Pasted text into a field
then clicked on another field on the card and I did get a closeField, so
maybe this was a bug that has been fixed? LC 4.6.3/OS X 10.6.8
Pete
Molly's Revenge http://www.mollysrevenge.com
On Tue, Oct 25, 2011 at
I guess that works but it means the button script will execute before the
focus on nothing in the card script which could be an issue, depending on
the application requirements.
Pete
Molly's Revenge http://www.mollysrevenge.com
On Wed, Oct 26, 2011 at 9:09 AM, Bob Sneidar b...@twft.com wrote:
How about inserting the mouseUp handler into the frontScript. That should run
before the button script then. Make sure to pass mouseUp though! Here is what I
did:
Create a button called btnFrontScript
in the script of that button put
on mouseUp
focus on nothing
pass mouseUp
end mouseUp
in
On Oct 26, 2011, at 11:29 AM, Pete wrote:
Hi Ken,
This took me by surprise so I just did a test. Pasted text into a field
then clicked on another field on the card and I did get a closeField, so
maybe this was a bug that has been fixed? LC 4.6.3/OS X 10.6.8
Well whaddaya know? You're
I'm glad they fixed it, 'cause that didn't seem right!
Pete
Molly's Revenge http://www.mollysrevenge.com
On Wed, Oct 26, 2011 at 2:44 PM, Ken Ray k...@sonsothunder.com wrote:
On Oct 26, 2011, at 11:29 AM, Pete wrote:
Hi Ken,
This took me by surprise so I just did a test. Pasted text
Message: 10
Date: Wed, 26 Oct 2011 15:05:09 -0700
From: Pete p...@mollysrevenge.com
To: How to use LiveCode use-livecode@lists.runrev.com
Subject: Re: When has a field changed?
Message-ID:
CABx6j9k5s_42TG85A-HL_yMoGD9cccKtQbD=bk9rbomadua...@mail.gmail.com
Content-Type: text/plain
I have a text field (unlocked) that the user can edit, but I want to know when
and to deal with the changes.
Here is what I have come up with, something of a kludge. Is there a cleaner way?
on mouseEnter --Enter the field
set the textChange of me to false
end mouseEnter
on rawkeydown tKey
Sorry to say Jim, but I had the same problem on my hands last year and ended
up doing pretty much as you have done, but I never asked the list for help, so
I'll be interested in seeing where this leads. (smile)
Joe Wilkins
Architect
On Oct 25, 2011, at 2:21 PM, James Hurley wrote:
I have a
yes. on closeField. However be aware that clicking a button before tabbing out
of the field will NOT send a closeField to an edited field. Someone sent me a
workaround for that, but I cannot find it right now. I am sure it is in the
archives. Note that exitField is sent when a field loses
Hi James,
Am 25.10.2011 um 23:21 schrieb James Hurley:
I have a text field (unlocked) that the user can edit, but I want to know
when and to deal with the changes.
Here is what I have come up with, something of a kludge. Is there a cleaner
way?
on mouseEnter --Enter the field
...
end
'closeField' is your friend here...
Dixie
Subject: When has a field changed?
From: jhurley0...@sbcglobal.net
Date: Tue, 25 Oct 2011 14:21:56 -0700
To: use-livecode@lists.runrev.com
I have a text field (unlocked) that the user can edit, but I want to know
when and to deal
James,
// this is a field script, providing
// a safe way to check if a field has changed
local lHash
local lHasChanged
on openField
put md5Digest(the text of me) into lHash
pass openField
end openField
on closeField
checkHash
pass closeField
end closeField
// depending on the purpose
Hi James,
In addition to my previous field script, for your button:
on mouseUp
if the changed of fld Whatever is true then
// continue
end if
end mouseUp
--
Best regards,
Mark Schonewille
Economy-x-Talk Consulting and Software Engineering
Homepage: http://economy-x-talk.com
Twitter:
On 10/25/11 6:48 PM, James Hurley wrote:
I worry about the size of the field text that it would be hashing. It
would be book length.
I don't have that much in there at present, so I can't test it, but
that is the ultimate goal.
I'd just use closefield myself. The bug with the buttons was a
In the button script you could put select empty in the first line. That
should cause the field's closeField handler to fire before the rest of the
button script.
Terry...
On 26/10/2011, at 10:48 AM, James Hurley wrote:
Mark,
Well there's another RR command (md5hash) I was unaware of.
I
James,
The button click/closeField problem happens because, on OS X anyway, the
filed doesn;t lose focus when you click on the button (you'll see the cursor
is still in it). Put focus on nothing at the top of your button's
mouseDown handler. That removes focus from the field thus causing the
Actually, the workaround I was thinking of trapped mouseUp in the card or stack
handler, then used the command focus on nothing. This will force the loss of
focus by the field thereby forcing a closeField to be sent to the field that
lost the focus.
This way you can use closeField in fields,
field...
Cheers,
- Boo
-Original Message-
From: Bob Sneidar
Sent: Tuesday, October 25, 2011 7:08 PM
To: How to use LiveCode
Subject: Re: When has a field changed?
Actually, the workaround I was thinking of trapped mouseUp in the card or
stack handler, then used the command focus
On Oct 25, 2011, at 7:30 PM, Keith (Gulf Breeze Ortho Lab) wrote:
Hi All,
Was following this thread and tried the instructions (see below), just for
the fun of it, and it worked fine. I set a bogus field so that it was not
visible, then simply set the focus to this hidden field upon
Thanks all. Problem solved.
The closeField is triggered only when the field is changed and the focus is
changed to something outside the field.
The only problem is when the next selection is a button (on the Mac at least)
the focus remains in the field.
The work around, as several pointed
On 10/25/11 11:24 PM, James Hurley wrote:
It appears to make no difference whether the traversalOn is true or
false for the button, which seems a bit odd.
Yeah. I misspoke. It's auto-hilite that matters. But then you have to
write your own hiliting handlers, so the focus solution is much
21 matches
Mail list logo