menubuilding
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
menubuilding
Why this works:
on menuPick theItem
if theItem is "exit" then close the defaultStack
else if theItem is "save" then save the defaultStack
end menuPick
and this not:
if theItem is "preferences then launch preferences
and the same for about and others.\
and what to do with "save as"
Where can I finf the essentials about menubuilding
on menuPick theItem
if theItem is "exit" then close the defaultStack
else if theItem is "save" then save the defaultStack
end menuPick
and this not:
if theItem is "preferences then launch preferences
and the same for about and others.\
and what to do with "save as"
Where can I finf the essentials about menubuilding
Re: menubuilding
Hi Rob,
1. when using "menupick" you better use the SWITCH syntax, easier to mainatin and much more readable:
2.
Is it stack? Is it a file? "launch" is for external files!
In other words, what do you exspect to happen in that case?
3.
http://www.hyperactivesw.com/revscriptc ... ences.html
The other stacks are not too bad either!
Best
Klaus
1. when using "menupick" you better use the SWITCH syntax, easier to mainatin and much more readable:
Code: Select all
on menuPick tItem
switch tItem
case "exit"
close the defaultStack
break
case "save"
save the defaultStack
break
case "copy"
copy
break
##etc...
end switch
end menuPick
Well, WHAT is "preferences" here?if theItem is "preferences then launch preferences
Is it stack? Is it a file? "launch" is for external files!
In other words, what do you exspect to happen in that case?

3.
Check the appropriate stack here:Where can I find the essentials about menubuilding
http://www.hyperactivesw.com/revscriptc ... ences.html
The other stacks are not too bad either!

Best
Klaus
Re: menubuilding
Klaus, very good advises!
1. when using "menupick" you better use the SWITCH syntax. OK, done.
2. Well, WHAT is "preferences" here? : I want the optionsmenu as is mostly under EDIT and the same for Help/about.
3.hyperactivesw.com: a nice place to be and veryuseful it seems.
Gdday
Rob
1. when using "menupick" you better use the SWITCH syntax. OK, done.
2. Well, WHAT is "preferences" here? : I want the optionsmenu as is mostly under EDIT and the same for Help/about.
3.hyperactivesw.com: a nice place to be and veryuseful it seems.
Gdday
Rob
Re: menubuilding
Dag Rob,
On the Mac, things are a bit different as you will see, check the stack at the url!
But my actual question is: what should happen when the user selects that menuitem?
Best
Klaus
yes, sure, the menu should be at the correct "position" in the menus.robm80 wrote:2. Well, WHAT is "preferences" here? : I want the optionsmenu as is mostly under EDIT and the same for Help/about.
On the Mac, things are a bit different as you will see, check the stack at the url!
But my actual question is: what should happen when the user selects that menuitem?
Best
Klaus
Re: menubuilding
Well the optionsmenu must open like here in the picture; and the same for About:But my actual question is: what should happen when the user selects that menuitem?
Re: menubuilding
Dag Rob,
as you might have guessed, the LC "preferences" and "About" dialogs are just STACKS!
So create YOUR "preferences" and "about" sub-stack and display them when the user
selects the appropriate menu items
Best
Klaus
as you might have guessed, the LC "preferences" and "About" dialogs are just STACKS!

So create YOUR "preferences" and "about" sub-stack and display them when the user
selects the appropriate menu items

Best
Klaus