wxNotebook

wxNotebook

wxNotebook
Functions for wxNotebook class

This class represents a notebook control, which manages multiple windows with associated tabs.

To use the class, create a wxNotebook object and call wxBookCtrlBase:addPage/4 or wxBookCtrlBase:insertPage/5, passing a window to be used as the page. Do not explicitly delete the window for a page that is currently managed by wxNotebook.

wxNotebookPage is a typedef for wxWindow.

Styles

This class supports the following styles:

Page backgrounds

On Windows, the default theme paints a background on the notebook's pages. If you wish to suppress this theme, for aesthetic or performance reasons, there are three ways of doing it. You can use wxNB_NOPAGETHEME to disable themed drawing for a particular notebook, you can call wxSystemOptions:setOption/2 to disable it for the whole application, or you can disable it for individual pages by using wxWindow:setBackgroundColour/2.

To disable themed pages globally:

Set the value to 1 to enable it again. To give a single page a solid background that more or less fits in with the overall theme, use:

On platforms other than Windows, or if the application is not using Windows themes, getThemeBackgroundColour/1 will return an uninitialised colour object, and the above code will therefore work on all platforms.

See: ?wxBookCtrl, wxBookCtrlEvent, wxImageList, Examples

This class is derived (and can use functions) from: wxBookCtrlBase wxControl wxWindow wxEvtHandler

wxWidgets docs: wxNotebook

Types

Returns the number of rows in the notebook control.

Types

If running under Windows and themes are enabled for the application, this function returns a suitable colour for painting the background of a notebook page, and can be passed to wxWindow:setBackgroundColour/2.

Otherwise, an uninitialised colour will be returned.

Types

Padding = {W :: integer(), H :: integer()}

Sets the amount of space around each page's icon and label, in pixels.

Note: The vertical padding cannot be changed in wxGTK.

Types

Size = {W :: integer(), H :: integer()}

Sets the width and height of the pages.

Note: This method is currently not implemented for wxGTK.