Replying to myself ...
No - that's the wrong version you pasted in ... it should have been
A simple fix is to do
[code]
on mouseup
if (word 2 of the selectedChunk) <= (word 4 of the selectedChunk) then -- there is a selection
type space
end if
delete char (word 4 of the selectedChunk) of the ...
Search found 4 matches
- Sun Nov 14, 2021 10:25 am
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Control of Text Fields
- Replies: 31
- Views: 30170
- Sun Nov 14, 2021 12:10 am
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Control of Text Fields
- Replies: 31
- Views: 30170
Re: Control of Text Fields
Ken,
you suggested a simpler version for the Del button, namely
[code]
on mouseUp
delete char (word 4 of the selectedChunk) of the focusedObject
end mouseUp
[/code]
but this doesn't work correctly in the case of an active text selection; the desired (correct) effect in that case is to delete the ...
you suggested a simpler version for the Del button, namely
[code]
on mouseUp
delete char (word 4 of the selectedChunk) of the focusedObject
end mouseUp
[/code]
but this doesn't work correctly in the case of an active text selection; the desired (correct) effect in that case is to delete the ...
- Mon Nov 08, 2021 1:40 am
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Control of Text Fields
- Replies: 31
- Views: 30170
Re: Control of Text Fields
As discussed in more detail on the use-list, there are a number of flaws with this approach to emulating the arrow/del/f-del keys, to the point that this is basically unusable.
I've changed the scripts for those keys in this modified version. (Can't quite figure out Richmond's naming scheme - so I ...
I've changed the scripts for those keys in this modified version. (Can't quite figure out Richmond's naming scheme - so I ...
- Wed Jul 29, 2020 8:15 pm
- Forum: Talking LiveCode
- Topic: Using external script only stack as behaviour
- Replies: 47
- Views: 60918
Re: Using external script only stack as behaviour
You really don't want to "start using stack ..." for a behaviour stack.
That starts using it as a library stack, putting it in the back of the message path - and therefore those handlers will be called (out of context) if the message is not handled elsewhere.
It is enough to ensure the stack is in ...
That starts using it as a library stack, putting it in the back of the message path - and therefore those handlers will be called (out of context) if the message is not handled elsewhere.
It is enough to ensure the stack is in ...