Skip to content

WindowMenu

Claude edited this page Oct 26, 2026 · 6 revisions

WindowMenu

Command Index · BlitzPlus · Windows

WindowMenu window%  ; returns Int

Works in: BlitzPlus

Gives the root of the menu tree of a window, which exists from the start but is empty. Menus made with this as their parent are the titles in the menu bar. The window needs flag 4 to show room for it.

Graphics 320, 240, 32, 2
win = CreateWindow("Menus", 20, 20, 260, 150, Desktop(), 15)
file = CreateMenu("File", 0, WindowMenu(win))
CreateMenu "Open", 1, file
CreateMenu "Exit", 2, file
edit = CreateMenu("Edit", 0, WindowMenu(win))
CreateMenu "Copy", 3, edit
UpdateWindowMenu win
Repeat
Until WaitEvent() = $803

WindowMenu

Parameter Type Default Description
window Int required Handle of a window.

Returns: The handle of the root menu. It is the same on every call.

Related commands

Command Index · BlitzPlus · Windows

Home · Command Index


Getting started

Language

Tools


Language Features
BlitzBasic
Blitz3D
BlitzPlus
Differences

More

Clone this wiki locally