Development :  K-Meleon Web Browser Forum
K-Meleon development related discussions. 
Pages: Previous123
Current Page: 3 of 3
Re: Macrolanguage usage
Posted by: siria
Date: January 14, 2018 08:08PM

(del)



Edited 1 time(s). Last edit at 08/12/2019 08:10AM by siria.

Options: ReplyQuote
Re: Macrolanguage usage
Posted by: siria
Date: August 12, 2019 08:16AM

Just a surprising (to me) discovery:
it's possible to get PROMPT inputs with multiple lines as infotext, not just one!!
The trick is to use injectJS and create the prompt with pure javascript:



Have missed this possibility for macros so often in the past, and now noticed it just by accident.

Okay and the catch is:
- no title as usual
- the input box is very short, even much shorter as with macro-prompts (on my system at least)
The info text defines the box width. It will wrap at the longest word or at "\n" linebreaks. If it's one superlong word, it gets CROPPED at the end:



But so far only tested with KM1.6, could be quite different on newer Systems or newer KM-versions. No idea.

(_HowTo macrolanguage prompt multiple lines)



Edited 5 time(s). Last edit at 08/12/2019 08:47AM by siria.

Attachments: PROMPT-box_MULTILINE_howto__just-use-JS-prompt.png (5.8 KB)   PROMPT-box_MULTILINE_howto__WIDTH_cropped-at-screen2.png (2.7 KB)  
Options: ReplyQuote
Re: Macrolanguage / bigger Prompt-size
Posted by: siria
Date: January 25, 2020 09:38PM

Just a little experiment, can't believe this worked - LOL!
For many years had completely forgotten about good old ResHacker, until just recently stumbling across it again. Now wanted to check if it possibly might allow to increase the oh so tiny readfile/injectJS-return limits in older KM-versions. No luck with this, the only thing it offers me to modify in macros.dll is the prompt dialogue. Okay, this has always been far too tiny too, just half a single line! So just pulled the boxes bigger with the mouse, just for fun - and it works! ROFL...



Well, only partly so far:
Unlike the pure javascript-prompts, the height of the "info text" is fix, not flexible. Anyone know if this can be changed in the ResHacker code lines? (see attached file with dll+screenshot)
And the input field is still just 1 line, not a multiline-textarea. But probably better to remain that way. A multiline-input would need a new function name, since macros do expect only 1-liners from prompts.



Edited 2 time(s). Last edit at 01/25/2020 09:42PM by siria.

Attachments: macros-dll_KM16b26_MOD_PromptSize_ResHacker.7z (61.1 KB)   macros_KM16b26_PromptSize_ResHacker_2.png (6.6 KB)  
Options: ReplyQuote
Re: Macrolanguage / bigger Prompt-size
Posted by: JohnHell
Date: January 25, 2020 11:02PM

Just edit the control and enable multiline and scroll.

CTRL+ENTER would be to create new line, or you can enable the es_wantreturn and only when pressing ok would be sent.

Never did this but playing a little was easy to find.



Edited 1 time(s). Last edit at 01/25/2020 11:02PM by JohnHell.

Options: ReplyQuote
Pages: Previous123
Current Page: 3 of 3


K-Meleon forum is powered by Phorum.