Please add a way to Name my own Controls

Something you want to see in a LiveCode product? Want a new forum set up for a specific topic? Talk about it here.

Moderator: Klaus

sturgis
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 1685
Joined: Sat Feb 28, 2009 11:49 pm

Re: Please add a way to Name my own Controls

Post by sturgis » Thu Sep 15, 2011 2:38 pm

To open the app browser, in the message box I put

Code: Select all

open stack "revApplicationOverview"
Should be easy to code a button that will toggle it open and closed.

To find the name of the stack to open was easy enough too. I opened the app browser, and in the message box executed

Code: Select all

 put the openstacks
and there it was.
The returned list was:
  • Message Box
    revTools
    revApplicationOverview
    revMenubar
    revNewScriptEditor 1

BarrySumpter
Posts: 1201
Joined: Sun Apr 24, 2011 2:17 am

Re: Please add a way to Name my own Controls

Post by BarrySumpter » Thu Sep 15, 2011 10:20 pm

Sorry thats just too complicated. ;-)
Can you put that into laymans terms so I can better understand where you're coming from. ;-)

As always the LiveCode solution is embarassingly simple.
All my best,
Barry G. Sumpter

Deving on WinXP sp3-32 bit. LC 5.5 Professional Build 1477
Android/iOS/Server Add Ons. OmegaBundle 2011 value ROCKS!
2 HTC HD2 Latest DorimanX Roms
Might have to reconsider LiveCode iOS Developer Program.

BarrySumpter
Posts: 1201
Joined: Sun Apr 24, 2011 2:17 am

Re: Please add a way to Name my own Controls

Post by BarrySumpter » Thu Sep 15, 2011 10:32 pm

Well the other embarassing thing is
I don't know how to open my revBGS.livecode in LiveCode for editiing.

revBGS doesn't appear in the App Browser.
So I probably need a msgbox script to open it.

I just started using "Hide Plugins Patch.rev"
to hide the Data Grid Helper stacks in the App Browser.

I wonder if I've inadvertantly done something with the Hide Plugins Patch.

If I can get some help opening my project I'll add an instructions card to it.

LOL

How embarassing.
All my best,
Barry G. Sumpter

Deving on WinXP sp3-32 bit. LC 5.5 Professional Build 1477
Android/iOS/Server Add Ons. OmegaBundle 2011 value ROCKS!
2 HTC HD2 Latest DorimanX Roms
Might have to reconsider LiveCode iOS Developer Program.

bn
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 4163
Joined: Sun Jan 07, 2007 9:12 pm

Re: Please add a way to Name my own Controls

Post by bn » Thu Sep 15, 2011 10:53 pm

Hi Barry,

since you prefixed your stack with rev it will not show in the application browser unless you go to preferences-> General and check -> Livecode UI elements appear in lists of stacks

then the application browser shows your stack and you can start editing it from there.

Kind regards

Bernd

BarrySumpter
Posts: 1201
Joined: Sun Apr 24, 2011 2:17 am

Re: Please add a way to Name my own Controls

Post by BarrySumpter » Thu Sep 15, 2011 11:30 pm

Thanks Bernd.
Much appreciated.

I can get to the script via the AppBrowser.
I can move the existing controls around.

But I can't seem to add a label to enter my instructions.

I think its something to do with the:
Palette this stack
Last edited by BarrySumpter on Thu Sep 15, 2011 11:43 pm, edited 1 time in total.
All my best,
Barry G. Sumpter

Deving on WinXP sp3-32 bit. LC 5.5 Professional Build 1477
Android/iOS/Server Add Ons. OmegaBundle 2011 value ROCKS!
2 HTC HD2 Latest DorimanX Roms
Might have to reconsider LiveCode iOS Developer Program.

bn
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 4163
Joined: Sun Jan 07, 2007 9:12 pm

Re: Please add a way to Name my own Controls

Post by bn » Thu Sep 15, 2011 11:35 pm

Hi Barry,

from the message box issue:

toplevel stack "myPalettedStack"

