See both variables and code in the debugger?

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

bogs
Posts: 5435
Joined: Sat Feb 25, 2017 10:45 pm

Re: See both variables and code in the debugger?

Post by bogs » Sat Jan 09, 2021 9:13 pm

FourthWorld wrote:
Sat Jan 09, 2021 7:29 pm
..but not as a tear-off window.

Never mind me, I was just making an obscure joke about the obscure joke that is the US software patent system (besides, it's been so long I'm pretty sure that old Adobe patent has expired by now).
Good one, I wouldn't count on a patent having expired yet though, I think you have to wait till just after the big bang starts again for that to come around... :P
jacque wrote:
Sat Jan 09, 2021 7:10 pm
You're right, maybe it's just me who calls it toolbar.
Actually, that was what I initially called it too, until I found Mc. Mc made it pretty clear that what you have there is a "Menu Bar" :mrgreen:
aPic_menuBar or not menuBar.png
It has a menu, belly up to the bar...
aPic_menuBar or not menuBar.png (8.71 KiB) Viewed 5644 times
Image

MichaelBluejay
Posts: 222
Joined: Thu Jul 01, 2010 11:50 am

Re: See both variables and code in the debugger?

Post by MichaelBluejay » Sun Jan 10, 2021 4:26 am

I don't have a toolbar on top of my screen. I just have a menubar, same as all my other apps. As I said, I'm on MacOS, using LC Community Edition 9.6.2-rc-1. The way I group items is to select them and then go to the Object menu and choose Group Selected.

I set the User Extensions path in Preferences to /My Stuff/Programming/LiveCode/Plugins, put the Variable Monitor plugin there, and restarted, but Variable Monitor still doesn't show up in Development > Plugins.

One problem leads to another. I started out with difficult debugging because someone made the ridiculous decision to have the variable list and code pane to compete for space. I tried to fix that by downloading a plugin (that someone generously made) only to have problems finding out where to download it and navigating Sample Stacks once I found it. Then once I downloaded it I can't get it to actually load in LC.

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: See both variables and code in the debugger?

Post by mwieder » Sun Jan 10, 2021 5:22 am

Michael-

There's one more annoying step you need (and I really wish this were better documented and/or an easier way to do this)

If you've placed the plugin into /My Stuff/Programming/LiveCode/Plugins then

from the menubar select LiveCode | Preferences...
from the panel that pops up select "Files and Memory"
down at the bottom under "User Extensions" either type or click the "..." button to select /My Stuff/Programming/LiveCode

Note that you need to select the folder that *contains* the Plugins folder, not the Plugins folder itself.

Now relaunch LiveCode and you should see the plugin under the Development | Plugins menu.
And you can put other plugin stacks in the Plugins folder and they'll appear as well.

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: See both variables and code in the debugger?

Post by mwieder » Sun Jan 10, 2021 6:12 am

...and of course I'd be remiss if I didn't mention that PowerDebug (see my sig) displays variables in a separate window.
Among its many other improvements <g>. Did I mention code profiling?

Cheers.

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

Re: See both variables and code in the debugger?

Post by jacque » Sun Jan 10, 2021 6:33 am

bogs wrote:
Sat Jan 09, 2021 9:13 pm
Actually, that was what I initially called it too, until I found Mc. Mc made it pretty clear that what you have there is a "Menu Bar" :mrgreen:
Right, but MC's is actually a menu. It combined the menu with the tools; it has File, Edit, etc. on WIndows and Linux (which is where it was originally developed.) Macs have a separate system menu. I think I started calling it a toolbar because my clients mostly use Macs and if I tell them to look at the menu bar they go all the way up to the top of the monitor.

If you look at the View menu on a Mac, there are options to toggle on/off Toolbar Text and Toolbar Icons. Might be that way on Windows/Linux too.

Speaking of which, @Michael -- if you don't see the toolbar on your Mac, look in the View menu and toggle on both those options. You may have hidden it inadvertently at some point.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

MichaelBluejay
Posts: 222
Joined: Thu Jul 01, 2010 11:50 am

Re: See both variables and code in the debugger?

Post by MichaelBluejay » Sun Jan 10, 2021 8:47 am

@mwieder, that did the trick, thanks! I'm finally able to see Variable Monitor. LC ought to be smart enough to check the current folder for Plugins if it's named "Plugins".

@Most everyone else: The icon-based toolbar you've been talking about is a toolbar, not a menubar. LC calls it a toolbar. If you say "dog" when you mean "cat", it's bound to cause some confusion.

@Andy: Thank you very much for making Variable Monitor. Unfortunately the separate window for monitoring a multiline variable doesn't update, even if I click the Refresh button.

AndyP
Posts: 615
Joined: Wed Aug 27, 2008 12:57 pm
Location: Seeheim, Germany (ex UK)
Contact:

Re: See both variables and code in the debugger?

Post by AndyP » Sun Jan 10, 2021 9:15 am

