Restored from previous forum. Originally posted by Froggerprogger.
MenuItem(1, "New" + Chr(9) + "Crtl+N")
MenuItem(2, "Save File as... " + Chr(9) + "Shift+S")
Chr(9) is the ASCII-code of tabulator.
And the 1st Tabstop in the Menu is behind the longest itemtext before the tab in the current Menu.
Here's some code:
Code: Select all
OpenWindow(1,0,0,600,200,#PB_Window_Systemmenu, "erituh")
CreateMenu(1, WindowID())
MenuTitle("File")
MenuItem(1,"New"+Chr(9)+"Ctrl+N")
MenuItem(2,"Save File..."+Chr(9)+"Ctrl+S")
MenuItem(3,"Save this file as a new one to..."+Chr(9)+"Ctrl+S")
MenuItem(3,"But"+Chr(9)+"just"+Chr(9)+"OneTab")
Resume=1
While Resume
Select WaitWindowEvent()
Case #PB_EventCloseWindow
Resume=0
EndSelect
Wend
Purebasic - what a nice name for a girl-friend