and it will leave palette mode and be fully editable.

Kind regards

Bernd

BarrySumpter
Posts: 1201
Joined: Sun Apr 24, 2011 2:17 am

Re: Please add a way to Name my own Controls

Post by BarrySumpter » Thu Sep 15, 2011 11:44 pm

sorry should have mentioned I did the right click on the app browser for my stack and selected top level.
Still no joy.

Will try the msgbox as see what happens.
---
Nope.
I get this sometimes on my normal unpalatted stacks.
I usually just restart LiveCode and all is well.

I wonder if I should rename the stack to BGSrev and save as BGSrev in say PluginsBackup.
Then when updating open only the BGSrev, make my updates, and save to plugins folder as revBGS.
Last edited by BarrySumpter on Thu Sep 15, 2011 11:56 pm, edited 1 time in total.
All my best,
Barry G. Sumpter

Deving on WinXP sp3-32 bit. LC 5.5 Professional Build 1477
Android/iOS/Server Add Ons. OmegaBundle 2011 value ROCKS!
2 HTC HD2 Latest DorimanX Roms
Might have to reconsider LiveCode iOS Developer Program.

bn
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 4163
Joined: Sun Jan 07, 2007 9:12 pm

Re: Please add a way to Name my own Controls

Post by bn » Thu Sep 15, 2011 11:55 pm

Hi Barry,

I don't know why you want to prefix your plug-in stack with rev. You get into all kinds of trouble since the rev prefix is for Runrev stacks: IDE etc. They use this to do all sort of behind the back magic.

You can name a plug-in anything you want it will work just as well.

Kind regards

Bernd

BarrySumpter
Posts: 1201
Joined: Sun Apr 24, 2011 2:17 am

Re: Please add a way to Name my own Controls

Post by BarrySumpter » Fri Sep 16, 2011 12:09 am

bn wrote:... You get into all kinds of trouble since the rev prefix is for Runrev stacks: IDE etc. They use this to do all sort of behind the back magic. ...
Yeah, getting into all the kinds of trouble now. LOL
I'm sure that was me trying to be smart and testing by trial and error.

I think I've really mucked up my stack now.
Can't get it to act like a normal stack.
Have found that a ctrl-shift right-MouseClick gets me my contect popups (edit script, property inspector, etc.)
But still can't drop a label on it.

Looks like I'll have to start a new stack and copy everything over to it and NOT EVER save with a rev prefix again.

What a pickle.
All my best,
Barry G. Sumpter

Deving on WinXP sp3-32 bit. LC 5.5 Professional Build 1477
Android/iOS/Server Add Ons. OmegaBundle 2011 value ROCKS!
2 HTC HD2 Latest DorimanX Roms
Might have to reconsider LiveCode iOS Developer Program.

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

Re: Please add a way to Name my own Controls

Post by mwieder » Fri Sep 16, 2011 12:12 am

Barry- yes, you do have to toplevel your stack if you want to add controls to it. I haven't tried this from the App Browser, but it does work from the message box. Note that you may indeed have problems updating a stack already in your plugins folder, especially if it's already in use as a plugin. I've found that the safest thing sometimes is to move it out of the plugins folder, toplevel it, do the editing, set it back to palette (or do this in the preopenstack handler), and then move it back into the plugins folder. ymmv.

BarrySumpter
Posts: 1201
Joined: Sun Apr 24, 2011 2:17 am

Re: Please add a way to Name my own Controls

Post by BarrySumpter » Fri Sep 16, 2011 12:23 am

Have topleveled,
have renamed stack to BGSrev and saved as BGSrev,
have removed BGSrev and revBGS from plugins folder
---- to Plugins Backup folder (at the same level as Plugsinsfolder),
have restarted LiveCode,
have opened BGSrev, topleveled and still won't allow me to drop a label.

Have started new MainStack and have to copy all one object and script at a time.
Lucky its only 4 buttons so far and about 6 tabs of script.


I don't think I need the palette either.

But just found this as well:
http://lists.runrev.com/pipermail/use-l ... 12923.html
How to edit a palette?