[quote=MichaelBluejay post_id=200227 time=1610264866 user_id=558

@Andy: Thank you very much for making Variable Monitor. Unfortunately the separate window for monitoring a multiline variable doesn't update, even if I click the Refresh button.
[/quote]

Thanks for the feedback, I'll have a look at this and get back to you.
Andy Piddock
https://livecode1001.blogspot.com Built with LiveCode
https://github.com/AndyPiddock/TinyIDE Mini IDE alternative
https://github.com/AndyPiddock/Seth Editor color theming
http://livecodeshare.runrev.com/stack/897/ LiveCode-Multi-Search

MichaelBluejay
Posts: 222
Joined: Thu Jul 01, 2010 11:50 am

Re: See both variables and code in the debugger?

Post by MichaelBluejay » Sun Jan 10, 2021 12:04 pm

Andy, I'm sorry, I can't use Variable Monitor. It took the already sluggish debugger and then made it glacial. It took me a couple minutes before I could even get LC to quit so I could restart.

Now my issue is that LC won't even deign to open the script editor window. I'm reinstalling LC as we speak.

Recently it feels like I've spent more of my time battling LiveCode than actually doing any development.

Update: Reinstalling didn't work. IDE is unusable now, about to start another thread on that subject. (sigh)

Second update: Now I can't even *Quit* the app! @#$@!

AndyP
Posts: 615
Joined: Wed Aug 27, 2008 12:57 pm
Location: Seeheim, Germany (ex UK)
Contact:

Re: See both variables and code in the debugger?

Post by AndyP » Sun Jan 10, 2021 5:17 pm

MichaelBluejay wrote:
Sun Jan 10, 2021 12:04 pm
Andy, I'm sorry, I can't use Variable Monitor. It took the already sluggish debugger and then made it glacial. It took me a couple minutes before I could even get LC to quit so I could restart.

Now my issue is that LC won't even deign to open the script editor window. I'm reinstalling LC as we speak.

Recently it feels like I've spent more of my time battling LiveCode than actually doing any development.

Update: Reinstalling didn't work. IDE is unusable now, about to start another thread on that subject. (sigh)

Second update: Now I can't even *Quit* the app! @#$@!
Hmmm... I have seen no slow down on both may computers here, both running Win 10 64.

It sounds like you may have some corruption in Livecode's preferences file ..this is a well know general problem that can result in various odd and often intermittent problems. Make a backup of the preferences file and then delete the original. Please be aware that any preferences you have set such as mobile paths and plugin path will have to be re-entered again in Preferences... so make a note of these.

The location of the preferences file depends on which OS you are using, an easy way to find it's location is to use one of Livecode's environment variables. Open the Message Box and copy this then hit return.

Code: Select all

put revEnvironmentUserPreferencesPath()
record the file location returned.

SHUT DOWN LIVECODE

You will see in the folder returned above livecode7.rev this is the Livecode preferences file delete this.

When you restart Livecode this file will be recreated.

Let us know how you get on.
Andy Piddock
https://livecode1001.blogspot.com Built with LiveCode
https://github.com/AndyPiddock/TinyIDE Mini IDE alternative
https://github.com/AndyPiddock/Seth Editor color theming
http://livecodeshare.runrev.com/stack/897/ LiveCode-Multi-Search

dunbarx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 9647
Joined: Wed May 06, 2009 2:28 pm
Location: New York, NY

Re: See both variables and code in the debugger?

Post by dunbarx » Sun Jan 10, 2021 5:55 pm

Michael.

Initially, when you asked where "Sample Stacks" was, I tried to tell you. Regardless of what we now call it, a "toolBar" or what LC calls it, "revmenuBar" I still am not sure if you now have access to that, er, object, and to that actual "Sample Stacks" button.

Craig

MichaelBluejay
Posts: 222
Joined: Thu Jul 01, 2010 11:50 am

Re: See both variables and code in the debugger?

Post by MichaelBluejay » Mon Jan 11, 2021 2:55 am

@dunbarx: Like I said, I was able to find Sample Stacks in the Help menu. In my View menu, LC calls what you're referring to a "Toolbar". If I show that Toolbar, then yes, Sample Stacks is there, but that issue has been moot for a long time.

@AndyP: I'd already tried deleting Preferences when reinstalling LC didn't fix various problems, and that got the IDE usable again. It also now takes about "only" half a second to do a step in the debugger, vs. about 1.5 seconds before. Half a second is still annoyingly slow, but that's a 3x improvement over before, so I'll take it. I'm not keen on reinstalling Variable Monitor because loading it is when the problems started and I've spent far too much time already battling LC. For now I'm just opening the few variables I want to watch in floating windows which is a decent enough solution.

MichaelBluejay
Posts: 222
Joined: Thu Jul 01, 2010 11:50 am

Re: See both variables and code in the debugger?

Post by MichaelBluejay » Mon Jan 11, 2021 3:36 am

Now I'm having the problem where the line numbers in the Script Editor don't scroll.

I can fix that by closing and reopening the script editor, but then LC forgets the column width for the Variables list, and kills all my floating Variable windows.

At this point I'm wondering if it would have been faster to have just done the project in Javascript.

MichaelBluejay
Posts: 222
Joined: Thu Jul 01, 2010 11:50 am

Re: See both variables and code in the debugger?

Post by MichaelBluejay » Mon Jan 11, 2021 4:02 am

And now the debugger is ignoring my breakpoints.

MichaelBluejay
Posts: 222
Joined: Thu Jul 01, 2010 11:50 am

Re: See both variables and code in the debugger?

Post by MichaelBluejay » Mon Jan 11, 2021 4:08 am

And the hits keep coming! Capitalized variables don't get sorted into proper alphabetical order with the non-capitalized variables in the Variables list, and there's no way to change it.

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

Re: See both variables and code in the debugger?

Post by jacque » Mon Jan 11, 2021 4:36 am

MichaelBluejay wrote:
Mon Jan 11, 2021 3:36 am
Now I'm having the problem where the line numbers in the Script Editor don't scroll.

I can fix that by closing and reopening the script editor, but then LC forgets the column width for the Variables list, and kills all my floating Variable windows.
This issue has been fixed a number of times but keeps returning; I suspect it's a tricky one to fix. I've found that if I click somewhere else in the script and then hit the up or down arrow key, they usually realign. Or you can also try clicking in the handler list to jump elsewhere. If you're debugging when it happens, all you have to do is step into or over the current line and that always realigns them for me.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

Post Reply

Return to “Getting Started with LiveCode - Complete Beginners”