Does anyone have a GUI lib where the menus can extend beyond the bounds of the parent window (using a child window for the menu), and that doesn't look too different from a regular Windows interface?
GUIs
BlitzMax Forums/BlitzMax Programming/GUIs Why not use a regular menu? All you'd have to do is handle the input code to determine when to open it and then do so.
WB Noel!
Ok... I've been here for quite a while.
WB Noel!
lol..
Ontopic - Nope, don't know of any GUI lib that does that. But like cower said, why not use a regular menu?
If I understand what you're after then I think MaxGUI does this either with a normal menu, a seperate window or a child window.
A childwindow is not allowed to have a menu, it should use the menu from the parent window and can't moved outside it's parent. But yes, any other window can may serve you with a menu to do the job. Not sure how it should look like for you. Try this:
'Source Code created on 28 Aug 2007 10:41:36 with Logic Gui Version 2.2 Build 262 'Start of external Header File SuperStrict 'End Of external Header File Local Win2:TGadget = CreateWindow:TGadget("Win2",473,128,111,93,Null,WINDOW_RESIZABLE |WINDOW_MENU |WINDOW_TOOL ) Local Win2_File:TGadget = CreateMenu( "File" , 100 , WindowMenu( Win2:TGadget ) ) Local Win2_Open:TGadget = CreateMenu( "Open" , 101 , WindowMenu( Win2_File:TGadget ) ) Local Win2_Close:TGadget = CreateMenu( "Close" , 102 , WindowMenu( Win2_File:TGadget ) ) Local Win2_Exit:TGadget = CreateMenu( "Exit" , 103 , WindowMenu( Win2_File:TGadget ) ) Local Win2_Edit:TGadget = CreateMenu( "Edit" , 200 , WindowMenu( Win2:TGadget ) ) Local Win2_Cut:TGadget = CreateMenu( "Cut" , 201 , WindowMenu( Win2_Edit:TGadget ) ) Local Win2_Copy:TGadget = CreateMenu( "Copy" , 202 , WindowMenu( Win2_Edit:TGadget ) ) Local Win2_Paste:TGadget = CreateMenu( "Paste" , 203 , WindowMenu( Win2_Edit:TGadget ) ) Local Win2_Help:TGadget = CreateMenu( "Help" , 300 , WindowMenu( Win2:TGadget ) ) Local Win2_About:TGadget = CreateMenu( "About" , 301 , WindowMenu( Win2_Help:TGadget ) ) UpdateWindowMenu( Win2:TGadget ) Local Win1:TGadget = CreateWindow:TGadget("Main Window",227,90,246,177,Null,WINDOW_TITLEBAR) Local Child:TGadget = CreateWindow:TGadget("Child",73,27,99,105,Win1:TGadget,WINDOW_TITLEBAR|WINDOW_TOOL |WINDOW_CHILD) Local Win3:TGadget = CreateWindow:TGadget("Win3",347,272,132,111,Null,WINDOW_TITLEBAR|WINDOW_MENU |WINDOW_TOOL ) Local Win3_File:TGadget = CreateMenu( "File" , 10100 , WindowMenu( Win3:TGadget ) ) Local Win3_Open:TGadget = CreateMenu( "Open" , 10101 , WindowMenu( Win3_File:TGadget ) ) Local Win3_Close:TGadget = CreateMenu( "Close" , 10102 , WindowMenu( Win3_File:TGadget ) ) Local Win3_Exit:TGadget = CreateMenu( "Exit" , 10103 , WindowMenu( Win3_File:TGadget ) ) Local Win3_Edit:TGadget = CreateMenu( "Edit" , 10200 , WindowMenu( Win3:TGadget ) ) Local Win3_Cut:TGadget = CreateMenu( "Cut" , 10201 , WindowMenu( Win3_Edit:TGadget ) ) Local Win3_Copy:TGadget = CreateMenu( "Copy" , 10202 , WindowMenu( Win3_Edit:TGadget ) ) Local Win3_Paste:TGadget = CreateMenu( "Paste" , 10203 , WindowMenu( Win3_Edit:TGadget ) ) Local Win3_Help:TGadget = CreateMenu( "Help" , 10300 , WindowMenu( Win3:TGadget ) ) Local Win3_About:TGadget = CreateMenu( "About" , 10301 , WindowMenu( Win3_Help:TGadget ) ) UpdateWindowMenu( Win3:TGadget ) Repeat WaitEvent() Select EventID() Case EVENT_WINDOWCLOSE Select EventSource() Case Win2 Win2_WC( Win2:TGadget ) Case Win1 Win1_WC( Win1:TGadget ) Case Child Child_WC( Child:TGadget ) Case Win3 Win3_WC( Win3:TGadget ) End Select Case EVENT_MENUACTION Select EventData() 'Menu_Events for Gadget = Win2 'Menu_Events for Gadget = Win3 End Select End Select Forever Function Win2_WC( Window:TGadget ) DebugLog "Window Win2 wants to be closed" ' HideGadget( Window:TGadget ) End End Function Function Win1_WC( Window:TGadget ) DebugLog "Window Win1 wants to be closed" ' HideGadget( Window:TGadget ) End End Function Function Child_WC( Window:TGadget ) DebugLog "Window Child wants to be closed" ' HideGadget( Window:TGadget ) End End Function Function Win3_WC( Window:TGadget ) DebugLog "Window Win3 wants to be closed" ' HideGadget( Window:TGadget ) End End Function
Two ideas:
- "Re-direct" clicking on a menu item to a pop-up menu; popups don't care for the window size.
- Use "<<" and ">>" buttons to implement a scrolling menu. Or make it even nicer, as Flashers would do it - the mouse hovering in the left or right corners will scroll the menu 'automagically'.
BUT: If you need a menu size bigger than your application window, then -maybe- there is something wrong with your entire user interface. Sounds like the typical Microsoft Overkill to me. Many Mac applications don't even need a menu. For example, I almost never use the menu in Aperture. Popup menus, yes, but not the regular application menu. Just a thought. ;-)
- "Re-direct" clicking on a menu item to a pop-up menu; popups don't care for the window size.
- Use "<<" and ">>" buttons to implement a scrolling menu. Or make it even nicer, as Flashers would do it - the mouse hovering in the left or right corners will scroll the menu 'automagically'.
BUT: If you need a menu size bigger than your application window, then -maybe- there is something wrong with your entire user interface. Sounds like the typical Microsoft Overkill to me. Many Mac applications don't even need a menu. For example, I almost never use the menu in Aperture. Popup menus, yes, but not the regular application menu. Just a thought. ;-)