Page 2 of 6
Re: Clear the MessageBox
Posted: Mon Dec 07, 2020 12:53 pm
by richmond62
Nope; not so lucky.
Interestingly enough . . . on deleting the contents of the multiline message box thingy, reverting to the single line thingy, then
returning to the multiline one the deleted commands are NOT deleted.
So, obviously (err; not THAT obviously) this does not behave in a similar way to the single command line.
Re: Clear the MessageBox
Posted: Mon Dec 07, 2020 5:04 pm
by Thunder
richmond62 wrote: Mon Dec 07, 2020 12:53 pm
Nope; not so lucky.
Interestingly enough . . . on deleting the contents of the multiline message box thingy, reverting to the single line thingy, then
returning to the multiline one the deleted commands are NOT deleted.
So, obviously (err; not THAT obviously) this does not behave in a similar way to the single command line.
Stack :
revMessageBoxMultipleLinesMessageBehavior
Line : 45 -> command revInitialise
Line : 50 -> put revIDEGetPreference("IDEMultipleLinesMessageHistory") into lHistory
Could this be of help ? revIDEGetPreference("
IDEMultipleLinesMessageHistory")
Re: Clear the MessageBox
Posted: Mon Dec 07, 2020 6:04 pm
by richmond62
Certainly worth a look: after supper.

Re: Clear the MessageBox
Posted: Mon Dec 07, 2020 6:26 pm
by jacque
I'm still trying to figure out why one would want to delete old message box entries. I find it very convenient to begin typing a command I used a long time ago and still have it pop up immediately after only two or three characters. Must be related to work flow I guess.
The way to execute the multi-line message box is documented. I remember reading it but can't recall if it was in the dictionary or the user guide.
Re: Clear the MessageBox
Posted: Mon Dec 07, 2020 6:50 pm
by richmond62
I'm still trying to figure out why one would want to delete old message box entries.
Well, it is probably no more than a matter of taste, but the auto-complete feature on my Android phone nearly drove me round the twist until I worked out how to disable it.
And the point is, surely, that one can disable auto-complete in Android, as one should be able to in the LiveCode IDE.
Things I dislike about modern computer systems:
1. The spell check that tries to turn my perfectly acceptable "British" English into some North American dialect.
2. The spell check that tries to turn my perfectly acceptable "British" English into some North American dialect.
3. The spell check that tries to turn my perfectly acceptable "British" English into some North American dialect.
Erm . . .
Re: Clear the MessageBox
Posted: Mon Dec 07, 2020 6:55 pm
by richmond62
Um . . . this disnae wark:
-
-
Because it disnae search in IDE stacks.

Re: Clear the MessageBox
Posted: Mon Dec 07, 2020 7:00 pm
by richmond62
BUT this does:
Code: Select all
on mouseUp
set the IDEMultipleLinesMessageHistory of stack "revPreferences" to empty
end mouseUp
BIG thanks to
Thunder for something I had overlooked.

Re: Clear the MessageBox
Posted: Mon Dec 07, 2020 7:13 pm
by jacque
The spell check that tries to turn my perfectly acceptable "British" English into some North American dialect.

Go into Settings and search for "language". You should see several options. Go through them all and change each to "English (UK)". Done.
You may need to add the UK keyboard.
Re: Clear the MessageBox
Posted: Mon Dec 07, 2020 7:25 pm
by FourthWorld
jacque wrote: Mon Dec 07, 2020 6:26 pm
I'm still trying to figure out why one would want to delete old message box entries. I find it very convenient to begin typing a command I used a long time ago and still have it pop up immediately after only two or three characters. Must be related to work flow I guess.
Most other command-line consoles like Terminal provide a way to clear history (in Unix and Linux it's "history -c"). It's not used every day, but often enough to have a command for it.
I've added a note to the enhancement request to consider a new command for Message Box operations, with args for clearing history. The UI is already cumbersome, I see little benefit in making it even more visually noisy for something seldom needed. But it is useful, so a general Message Box handler with options for useful tasks may strike a good middle ground, and follow conventions anticipatable by those who enjoy command line tools like Message Box.
The way to execute the multi-line message box is documented. I remember reading it but can't recall if it was in the dictionary or the user guide.
Apparently that part of the User Guide is very old, before they started being more aware of the world outside Apple-specific keyboard layouts.
Under "LiveCode IDE" -> "Message Box" on p 501 it says:
Type valid LiveCode code into this area. In Single Line mode, separate multiple lines with; (semi-colon) and press Return to execute. In Multiple Line mode, press return to separate lines, and press Enter to execute.
No doubt that makes good sense if you happen to be using Apple hardware. But the other 85% of the world has no key labeled "Return". Instead, what Apple calls "Return" is labeled "Enter" on keyboards for all other systems, and what Apple calls "Enter" can be emulated on normal keyboards with Ctrl-Enter.
The good news is that this is consistent with how we trigger the Apply button in the Script Editor, and there are likely a few other contexts where this same convention is used consistently.
The bad news is that at least that one instance in the User Guide is incorrectly described, so I just filed a docs report on it:
https://quality.livecode.com/show_bug.cgi?id=23023
Re: Clear the MessageBox
Posted: Mon Dec 07, 2020 7:45 pm
by FourthWorld
richmond62 wrote: Mon Dec 07, 2020 9:53 am
other elements designed for internal use
The fact that LiveCode central has decided that some elements are 'designed for internal use' does not, also,
preclude the possibility of documenting them.
True, it does not preclude the
possibility of documenting IDE internals, but neither does it
obligate them to do so.
What you
really want is indeed quite practical, a way to clear MB history. Most other command line tools offer a command for that, and it seems fitting LC should as well. And when they add such a command, I would imagine they'd document it.
But what you posted immediately prior to "Why do I feel that LiveCode needs an awful lot more documentation?" was a long list of property names used internally within the IDE. Documenting all of those would not solve your problem, as doing so would not provide you with a command to clear MB history.
And as Thunder demonstrated, one of the great things we love about LC is that it's so readable it's nearly self-documenting. Even though the team didn't take hundreds of hours away from fixes and features we ask of them to create thousands of pages of documentation for internals unlikely to ever be read, the self-documenting nature of LC and the availability of LC's source code allow anyone experienced enough to use such properties to read how the IDE uses them.
Indeed, as nice as it will be for newcomers to see a MB-clearing command included right out of the box, the ease of the language means the experienced users asking for it here don't even need to wait for that: making one's own takes just a few minutes' research and two statements to write as a library or plugin we can have and enjoy right now.
Re: Clear the MessageBox
Posted: Mon Dec 07, 2020 7:54 pm
by richmond62
Documenting all of those would not solve your problem
No, that's true: it would solve neither 'my problem' (and that's something for my wife to deal with, not LiveCode),
nor anything else, and I was NOT proposing a monster set of preferences that would allow end-users to bugger up the
whole IDE: ALL I was doing was demonstrating how much stuff there is "under the hood' of LiveCode (which, even
if nothing else, should make us all appreciate the vast work done by Kevin, Mark and the other workers at the coal face).
Re: Clear the MessageBox
Posted: Mon Dec 07, 2020 8:00 pm
by richmond62
-
Just to be a complete pain in the bum (OK, that's nothing new), I should like to point out that 3
Apple keyboards
I use on on a regular basis have
NO keys labelled either
RETURN or
ENTER.
Re: Clear the MessageBox
Posted: Tue Dec 08, 2020 8:26 pm
by richmond62
-
Mockup.

Re: Clear the MessageBox
Posted: Tue Dec 08, 2020 9:11 pm
by chipsm
Interesting idea. I like it.
Re: Clear the MessageBox
Posted: Tue Dec 08, 2020 10:58 pm
by FourthWorld
Much better than adding more complexity to the Message Box UI itself.
You could add the feature and update the docs in a pull request via GitHub.
Or you could take 15 minutes and write a two-line plugin.
I guess it depends on how quickly you'd like this. If it's not important you can wait.
It's been a good discussion, because while I don't use LC's Message Box it reminds me that I should include a way to purge history in my drop-in replacement tool. In mine, unencumbered by other considerations, I have the freedom to make it as flexible as I'd like, so I'll probably use a command with the default being to clear all of history, and options to list the full history, and to delete a specific line from history, all without leaving the keyboard.