Resizing script editor variable pallets

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller

mcelvain
Posts: 58
Joined: Sat Apr 29, 2023 10:13 pm

Re: Resizing script editor variable pallets

Post by mcelvain » Fri May 26, 2023 7:11 pm

I really enjoy reading this conversation among folks who know what they’re talking about !

Also enjoy looking under the hood in products you’ve authored.

All I know is that you’ll eventually age, as I have; needing bigger text sizes to read your previous work.

And nothing is more pressing than following the value of a variable through successive lines of code.

Maybe there’s a way to RevSpeak the value of a given variable with mouseloc in hotspot or something.

FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 9853
Joined: Sat Apr 08, 2006 7:05 am
Location: Los Angeles
Contact:

Re: Resizing script editor variable pallets

Post by FourthWorld » Fri May 26, 2023 7:34 pm

mcelvain wrote:
Fri May 26, 2023 7:11 pm
All I know is that you’ll eventually age, as I have; needing bigger text sizes to read your previous work.
Someone please tell that to the 20-somethings running Google's Maps team. ;)
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn

mwieder
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3581
Joined: Mon Jan 22, 2007 7:36 am
Location: Berkeley, CA, US
Contact:

Re: Resizing script editor variable pallets

Post by mwieder » Sun May 28, 2023 7:10 am

LOL.
I do want to say, though, that PowerDebug has the option to change the text font and size for both the variables display and the script view.

mcelvain
Posts: 58
Joined: Sat Apr 29, 2023 10:13 pm

Re: Resizing script editor variable pallets

Post by mcelvain » Mon May 29, 2023 1:51 am

Since my temporary workaround to make debugger variables easier to see is to write them to a field or table on my left monitor with BIG text, and since a script can store itself in a variable, I can do this if I know which line of script is being read; both globals and locals can be distilled from the handler within the script I'm calling.

Is there a command that returns the number of the script line currently being executed ?

mwieder
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3581
Joined: Mon Jan 22, 2007 7:36 am
Location: Berkeley, CA, US
Contact:

Re: Resizing script editor variable pallets

Post by mwieder » Mon May 29, 2023 2:24 am

Not a command, but if you catch the trace or traceBreak messages in a frontscript you get the proper arguments.

Code: Select all

on trace pHandlerName, pLineNumber, pDepth
on traceBreak pHandlerName, pLineNumber, pDepth

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7257
Joined: Sat Apr 08, 2006 8:31 pm
Location: Minneapolis MN
Contact:

Re: Resizing script editor variable pallets

Post by jacque » Mon May 29, 2023 4:40 am

I think you said you were on a Mac. Cmd-Opt-+ (plus) zooms the screen, and Cmd-Opt-- (minus) reduces it. That might be easier than moving text around.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

mcelvain
Posts: 58
Joined: Sat Apr 29, 2023 10:13 pm

Re: Resizing script editor variable pallets

Post by mcelvain » Mon May 29, 2023 8:39 am

Thank-you for the suggestion to try your trace code in a frontscript, Mweider.

I will do that.

Jacque, I constantly use Cmd-Opt-(+/-).

Constantly.

Unfortunately, my hand joint bursae are taking their cues from my retinal membranes.

In fact, the reason I’m firing off questions is that I plan to write iPhone personal aps that render the device into a much-needed assistant.

Siri and Alexa aps are way too general, and their information collecting:dispensing ratio seems lopsided.

Not sure how A.I. will decide how to self-define long-term.

mwieder
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3581
Joined: Mon Jan 22, 2007 7:36 am
Location: Berkeley, CA, US
Contact:

Re: Resizing script editor variable pallets

Post by mwieder » Mon May 29, 2023 6:10 pm

Here's the tl;dr of how I go from debugger to script editor. ymmv.

Code: Select all

/**
* editScriptAt
*
* pSelection : chunk - "char start to end of line n"
* pObject : name of object to be edited
*/
constant kIDEScriptEditor = "revNewScriptEditor 1"
private command editScriptAt pSelection, pObject
   local tChunk
   local tScriptEditor
   
   lock screen
   put kIDEScriptEditor into tScriptEditor
   
   try
      if pObject is not empty then
         edit the script of pObject
         put word 2 of pSelection,word 4 of pSelection into tChunk
         send "goLine" && word -1 of pSelection, "position", tChunk to group "Editor" of stack tScriptEditor in 10 milliseconds
      end if
   catch tJunk
      answer tJunk
      set the traceabort to true
   end try
   unlock screen
end editScriptAt

mcelvain
Posts: 58
Joined: Sat Apr 29, 2023 10:13 pm

Re: Resizing script editor variable pallets

Post by mcelvain » Fri Jun 02, 2023 7:31 am

Very interesting code; can’t wait to try it.

Reading it makes sense.

Thank-you sir !

Since a re-install lies awaiting for my previous mutilation of mb, doing same to script editor is not fatal.

I’d still like to look under the hood of some of these toolkit stacks.

Post Reply

Return to “Getting Started with LiveCode - Complete Beginners”