forward slash in Option button

Dave Cragg dcragg at lacscentre.co.uk
Fri Jun 30 06:33:05 EDT 2006


Apologies if this has been covered before.

I want to make an option button that displays a hierarchy of  
sequential directory paths (the kind of thing you see in some FTP and  
file browsers). The contents would look something like this:

   /
   /Users
   /Users/kosmo
   /Users/kosmo/mealtickets

I have 2 questions/concerns.

1.  The docs say that "/" is a special character in menu items. (To  
quote:  "Putting the / character anywhere in a line makes the next  
character the keyboard equivalent for the menu item.") This doesn't  
seem to be the case with Option menus, and they display normally.  
(And escaping with "//" displays "//".) However, I can't see this  
specifically described in the docs. Can someone confirm that this is  
the case (i.e. that / is allowed in Option menus)?

2.  On Mac OS X (Windows seems OK), if there is only a single line in  
the menu, and that is "/", then the button behaves as if there were  
no contents at all -- no menu pops up and no menuPick message is  
received. One workaround appears to be to put a space after the "/".  
But if someone knows a better way, which doesn't involve special  
parsing in the menuPick message, could you let me know.

Cheers
Dave





More information about the use-livecode mailing list