Contextual menus not working for me either... but for years I have put
toggles on palette windows during dev... this works great: make it a
check box btn ( if you want to see it) or make it transparent,
borderless, nameless btn in some location you can remember (if you
don't like to see it on the interface... later if you forget you can
find it in the application overview)

Code: Select all

on mouseup
   if the mode of this stack is 4 then
     toplevel this stack
   else
     palette this stack
   end if
end mouseup

or "remotely" from another stack, say stack "Dev Tools" which has a 
button:

"Edit Favorites Window"

on mouseup
   if the mode of stack "Favorites" is 4 then
     toplevel stack "Favorites" ## allows editing
   else
     palette stack "Favorites" ## restore to palette
   end if
end mouseup
All my best,
Barry G. Sumpter

Deving on WinXP sp3-32 bit. LC 5.5 Professional Build 1477
Android/iOS/Server Add Ons. OmegaBundle 2011 value ROCKS!
2 HTC HD2 Latest DorimanX Roms
Might have to reconsider LiveCode iOS Developer Program.

BarrySumpter
Posts: 1201
Joined: Sun Apr 24, 2011 2:17 am

Re: Please add a way to Name my own Controls

Post by BarrySumpter » Fri Sep 16, 2011 12:55 am

With the Save, How can I send file | Save to the revMenubar?

something like this:

Code: Select all

if the mode of stack "revApplicationOverview" is not 0 then
    send "revRetainStacks" to stack "revApplicationOverview"
    send "revInitAppBrowser" to stack "revApplicationOverview"
  end if
All my best,
Barry G. Sumpter

Deving on WinXP sp3-32 bit. LC 5.5 Professional Build 1477
Android/iOS/Server Add Ons. OmegaBundle 2011 value ROCKS!
2 HTC HD2 Latest DorimanX Roms
Might have to reconsider LiveCode iOS Developer Program.

BarrySumpter
Posts: 1201
Joined: Sun Apr 24, 2011 2:17 am

Re: Please add a way to Name my own Controls

Post by BarrySumpter » Fri Sep 16, 2011 2:03 am

Ok, lost my momentum for researching this for now.

Have attached my work so far.
Attachments
BGS2.zip
(4.43 KiB) Downloaded 172 times
All my best,
Barry G. Sumpter

Deving on WinXP sp3-32 bit. LC 5.5 Professional Build 1477
Android/iOS/Server Add Ons. OmegaBundle 2011 value ROCKS!
2 HTC HD2 Latest DorimanX Roms
Might have to reconsider LiveCode iOS Developer Program.

BarrySumpter
Posts: 1201
Joined: Sun Apr 24, 2011 2:17 am

Re: Please add a way to Name my own Controls

Post by BarrySumpter » Fri Sep 16, 2011 6:00 am

well this is kind of interesting:
altPlugin
http://www.altuit.com/webs/altuit2/RunRev/default.htm
http://www.altuit.com/webs/altuit2/altP ... lugins.htm

But the altPluginBuilder plugin.rev isn't available.
Drats!
All my best,
Barry G. Sumpter

Deving on WinXP sp3-32 bit. LC 5.5 Professional Build 1477
Android/iOS/Server Add Ons. OmegaBundle 2011 value ROCKS!
2 HTC HD2 Latest DorimanX Roms
Might have to reconsider LiveCode iOS Developer Program.

BarrySumpter
Posts: 1201
Joined: Sun Apr 24, 2011 2:17 am

Re: Please add a way to Name my own Controls

Post by BarrySumpter » Fri Sep 16, 2011 6:03 am

toplevel this stack

opens the stack for editing

Is there a way to Bring To Top the AppBrowser stack?
All my best,
Barry G. Sumpter

Deving on WinXP sp3-32 bit. LC 5.5 Professional Build 1477
Android/iOS/Server Add Ons. OmegaBundle 2011 value ROCKS!
2 HTC HD2 Latest DorimanX Roms
Might have to reconsider LiveCode iOS Developer Program.

Post Reply