Frame

Help Contents GUI programming Frames Frame
Frames FrameDestroy

Frame parent title style pos size
(Frame parent title style)
(Frame parent title style pos size name)


Operation which outputs a new Frame (a window with maybe a border around). This Frame can be assigned to a variable, and it will be deleted, when the variable is being deleted. So with local variables you can emulate Dialogs with Frames until those will be included into aUCBLogo.

parent can be a Frame or a Graph.

title is the window title text.



style is the Window Style and can be a combination (with +) of the folling constants:

wxDEFAULT_FRAME_STYLE Defined as wxMINIMIZE_BOX | wxMAXIMIZE_BOX | wxRESIZE_BORDER | wxSYSTEM_MENU | wxCAPTION | wxCLOSE_BOX | wxCLIP_CHILDREN.

wxICONIZE Display the frame iconized (minimized). Windows only.

wxCAPTION Puts a caption on the frame.

wxMINIMIZE Identical to wxICONIZE. Windows only.

wxMINIMIZE_BOX Displays a minimize box on the frame.

wxMAXIMIZE Displays the frame maximized. Windows only.

wxMAXIMIZE_BOX Displays a maximize box on the frame.

wxCLOSE_BOX Displays a close box on the frame.

wxSTAY_ON_TOP Stay on top of all other windows, see also wxFRAME_FLOAT_ON_PARENT.

wxSYSTEM_MENU Displays a system menu.

wxRESIZE_BORDER Displays a resizeable border around the window.

wxFRAME_TOOL_WINDOW Causes a frame with a small titlebar to be created; the frame does not appear in the taskbar under Windows or GTK+.

wxFRAME_NO_TASKBAR Creates an otherwise normal frame but it does not appear in the taskbar under Windows or GTK+ (note that it will minimize to the desktop window under Windows which may seem strange to the users and thus it might be better to use this style only without wxMINIMIZE_BOX style). In wxGTK, the flag is respected only if GTK+ is at least version 2.2 and the window manager supports _NET_WM_STATE_SKIP_TASKBAR hint. Has no effect under other platforms.

wxFRAME_FLOAT_ON_PARENT The frame will always be on top of its parent (unlike wxSTAY_ON_TOP). A frame created with this style must have a non-NULL parent.

wxFRAME_SHAPED Windows with this style are allowed to have their shape changed with the SetShape method.



pos is a list of two integer numbers representing x and y position.

size is a list of two integer numbers representing width and height.

Like all window or control positions and sizes the value -1 for a coordinate means that wxWidgets will use the default value. This is especially useful when you use sizers, so you mostly don't need to figure out the coordinates yourself, for i.e. Buttons or other controls.

name is the internal name of the window, it's mostly unused.

Output is the created Frame.

Examples:

f=Frame [][MyFrame][][400 200][200 100]
f2=(Frame [][MyFrame2]
	wxDefault_Frame_Style+wxStay_on_Top
	[400 300][300 300])

f3=(Frame f2 [MyFrame3]
	wxDefault_Frame_Style+wxFrame_float_on_parent+wxFrame_shaped
	[500 400][260 300])

f4=(Frame f2 [MyFrame4]
	wxDefault_Frame_Style+wxFrame_shaped+wxFrame_float_on_parent
	[100 400][260 300]
	[noname])

OnChar [ern [f f2 f3 f4] GC OnChar []]

Examples:

References:

Frames FrameDestroy