Copyright | Will Thompson Iñaki García Etxebarria and Jonas Platte |
---|---|
License | LGPL-2.1 |
Maintainer | Iñaki García Etxebarria |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
- Exported types
- Methods
- appendPage
- appendPageMenu
- detachTab
- getActionWidget
- getCurrentPage
- getGroupName
- getMenuLabel
- getMenuLabelText
- getNPages
- getNthPage
- getScrollable
- getShowBorder
- getShowTabs
- getTabDetachable
- getTabHborder
- getTabLabel
- getTabLabelText
- getTabPos
- getTabReorderable
- getTabVborder
- insertPage
- insertPageMenu
- new
- nextPage
- pageNum
- popupDisable
- popupEnable
- prependPage
- prependPageMenu
- prevPage
- removePage
- reorderChild
- setActionWidget
- setCurrentPage
- setGroupName
- setMenuLabel
- setMenuLabelText
- setScrollable
- setShowBorder
- setShowTabs
- setTabDetachable
- setTabLabel
- setTabLabelText
- setTabPos
- setTabReorderable
- Properties
- Signals
The Notebook
widget is a Container
whose children are pages that
can be switched between using tab labels along one edge.
There are many configuration options for GtkNotebook. Among other
things, you can choose on which edge the tabs appear
(see notebookSetTabPos
), whether, if there are too many
tabs to fit the notebook should be made bigger or scrolling
arrows added (see notebookSetScrollable
), and whether there
will be a popup menu allowing the users to switch pages.
(see notebookPopupEnable
, notebookPopupDisable
)
GtkNotebook as GtkBuildable
The GtkNotebook implementation of the Buildable
interface
supports placing children into tabs by specifying “tab” as the
“type” attribute of a <child> element. Note that the content
of the tab must be created before the tab can be filled.
A tab child can be specified without specifying a <child>
type attribute.
To add a child widget in the notebooks action area, specify "action-start" or “action-end” as the “type” attribute of the <child> element.
An example of a UI definition fragment with GtkNotebook: > >class="GtkNotebook" > child > class="GtkLabel" id="notebook-content" > name="label"Content/property > /object > /child > type="tab" > class="GtkLabel" id="notebook-tab" > name="label"Tab/property > /object > /child >/object
CSS nodes
plain code
notebook ├── header.top │ ├── [<action widget>] │ ├── tabs │ │ ├── [arrow] │ │ ├── tab │ │ │ ╰── <tab label> ┊ ┊ ┊ │ │ ├── tab[.reorderable-page] │ │ │ ╰── <tab label> │ │ ╰── [arrow] │ ╰── [<action widget>] │ ╰── stack ├── <child> ┊ ╰── <child>
GtkNotebook has a main CSS node with name notebook, a subnode with name header and below that a subnode with name tabs which contains one subnode per tab with name tab.
If action widgets are present, their CSS nodes are placed next to the tabs node. If the notebook is scrollable, CSS nodes with name arrow are placed as first and last child of the tabs node.
The main node gets the .frame style class when the notebook
has a border (see notebookSetShowBorder
).
The header node gets one of the style class .top, .bottom, .left or .right, depending on where the tabs are placed. For reorderable pages, the tab node gets the .reorderable-page class.
A tab node gets the .dnd style class while it is moved with drag-and-drop.
The nodes are always arranged from left-to-right, regarldess of text direction.
Synopsis
- newtype Notebook = Notebook (ManagedPtr Notebook)
- class (GObject o, IsDescendantOf Notebook o) => IsNotebook o
- toNotebook :: (MonadIO m, IsNotebook o) => o -> m Notebook
- notebookAppendPage :: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b, IsWidget c) => a -> b -> Maybe c -> m Int32
- notebookAppendPageMenu :: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b, IsWidget c, IsWidget d) => a -> b -> Maybe c -> Maybe d -> m Int32
- notebookDetachTab :: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) => a -> b -> m ()
- notebookGetActionWidget :: (HasCallStack, MonadIO m, IsNotebook a) => a -> PackType -> m (Maybe Widget)
- notebookGetCurrentPage :: (HasCallStack, MonadIO m, IsNotebook a) => a -> m Int32
- notebookGetGroupName :: (HasCallStack, MonadIO m, IsNotebook a) => a -> m (Maybe Text)
- notebookGetMenuLabel :: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) => a -> b -> m (Maybe Widget)
- notebookGetMenuLabelText :: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) => a -> b -> m (Maybe Text)
- notebookGetNPages :: (HasCallStack, MonadIO m, IsNotebook a) => a -> m Int32
- notebookGetNthPage :: (HasCallStack, MonadIO m, IsNotebook a) => a -> Int32 -> m (Maybe Widget)
- notebookGetScrollable :: (HasCallStack, MonadIO m, IsNotebook a) => a -> m Bool
- notebookGetShowBorder :: (HasCallStack, MonadIO m, IsNotebook a) => a -> m Bool
- notebookGetShowTabs :: (HasCallStack, MonadIO m, IsNotebook a) => a -> m Bool
- notebookGetTabDetachable :: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) => a -> b -> m Bool
- notebookGetTabHborder :: (HasCallStack, MonadIO m, IsNotebook a) => a -> m Word16
- notebookGetTabLabel :: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) => a -> b -> m (Maybe Widget)
- notebookGetTabLabelText :: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) => a -> b -> m (Maybe Text)
- notebookGetTabPos :: (HasCallStack, MonadIO m, IsNotebook a) => a -> m PositionType
- notebookGetTabReorderable :: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) => a -> b -> m Bool
- notebookGetTabVborder :: (HasCallStack, MonadIO m, IsNotebook a) => a -> m Word16
- notebookInsertPage :: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b, IsWidget c) => a -> b -> Maybe c -> Int32 -> m Int32
- notebookInsertPageMenu :: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b, IsWidget c, IsWidget d) => a -> b -> Maybe c -> Maybe d -> Int32 -> m Int32
- notebookNew :: (HasCallStack, MonadIO m) => m Notebook
- notebookNextPage :: (HasCallStack, MonadIO m, IsNotebook a) => a -> m ()
- notebookPageNum :: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) => a -> b -> m Int32
- notebookPopupDisable :: (HasCallStack, MonadIO m, IsNotebook a) => a -> m ()
- notebookPopupEnable :: (HasCallStack, MonadIO m, IsNotebook a) => a -> m ()
- notebookPrependPage :: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b, IsWidget c) => a -> b -> Maybe c -> m Int32
- notebookPrependPageMenu :: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b, IsWidget c, IsWidget d) => a -> b -> Maybe c -> Maybe d -> m Int32
- notebookPrevPage :: (HasCallStack, MonadIO m, IsNotebook a) => a -> m ()
- notebookRemovePage :: (HasCallStack, MonadIO m, IsNotebook a) => a -> Int32 -> m ()
- notebookReorderChild :: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) => a -> b -> Int32 -> m ()
- notebookSetActionWidget :: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) => a -> b -> PackType -> m ()
- notebookSetCurrentPage :: (HasCallStack, MonadIO m, IsNotebook a) => a -> Int32 -> m ()
- notebookSetGroupName :: (HasCallStack, MonadIO m, IsNotebook a) => a -> Maybe Text -> m ()
- notebookSetMenuLabel :: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b, IsWidget c) => a -> b -> Maybe c -> m ()
- notebookSetMenuLabelText :: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) => a -> b -> Text -> m ()
- notebookSetScrollable :: (HasCallStack, MonadIO m, IsNotebook a) => a -> Bool -> m ()
- notebookSetShowBorder :: (HasCallStack, MonadIO m, IsNotebook a) => a -> Bool -> m ()
- notebookSetShowTabs :: (HasCallStack, MonadIO m, IsNotebook a) => a -> Bool -> m ()
- notebookSetTabDetachable :: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) => a -> b -> Bool -> m ()
- notebookSetTabLabel :: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b, IsWidget c) => a -> b -> Maybe c -> m ()
- notebookSetTabLabelText :: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) => a -> b -> Text -> m ()
- notebookSetTabPos :: (HasCallStack, MonadIO m, IsNotebook a) => a -> PositionType -> m ()
- notebookSetTabReorderable :: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) => a -> b -> Bool -> m ()
- constructNotebookEnablePopup :: (IsNotebook o, MonadIO m) => Bool -> m (GValueConstruct o)
- getNotebookEnablePopup :: (MonadIO m, IsNotebook o) => o -> m Bool
- setNotebookEnablePopup :: (MonadIO m, IsNotebook o) => o -> Bool -> m ()
- clearNotebookGroupName :: (MonadIO m, IsNotebook o) => o -> m ()
- constructNotebookGroupName :: (IsNotebook o, MonadIO m) => Text -> m (GValueConstruct o)
- getNotebookGroupName :: (MonadIO m, IsNotebook o) => o -> m (Maybe Text)
- setNotebookGroupName :: (MonadIO m, IsNotebook o) => o -> Text -> m ()
- constructNotebookPage :: (IsNotebook o, MonadIO m) => Int32 -> m (GValueConstruct o)
- getNotebookPage :: (MonadIO m, IsNotebook o) => o -> m Int32
- setNotebookPage :: (MonadIO m, IsNotebook o) => o -> Int32 -> m ()
- constructNotebookScrollable :: (IsNotebook o, MonadIO m) => Bool -> m (GValueConstruct o)
- getNotebookScrollable :: (MonadIO m, IsNotebook o) => o -> m Bool
- setNotebookScrollable :: (MonadIO m, IsNotebook o) => o -> Bool -> m ()
- constructNotebookShowBorder :: (IsNotebook o, MonadIO m) => Bool -> m (GValueConstruct o)
- getNotebookShowBorder :: (MonadIO m, IsNotebook o) => o -> m Bool
- setNotebookShowBorder :: (MonadIO m, IsNotebook o) => o -> Bool -> m ()
- constructNotebookShowTabs :: (IsNotebook o, MonadIO m) => Bool -> m (GValueConstruct o)
- getNotebookShowTabs :: (MonadIO m, IsNotebook o) => o -> m Bool
- setNotebookShowTabs :: (MonadIO m, IsNotebook o) => o -> Bool -> m ()
- constructNotebookTabPos :: (IsNotebook o, MonadIO m) => PositionType -> m (GValueConstruct o)
- getNotebookTabPos :: (MonadIO m, IsNotebook o) => o -> m PositionType
- setNotebookTabPos :: (MonadIO m, IsNotebook o) => o -> PositionType -> m ()
- type C_NotebookChangeCurrentPageCallback = Ptr () -> Int32 -> Ptr () -> IO CInt
- type NotebookChangeCurrentPageCallback = Int32 -> IO Bool
- afterNotebookChangeCurrentPage :: (IsNotebook a, MonadIO m) => a -> NotebookChangeCurrentPageCallback -> m SignalHandlerId
- genClosure_NotebookChangeCurrentPage :: MonadIO m => NotebookChangeCurrentPageCallback -> m (GClosure C_NotebookChangeCurrentPageCallback)
- mk_NotebookChangeCurrentPageCallback :: C_NotebookChangeCurrentPageCallback -> IO (FunPtr C_NotebookChangeCurrentPageCallback)
- noNotebookChangeCurrentPageCallback :: Maybe NotebookChangeCurrentPageCallback
- onNotebookChangeCurrentPage :: (IsNotebook a, MonadIO m) => a -> NotebookChangeCurrentPageCallback -> m SignalHandlerId
- wrap_NotebookChangeCurrentPageCallback :: NotebookChangeCurrentPageCallback -> C_NotebookChangeCurrentPageCallback
- type C_NotebookCreateWindowCallback = Ptr () -> Ptr Widget -> Int32 -> Int32 -> Ptr () -> IO (Ptr Notebook)
- type NotebookCreateWindowCallback = Widget -> Int32 -> Int32 -> IO Notebook
- afterNotebookCreateWindow :: (IsNotebook a, MonadIO m) => a -> NotebookCreateWindowCallback -> m SignalHandlerId
- genClosure_NotebookCreateWindow :: MonadIO m => NotebookCreateWindowCallback -> m (GClosure C_NotebookCreateWindowCallback)
- mk_NotebookCreateWindowCallback :: C_NotebookCreateWindowCallback -> IO (FunPtr C_NotebookCreateWindowCallback)
- noNotebookCreateWindowCallback :: Maybe NotebookCreateWindowCallback
- onNotebookCreateWindow :: (IsNotebook a, MonadIO m) => a -> NotebookCreateWindowCallback -> m SignalHandlerId
- wrap_NotebookCreateWindowCallback :: NotebookCreateWindowCallback -> C_NotebookCreateWindowCallback
- type C_NotebookFocusTabCallback = Ptr () -> CUInt -> Ptr () -> IO CInt
- type NotebookFocusTabCallback = NotebookTab -> IO Bool
- afterNotebookFocusTab :: (IsNotebook a, MonadIO m) => a -> NotebookFocusTabCallback -> m SignalHandlerId
- genClosure_NotebookFocusTab :: MonadIO m => NotebookFocusTabCallback -> m (GClosure C_NotebookFocusTabCallback)
- mk_NotebookFocusTabCallback :: C_NotebookFocusTabCallback -> IO (FunPtr C_NotebookFocusTabCallback)
- noNotebookFocusTabCallback :: Maybe NotebookFocusTabCallback
- onNotebookFocusTab :: (IsNotebook a, MonadIO m) => a -> NotebookFocusTabCallback -> m SignalHandlerId
- wrap_NotebookFocusTabCallback :: NotebookFocusTabCallback -> C_NotebookFocusTabCallback
- type C_NotebookMoveFocusOutCallback = Ptr () -> CUInt -> Ptr () -> IO ()
- type NotebookMoveFocusOutCallback = DirectionType -> IO ()
- afterNotebookMoveFocusOut :: (IsNotebook a, MonadIO m) => a -> NotebookMoveFocusOutCallback -> m SignalHandlerId
- genClosure_NotebookMoveFocusOut :: MonadIO m => NotebookMoveFocusOutCallback -> m (GClosure C_NotebookMoveFocusOutCallback)
- mk_NotebookMoveFocusOutCallback :: C_NotebookMoveFocusOutCallback -> IO (FunPtr C_NotebookMoveFocusOutCallback)
- noNotebookMoveFocusOutCallback :: Maybe NotebookMoveFocusOutCallback
- onNotebookMoveFocusOut :: (IsNotebook a, MonadIO m) => a -> NotebookMoveFocusOutCallback -> m SignalHandlerId
- wrap_NotebookMoveFocusOutCallback :: NotebookMoveFocusOutCallback -> C_NotebookMoveFocusOutCallback
- type C_NotebookPageAddedCallback = Ptr () -> Ptr Widget -> Word32 -> Ptr () -> IO ()
- type NotebookPageAddedCallback = Widget -> Word32 -> IO ()
- afterNotebookPageAdded :: (IsNotebook a, MonadIO m) => a -> NotebookPageAddedCallback -> m SignalHandlerId
- genClosure_NotebookPageAdded :: MonadIO m => NotebookPageAddedCallback -> m (GClosure C_NotebookPageAddedCallback)
- mk_NotebookPageAddedCallback :: C_NotebookPageAddedCallback -> IO (FunPtr C_NotebookPageAddedCallback)
- noNotebookPageAddedCallback :: Maybe NotebookPageAddedCallback
- onNotebookPageAdded :: (IsNotebook a, MonadIO m) => a -> NotebookPageAddedCallback -> m SignalHandlerId
- wrap_NotebookPageAddedCallback :: NotebookPageAddedCallback -> C_NotebookPageAddedCallback
- type C_NotebookPageRemovedCallback = Ptr () -> Ptr Widget -> Word32 -> Ptr () -> IO ()
- type NotebookPageRemovedCallback = Widget -> Word32 -> IO ()
- afterNotebookPageRemoved :: (IsNotebook a, MonadIO m) => a -> NotebookPageRemovedCallback -> m SignalHandlerId
- genClosure_NotebookPageRemoved :: MonadIO m => NotebookPageRemovedCallback -> m (GClosure C_NotebookPageRemovedCallback)
- mk_NotebookPageRemovedCallback :: C_NotebookPageRemovedCallback -> IO (FunPtr C_NotebookPageRemovedCallback)
- noNotebookPageRemovedCallback :: Maybe NotebookPageRemovedCallback
- onNotebookPageRemoved :: (IsNotebook a, MonadIO m) => a -> NotebookPageRemovedCallback -> m SignalHandlerId
- wrap_NotebookPageRemovedCallback :: NotebookPageRemovedCallback -> C_NotebookPageRemovedCallback
- type C_NotebookPageReorderedCallback = Ptr () -> Ptr Widget -> Word32 -> Ptr () -> IO ()
- type NotebookPageReorderedCallback = Widget -> Word32 -> IO ()
- afterNotebookPageReordered :: (IsNotebook a, MonadIO m) => a -> NotebookPageReorderedCallback -> m SignalHandlerId
- genClosure_NotebookPageReordered :: MonadIO m => NotebookPageReorderedCallback -> m (GClosure C_NotebookPageReorderedCallback)
- mk_NotebookPageReorderedCallback :: C_NotebookPageReorderedCallback -> IO (FunPtr C_NotebookPageReorderedCallback)
- noNotebookPageReorderedCallback :: Maybe NotebookPageReorderedCallback
- onNotebookPageReordered :: (IsNotebook a, MonadIO m) => a -> NotebookPageReorderedCallback -> m SignalHandlerId
- wrap_NotebookPageReorderedCallback :: NotebookPageReorderedCallback -> C_NotebookPageReorderedCallback
- type C_NotebookReorderTabCallback = Ptr () -> CUInt -> CInt -> Ptr () -> IO CInt
- type NotebookReorderTabCallback = DirectionType -> Bool -> IO Bool
- afterNotebookReorderTab :: (IsNotebook a, MonadIO m) => a -> NotebookReorderTabCallback -> m SignalHandlerId
- genClosure_NotebookReorderTab :: MonadIO m => NotebookReorderTabCallback -> m (GClosure C_NotebookReorderTabCallback)
- mk_NotebookReorderTabCallback :: C_NotebookReorderTabCallback -> IO (FunPtr C_NotebookReorderTabCallback)
- noNotebookReorderTabCallback :: Maybe NotebookReorderTabCallback
- onNotebookReorderTab :: (IsNotebook a, MonadIO m) => a -> NotebookReorderTabCallback -> m SignalHandlerId
- wrap_NotebookReorderTabCallback :: NotebookReorderTabCallback -> C_NotebookReorderTabCallback
- type C_NotebookSelectPageCallback = Ptr () -> CInt -> Ptr () -> IO CInt
- type NotebookSelectPageCallback = Bool -> IO Bool
- afterNotebookSelectPage :: (IsNotebook a, MonadIO m) => a -> NotebookSelectPageCallback -> m SignalHandlerId
- genClosure_NotebookSelectPage :: MonadIO m => NotebookSelectPageCallback -> m (GClosure C_NotebookSelectPageCallback)
- mk_NotebookSelectPageCallback :: C_NotebookSelectPageCallback -> IO (FunPtr C_NotebookSelectPageCallback)
- noNotebookSelectPageCallback :: Maybe NotebookSelectPageCallback
- onNotebookSelectPage :: (IsNotebook a, MonadIO m) => a -> NotebookSelectPageCallback -> m SignalHandlerId
- wrap_NotebookSelectPageCallback :: NotebookSelectPageCallback -> C_NotebookSelectPageCallback
- type C_NotebookSwitchPageCallback = Ptr () -> Ptr Widget -> Word32 -> Ptr () -> IO ()
- type NotebookSwitchPageCallback = Widget -> Word32 -> IO ()
- afterNotebookSwitchPage :: (IsNotebook a, MonadIO m) => a -> NotebookSwitchPageCallback -> m SignalHandlerId
- genClosure_NotebookSwitchPage :: MonadIO m => NotebookSwitchPageCallback -> m (GClosure C_NotebookSwitchPageCallback)
- mk_NotebookSwitchPageCallback :: C_NotebookSwitchPageCallback -> IO (FunPtr C_NotebookSwitchPageCallback)
- noNotebookSwitchPageCallback :: Maybe NotebookSwitchPageCallback
- onNotebookSwitchPage :: (IsNotebook a, MonadIO m) => a -> NotebookSwitchPageCallback -> m SignalHandlerId
- wrap_NotebookSwitchPageCallback :: NotebookSwitchPageCallback -> C_NotebookSwitchPageCallback
Exported types
Memory-managed wrapper type.
Instances
Eq Notebook Source # | |
GObject Notebook Source # | |
Defined in GI.Gtk.Objects.Notebook | |
ManagedPtrNewtype Notebook Source # | |
Defined in GI.Gtk.Objects.Notebook toManagedPtr :: Notebook -> ManagedPtr Notebook | |
TypedObject Notebook Source # | |
Defined in GI.Gtk.Objects.Notebook | |
HasParentTypes Notebook Source # | |
Defined in GI.Gtk.Objects.Notebook | |
IsGValue (Maybe Notebook) Source # | Convert |
Defined in GI.Gtk.Objects.Notebook gvalueGType_ :: IO GType gvalueSet_ :: Ptr GValue -> Maybe Notebook -> IO () gvalueGet_ :: Ptr GValue -> IO (Maybe Notebook) | |
type ParentTypes Notebook Source # | |
class (GObject o, IsDescendantOf Notebook o) => IsNotebook o Source #
Type class for types which can be safely cast to Notebook
, for instance with toNotebook
.
Instances
(GObject o, IsDescendantOf Notebook o) => IsNotebook o Source # | |
Defined in GI.Gtk.Objects.Notebook |
toNotebook :: (MonadIO m, IsNotebook o) => o -> m Notebook Source #
Methods
Click to display all available methods, including inherited ones
Methods
activate, add, addAccelerator, addChild, addDeviceEvents, addEvents, addMnemonicLabel, addTickCallback, appendPage, appendPageMenu, bindProperty, bindPropertyFull, canActivateAccel, checkResize, childFocus, childGetProperty, childNotify, childNotifyByPspec, childSetProperty, childType, classPath, computeExpand, constructChild, createPangoContext, createPangoLayout, customFinished, customTagEnd, customTagStart, destroy, destroyed, detachTab, deviceIsShadowed, dragBegin, dragBeginWithCoordinates, dragCheckThreshold, dragDestAddImageTargets, dragDestAddTextTargets, dragDestAddUriTargets, dragDestFindTarget, dragDestGetTargetList, dragDestGetTrackMotion, dragDestSet, dragDestSetProxy, dragDestSetTargetList, dragDestSetTrackMotion, dragDestUnset, dragGetData, dragHighlight, dragSourceAddImageTargets, dragSourceAddTextTargets, dragSourceAddUriTargets, dragSourceGetTargetList, dragSourceSet, dragSourceSetIconGicon, dragSourceSetIconName, dragSourceSetIconPixbuf, dragSourceSetIconStock, dragSourceSetTargetList, dragSourceUnset, dragUnhighlight, draw, ensureStyle, errorBell, event, forall, forceFloating, foreach, freezeChildNotify, freezeNotify, getv, grabAdd, grabDefault, grabFocus, grabRemove, hasDefault, hasFocus, hasGrab, hasRcStyle, hasScreen, hasVisibleFocus, hide, hideOnDelete, inDestruction, initTemplate, inputShapeCombineRegion, insertActionGroup, insertPage, insertPageMenu, intersect, isAncestor, isComposited, isDrawable, isFloating, isFocus, isSensitive, isToplevel, isVisible, keynavFailed, listAccelClosures, listActionPrefixes, listMnemonicLabels, map, mnemonicActivate, modifyBase, modifyBg, modifyCursor, modifyFg, modifyFont, modifyStyle, modifyText, nextPage, notify, notifyByPspec, overrideBackgroundColor, overrideColor, overrideCursor, overrideFont, overrideSymbolicColor, pageNum, parserFinished, path, popupDisable, popupEnable, prependPage, prependPageMenu, prevPage, propagateDraw, queueAllocate, queueComputeExpand, queueDraw, queueDrawArea, queueDrawRegion, queueResize, queueResizeNoRedraw, realize, ref, refSink, regionIntersect, registerWindow, remove, removeAccelerator, removeMnemonicLabel, removePage, removeTickCallback, renderIcon, renderIconPixbuf, reorderChild, reparent, resetRcStyles, resetStyle, resizeChildren, runDispose, sendExpose, sendFocusChange, shapeCombineRegion, show, showAll, showNow, sizeAllocate, sizeAllocateWithBaseline, sizeRequest, stealData, stealQdata, styleAttach, styleGetProperty, thawChildNotify, thawNotify, translateCoordinates, triggerTooltipQuery, unmap, unparent, unrealize, unref, unregisterWindow, unsetFocusChain, unsetStateFlags, watchClosure.
Getters
getAccessible, getActionGroup, getActionWidget, getAllocatedBaseline, getAllocatedHeight, getAllocatedSize, getAllocatedWidth, getAllocation, getAncestor, getAppPaintable, getBorderWidth, getCanDefault, getCanFocus, getChildRequisition, getChildVisible, getChildren, getClip, getClipboard, getCompositeName, getCurrentPage, getData, getDeviceEnabled, getDeviceEvents, getDirection, getDisplay, getDoubleBuffered, getEvents, getFocusChain, getFocusChild, getFocusHadjustment, getFocusOnClick, getFocusVadjustment, getFontMap, getFontOptions, getFrameClock, getGroupName, getHalign, getHasTooltip, getHasWindow, getHexpand, getHexpandSet, getInternalChild, getMapped, getMarginBottom, getMarginEnd, getMarginLeft, getMarginRight, getMarginStart, getMarginTop, getMenuLabel, getMenuLabelText, getModifierMask, getModifierStyle, getNPages, getName, getNoShowAll, getNthPage, getOpacity, getPangoContext, getParent, getParentWindow, getPath, getPathForChild, getPointer, getPreferredHeight, getPreferredHeightAndBaselineForWidth, getPreferredHeightForWidth, getPreferredSize, getPreferredWidth, getPreferredWidthForHeight, getProperty, getQdata, getRealized, getReceivesDefault, getRequestMode, getRequisition, getResizeMode, getRootWindow, getScaleFactor, getScreen, getScrollable, getSensitive, getSettings, getShowBorder, getShowTabs, getSizeRequest, getState, getStateFlags, getStyle, getStyleContext, getSupportMultidevice, getTabDetachable, getTabHborder, getTabLabel, getTabLabelText, getTabPos, getTabReorderable, getTabVborder, getTemplateChild, getTooltipMarkup, getTooltipText, getTooltipWindow, getToplevel, getValign, getValignWithBaseline, getVexpand, getVexpandSet, getVisible, getVisual, getWindow.
Setters
setAccelPath, setActionWidget, setAllocation, setAppPaintable, setBorderWidth, setBuildableProperty, setCanDefault, setCanFocus, setChildVisible, setClip, setCompositeName, setCurrentPage, setData, setDataFull, setDeviceEnabled, setDeviceEvents, setDirection, setDoubleBuffered, setEvents, setFocusChain, setFocusChild, setFocusHadjustment, setFocusOnClick, setFocusVadjustment, setFontMap, setFontOptions, setGroupName, setHalign, setHasTooltip, setHasWindow, setHexpand, setHexpandSet, setMapped, setMarginBottom, setMarginEnd, setMarginLeft, setMarginRight, setMarginStart, setMarginTop, setMenuLabel, setMenuLabelText, setName, setNoShowAll, setOpacity, setParent, setParentWindow, setProperty, setRealized, setReallocateRedraws, setReceivesDefault, setRedrawOnAllocate, setResizeMode, setScrollable, setSensitive, setShowBorder, setShowTabs, setSizeRequest, setState, setStateFlags, setStyle, setSupportMultidevice, setTabDetachable, setTabLabel, setTabLabelText, setTabPos, setTabReorderable, setTooltipMarkup, setTooltipText, setTooltipWindow, setValign, setVexpand, setVexpandSet, setVisible, setVisual, setWindow.
appendPage
:: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b, IsWidget c) | |
=> a |
|
-> b |
|
-> Maybe c |
|
-> m Int32 | Returns: the index (starting from 0) of the appended page in the notebook, or -1 if function fails |
Appends a page to notebook
.
appendPageMenu
notebookAppendPageMenu Source #
:: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b, IsWidget c, IsWidget d) | |
=> a |
|
-> b |
|
-> Maybe c |
|
-> Maybe d |
|
-> m Int32 | Returns: the index (starting from 0) of the appended page in the notebook, or -1 if function fails |
Appends a page to notebook
, specifying the widget to use as the
label in the popup menu.
detachTab
:: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) | |
=> a |
|
-> b |
|
-> m () |
Removes the child from the notebook.
This function is very similar to containerRemove
,
but additionally informs the notebook that the removal
is happening as part of a tab DND operation, which should
not be cancelled.
Since: 3.16
getActionWidget
notebookGetActionWidget Source #
:: (HasCallStack, MonadIO m, IsNotebook a) | |
=> a |
|
-> PackType |
|
-> m (Maybe Widget) | Returns: The action widget with the given
|
Gets one of the action widgets. See notebookSetActionWidget
.
Since: 2.20
getCurrentPage
notebookGetCurrentPage Source #
:: (HasCallStack, MonadIO m, IsNotebook a) | |
=> a |
|
-> m Int32 | Returns: the index (starting from 0) of the current page in the notebook. If the notebook has no pages, then -1 will be returned. |
Returns the page number of the current page.
getGroupName
:: (HasCallStack, MonadIO m, IsNotebook a) | |
=> a |
|
-> m (Maybe Text) | Returns: the group name, or |
Gets the current group name for notebook
.
Since: 2.24
getMenuLabel
:: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) | |
=> a |
|
-> b |
|
-> m (Maybe Widget) | Returns: the menu label, or |
Retrieves the menu label widget of the page containing child
.
getMenuLabelText
notebookGetMenuLabelText Source #
:: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) | |
=> a |
|
-> b |
|
-> m (Maybe Text) | Returns: the text of the tab label, or |
Retrieves the text of the menu label for the page containing
child
.
getNPages
:: (HasCallStack, MonadIO m, IsNotebook a) | |
=> a |
|
-> m Int32 | Returns: the number of pages in the notebook |
Gets the number of pages in a notebook.
Since: 2.2
getNthPage
:: (HasCallStack, MonadIO m, IsNotebook a) | |
=> a |
|
-> Int32 |
|
-> m (Maybe Widget) | Returns: the child widget, or |
Returns the child widget contained in page number pageNum
.
getScrollable
notebookGetScrollable Source #
:: (HasCallStack, MonadIO m, IsNotebook a) | |
=> a |
|
-> m Bool | Returns: |
Returns whether the tab label area has arrows for scrolling.
See notebookSetScrollable
.
getShowBorder
notebookGetShowBorder Source #
:: (HasCallStack, MonadIO m, IsNotebook a) | |
=> a |
|
-> m Bool | Returns: |
Returns whether a bevel will be drawn around the notebook pages.
See notebookSetShowBorder
.
getShowTabs
:: (HasCallStack, MonadIO m, IsNotebook a) | |
=> a |
|
-> m Bool | Returns: |
Returns whether the tabs of the notebook are shown.
See notebookSetShowTabs
.
getTabDetachable
notebookGetTabDetachable Source #
:: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) | |
=> a |
|
-> b |
|
-> m Bool | Returns: |
Returns whether the tab contents can be detached from notebook
.
Since: 2.10
getTabHborder
notebookGetTabHborder Source #
:: (HasCallStack, MonadIO m, IsNotebook a) | |
=> a |
|
-> m Word16 | Returns: horizontal width of a tab border |
Deprecated: (Since version 3.4)this function returns zero
Returns the horizontal width of a tab border.
Since: 2.22
getTabLabel
:: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) | |
=> a |
|
-> b |
|
-> m (Maybe Widget) | Returns: the tab label |
Returns the tab label widget for the page child
.
Nothing
is returned if child
is not in notebook
or
if no tab label has specifically been set for child
.
getTabLabelText
notebookGetTabLabelText Source #
:: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) | |
=> a |
|
-> b |
|
-> m (Maybe Text) | Returns: the text of the tab label, or |
Retrieves the text of the tab label for the page containing
child
.
getTabPos
:: (HasCallStack, MonadIO m, IsNotebook a) | |
=> a |
|
-> m PositionType | Returns: the edge at which the tabs are drawn |
Gets the edge at which the tabs for switching pages in the notebook are drawn.
getTabReorderable
notebookGetTabReorderable Source #
:: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) | |
=> a |
|
-> b |
|
-> m Bool | Returns: |
Gets whether the tab can be reordered via drag and drop or not.
Since: 2.10
getTabVborder
notebookGetTabVborder Source #
:: (HasCallStack, MonadIO m, IsNotebook a) | |
=> a |
|
-> m Word16 | Returns: vertical width of a tab border |
Deprecated: (Since version 3.4)this function returns zero
Returns the vertical width of a tab border.
Since: 2.22
insertPage
:: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b, IsWidget c) | |
=> a |
|
-> b |
|
-> Maybe c |
|
-> Int32 |
|
-> m Int32 | Returns: the index (starting from 0) of the inserted page in the notebook, or -1 if function fails |
Insert a page into notebook
at the given position.
insertPageMenu
notebookInsertPageMenu Source #
:: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b, IsWidget c, IsWidget d) | |
=> a |
|
-> b |
|
-> Maybe c |
|
-> Maybe d |
|
-> Int32 |
|
-> m Int32 | Returns: the index (starting from 0) of the inserted page in the notebook |
Insert a page into notebook
at the given position, specifying
the widget to use as the label in the popup menu.
new
:: (HasCallStack, MonadIO m) | |
=> m Notebook | Returns: the newly created |
Creates a new Notebook
widget with no pages.
nextPage
:: (HasCallStack, MonadIO m, IsNotebook a) | |
=> a |
|
-> m () |
Switches to the next page. Nothing happens if the current page is the last page.
pageNum
:: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) | |
=> a |
|
-> b |
|
-> m Int32 | Returns: the index of the page containing |
Finds the index of the page which contains the given child widget.
popupDisable
:: (HasCallStack, MonadIO m, IsNotebook a) | |
=> a |
|
-> m () |
Disables the popup menu.
popupEnable
:: (HasCallStack, MonadIO m, IsNotebook a) | |
=> a |
|
-> m () |
Enables the popup menu: if the user clicks with the right mouse button on the tab labels, a menu with all the pages will be popped up.
prependPage
:: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b, IsWidget c) | |
=> a |
|
-> b |
|
-> Maybe c |
|
-> m Int32 | Returns: the index (starting from 0) of the prepended page in the notebook, or -1 if function fails |
Prepends a page to notebook
.
prependPageMenu
notebookPrependPageMenu Source #
:: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b, IsWidget c, IsWidget d) | |
=> a |
|
-> b |
|
-> Maybe c |
|
-> Maybe d |
|
-> m Int32 | Returns: the index (starting from 0) of the prepended page in the notebook, or -1 if function fails |
Prepends a page to notebook
, specifying the widget to use as the
label in the popup menu.
prevPage
:: (HasCallStack, MonadIO m, IsNotebook a) | |
=> a |
|
-> m () |
Switches to the previous page. Nothing happens if the current page is the first page.
removePage
:: (HasCallStack, MonadIO m, IsNotebook a) | |
=> a |
|
-> Int32 |
|
-> m () |
Removes a page from the notebook given its index in the notebook.
reorderChild
:: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) | |
=> a |
|
-> b |
|
-> Int32 |
|
-> m () |
Reorders the page containing child
, so that it appears in position
position
. If position
is greater than or equal to the number of
children in the list or negative, child
will be moved to the end
of the list.
setActionWidget
notebookSetActionWidget Source #
:: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) | |
=> a |
|
-> b |
|
-> PackType |
|
-> m () |
Sets widget
as one of the action widgets. Depending on the pack type
the widget will be placed before or after the tabs. You can use
a Box
if you need to pack more than one widget on the same side.
Note that action widgets are “internal” children of the notebook and thus
not included in the list returned from containerForeach
.
Since: 2.20
setCurrentPage
notebookSetCurrentPage Source #
:: (HasCallStack, MonadIO m, IsNotebook a) | |
=> a |
|
-> Int32 |
|
-> m () |
Switches to the page number pageNum
.
Note that due to historical reasons, GtkNotebook refuses to switch to a page unless the child widget is visible. Therefore, it is recommended to show child widgets before adding them to a notebook.
setGroupName
:: (HasCallStack, MonadIO m, IsNotebook a) | |
=> a |
|
-> Maybe Text |
|
-> m () |
Sets a group name for notebook
.
Notebooks with the same name will be able to exchange tabs
via drag and drop. A notebook with a Nothing
group name will
not be able to exchange tabs with any other notebook.
Since: 2.24
setMenuLabel
:: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b, IsWidget c) | |
=> a |
|
-> b |
|
-> Maybe c |
|
-> m () |
Changes the menu label for the page containing child
.
setMenuLabelText
notebookSetMenuLabelText Source #
:: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) | |
=> a |
|
-> b |
|
-> Text |
|
-> m () |
Creates a new label and sets it as the menu label of child
.
setScrollable
notebookSetScrollable Source #
:: (HasCallStack, MonadIO m, IsNotebook a) | |
=> a |
|
-> Bool |
|
-> m () |
Sets whether the tab label area will have arrows for scrolling if there are too many tabs to fit in the area.
setShowBorder
notebookSetShowBorder Source #
:: (HasCallStack, MonadIO m, IsNotebook a) | |
=> a |
|
-> Bool |
|
-> m () |
Sets whether a bevel will be drawn around the notebook pages.
This only has a visual effect when the tabs are not shown.
See notebookSetShowTabs
.
setShowTabs
:: (HasCallStack, MonadIO m, IsNotebook a) | |
=> a |
|
-> Bool |
|
-> m () |
Sets whether to show the tabs for the notebook or not.
setTabDetachable
notebookSetTabDetachable Source #
:: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) | |
=> a |
|
-> b |
|
-> Bool |
|
-> m () |
Sets whether the tab can be detached from notebook
to another
notebook or widget.
Note that 2 notebooks must share a common group identificator
(see notebookSetGroupName
) to allow automatic tabs
interchange between them.
If you want a widget to interact with a notebook through DnD (i.e.: accept dragged tabs from it) it must be set as a drop destination and accept the target “GTK_NOTEBOOK_TAB”. The notebook will fill the selection with a GtkWidget** pointing to the child widget that corresponds to the dropped tab.
Note that you should use notebookDetachTab
instead
of containerRemove
if you want to remove the tab from
the source notebook as part of accepting a drop. Otherwise,
the source notebook will think that the dragged tab was
removed from underneath the ongoing drag operation, and
will initiate a drag cancel animation.
C code
static void on_drag_data_received (GtkWidget *widget, GdkDragContext *context, gint x, gint y, GtkSelectionData *data, guint info, guint time, gpointer user_data) { GtkWidget *notebook; GtkWidget **child; notebook = gtk_drag_get_source_widget (context); child = (void*) gtk_selection_data_get_data (data); // process_widget (*child); gtk_notebook_detach_tab (GTK_NOTEBOOK (notebook), *child); }
If you want a notebook to accept drags from other widgets, you will have to set your own DnD code to do it.
Since: 2.10
setTabLabel
:: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b, IsWidget c) | |
=> a |
|
-> b |
|
-> Maybe c |
|
-> m () |
Changes the tab label for child
.
If Nothing
is specified for tabLabel
, then the page will
have the label “page N”.
setTabLabelText
notebookSetTabLabelText Source #
:: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) | |
=> a |
|
-> b |
|
-> Text |
|
-> m () |
Creates a new label and sets it as the tab label for the page
containing child
.
setTabPos
:: (HasCallStack, MonadIO m, IsNotebook a) | |
=> a |
|
-> PositionType |
|
-> m () |
Sets the edge at which the tabs for switching pages in the notebook are drawn.
setTabReorderable
notebookSetTabReorderable Source #
:: (HasCallStack, MonadIO m, IsNotebook a, IsWidget b) | |
=> a |
|
-> b |
|
-> Bool |
|
-> m () |
Sets whether the notebook tab can be reordered via drag and drop or not.
Since: 2.10
Properties
enablePopup
No description available in the introspection data.
constructNotebookEnablePopup :: (IsNotebook o, MonadIO m) => Bool -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “enable-popup
” property. This is rarely needed directly, but it is used by new
.
getNotebookEnablePopup :: (MonadIO m, IsNotebook o) => o -> m Bool Source #
Get the value of the “enable-popup
” property.
When overloading is enabled, this is equivalent to
get
notebook #enablePopup
setNotebookEnablePopup :: (MonadIO m, IsNotebook o) => o -> Bool -> m () Source #
Set the value of the “enable-popup
” property.
When overloading is enabled, this is equivalent to
set
notebook [ #enablePopup:=
value ]
groupName
Group name for tab drag and drop.
Since: 2.24
clearNotebookGroupName :: (MonadIO m, IsNotebook o) => o -> m () Source #
Set the value of the “group-name
” property to Nothing
.
When overloading is enabled, this is equivalent to
clear
#groupName
constructNotebookGroupName :: (IsNotebook o, MonadIO m) => Text -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “group-name
” property. This is rarely needed directly, but it is used by new
.
getNotebookGroupName :: (MonadIO m, IsNotebook o) => o -> m (Maybe Text) Source #
Get the value of the “group-name
” property.
When overloading is enabled, this is equivalent to
get
notebook #groupName
setNotebookGroupName :: (MonadIO m, IsNotebook o) => o -> Text -> m () Source #
Set the value of the “group-name
” property.
When overloading is enabled, this is equivalent to
set
notebook [ #groupName:=
value ]
page
No description available in the introspection data.
constructNotebookPage :: (IsNotebook o, MonadIO m) => Int32 -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “page
” property. This is rarely needed directly, but it is used by new
.
getNotebookPage :: (MonadIO m, IsNotebook o) => o -> m Int32 Source #
Get the value of the “page
” property.
When overloading is enabled, this is equivalent to
get
notebook #page
setNotebookPage :: (MonadIO m, IsNotebook o) => o -> Int32 -> m () Source #
Set the value of the “page
” property.
When overloading is enabled, this is equivalent to
set
notebook [ #page:=
value ]
scrollable
No description available in the introspection data.
constructNotebookScrollable :: (IsNotebook o, MonadIO m) => Bool -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “scrollable
” property. This is rarely needed directly, but it is used by new
.
getNotebookScrollable :: (MonadIO m, IsNotebook o) => o -> m Bool Source #
Get the value of the “scrollable
” property.
When overloading is enabled, this is equivalent to
get
notebook #scrollable
setNotebookScrollable :: (MonadIO m, IsNotebook o) => o -> Bool -> m () Source #
Set the value of the “scrollable
” property.
When overloading is enabled, this is equivalent to
set
notebook [ #scrollable:=
value ]
showBorder
No description available in the introspection data.
constructNotebookShowBorder :: (IsNotebook o, MonadIO m) => Bool -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “show-border
” property. This is rarely needed directly, but it is used by new
.
getNotebookShowBorder :: (MonadIO m, IsNotebook o) => o -> m Bool Source #
Get the value of the “show-border
” property.
When overloading is enabled, this is equivalent to
get
notebook #showBorder
setNotebookShowBorder :: (MonadIO m, IsNotebook o) => o -> Bool -> m () Source #
Set the value of the “show-border
” property.
When overloading is enabled, this is equivalent to
set
notebook [ #showBorder:=
value ]
showTabs
No description available in the introspection data.
constructNotebookShowTabs :: (IsNotebook o, MonadIO m) => Bool -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “show-tabs
” property. This is rarely needed directly, but it is used by new
.
getNotebookShowTabs :: (MonadIO m, IsNotebook o) => o -> m Bool Source #
Get the value of the “show-tabs
” property.
When overloading is enabled, this is equivalent to
get
notebook #showTabs
setNotebookShowTabs :: (MonadIO m, IsNotebook o) => o -> Bool -> m () Source #
Set the value of the “show-tabs
” property.
When overloading is enabled, this is equivalent to
set
notebook [ #showTabs:=
value ]
tabPos
No description available in the introspection data.
constructNotebookTabPos :: (IsNotebook o, MonadIO m) => PositionType -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “tab-pos
” property. This is rarely needed directly, but it is used by new
.
getNotebookTabPos :: (MonadIO m, IsNotebook o) => o -> m PositionType Source #
Get the value of the “tab-pos
” property.
When overloading is enabled, this is equivalent to
get
notebook #tabPos
setNotebookTabPos :: (MonadIO m, IsNotebook o) => o -> PositionType -> m () Source #
Set the value of the “tab-pos
” property.
When overloading is enabled, this is equivalent to
set
notebook [ #tabPos:=
value ]
Signals
changeCurrentPage
type C_NotebookChangeCurrentPageCallback = Ptr () -> Int32 -> Ptr () -> IO CInt Source #
Type for the callback on the (unwrapped) C side.
type NotebookChangeCurrentPageCallback = Int32 -> IO Bool Source #
No description available in the introspection data.
afterNotebookChangeCurrentPage :: (IsNotebook a, MonadIO m) => a -> NotebookChangeCurrentPageCallback -> m SignalHandlerId Source #
Connect a signal handler for the changeCurrentPage signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
notebook #changeCurrentPage callback
genClosure_NotebookChangeCurrentPage :: MonadIO m => NotebookChangeCurrentPageCallback -> m (GClosure C_NotebookChangeCurrentPageCallback) Source #
Wrap the callback into a GClosure
.
mk_NotebookChangeCurrentPageCallback :: C_NotebookChangeCurrentPageCallback -> IO (FunPtr C_NotebookChangeCurrentPageCallback) Source #
Generate a function pointer callable from C code, from a C_NotebookChangeCurrentPageCallback
.
noNotebookChangeCurrentPageCallback :: Maybe NotebookChangeCurrentPageCallback Source #
A convenience synonym for
.Nothing
:: Maybe
NotebookChangeCurrentPageCallback
onNotebookChangeCurrentPage :: (IsNotebook a, MonadIO m) => a -> NotebookChangeCurrentPageCallback -> m SignalHandlerId Source #
Connect a signal handler for the changeCurrentPage signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
notebook #changeCurrentPage callback
wrap_NotebookChangeCurrentPageCallback :: NotebookChangeCurrentPageCallback -> C_NotebookChangeCurrentPageCallback Source #
createWindow
type C_NotebookCreateWindowCallback = Ptr () -> Ptr Widget -> Int32 -> Int32 -> Ptr () -> IO (Ptr Notebook) Source #
Type for the callback on the (unwrapped) C side.
type NotebookCreateWindowCallback Source #
= Widget |
|
-> Int32 |
|
-> Int32 |
|
-> IO Notebook | Returns: a |
The createWindow signal is emitted when a detachable tab is dropped on the root window.
A handler for this signal can create a window containing
a notebook where the tab will be attached. It is also
responsible for moving/resizing the window and adding the
necessary properties to the notebook (e.g. the
Notebook
:group-name
).
Since: 2.12
afterNotebookCreateWindow :: (IsNotebook a, MonadIO m) => a -> NotebookCreateWindowCallback -> m SignalHandlerId Source #
Connect a signal handler for the createWindow signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
notebook #createWindow callback
genClosure_NotebookCreateWindow :: MonadIO m => NotebookCreateWindowCallback -> m (GClosure C_NotebookCreateWindowCallback) Source #
Wrap the callback into a GClosure
.
mk_NotebookCreateWindowCallback :: C_NotebookCreateWindowCallback -> IO (FunPtr C_NotebookCreateWindowCallback) Source #
Generate a function pointer callable from C code, from a C_NotebookCreateWindowCallback
.
noNotebookCreateWindowCallback :: Maybe NotebookCreateWindowCallback Source #
A convenience synonym for
.Nothing
:: Maybe
NotebookCreateWindowCallback
onNotebookCreateWindow :: (IsNotebook a, MonadIO m) => a -> NotebookCreateWindowCallback -> m SignalHandlerId Source #
Connect a signal handler for the createWindow signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
notebook #createWindow callback
wrap_NotebookCreateWindowCallback :: NotebookCreateWindowCallback -> C_NotebookCreateWindowCallback Source #
Wrap a NotebookCreateWindowCallback
into a C_NotebookCreateWindowCallback
.
focusTab
type C_NotebookFocusTabCallback = Ptr () -> CUInt -> Ptr () -> IO CInt Source #
Type for the callback on the (unwrapped) C side.
type NotebookFocusTabCallback = NotebookTab -> IO Bool Source #
No description available in the introspection data.
afterNotebookFocusTab :: (IsNotebook a, MonadIO m) => a -> NotebookFocusTabCallback -> m SignalHandlerId Source #
Connect a signal handler for the focusTab signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
notebook #focusTab callback
genClosure_NotebookFocusTab :: MonadIO m => NotebookFocusTabCallback -> m (GClosure C_NotebookFocusTabCallback) Source #
Wrap the callback into a GClosure
.
mk_NotebookFocusTabCallback :: C_NotebookFocusTabCallback -> IO (FunPtr C_NotebookFocusTabCallback) Source #
Generate a function pointer callable from C code, from a C_NotebookFocusTabCallback
.
noNotebookFocusTabCallback :: Maybe NotebookFocusTabCallback Source #
A convenience synonym for
.Nothing
:: Maybe
NotebookFocusTabCallback
onNotebookFocusTab :: (IsNotebook a, MonadIO m) => a -> NotebookFocusTabCallback -> m SignalHandlerId Source #
Connect a signal handler for the focusTab signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
notebook #focusTab callback
wrap_NotebookFocusTabCallback :: NotebookFocusTabCallback -> C_NotebookFocusTabCallback Source #
Wrap a NotebookFocusTabCallback
into a C_NotebookFocusTabCallback
.
moveFocusOut
type C_NotebookMoveFocusOutCallback = Ptr () -> CUInt -> Ptr () -> IO () Source #
Type for the callback on the (unwrapped) C side.
type NotebookMoveFocusOutCallback = DirectionType -> IO () Source #
No description available in the introspection data.
afterNotebookMoveFocusOut :: (IsNotebook a, MonadIO m) => a -> NotebookMoveFocusOutCallback -> m SignalHandlerId Source #
Connect a signal handler for the moveFocusOut signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
notebook #moveFocusOut callback
genClosure_NotebookMoveFocusOut :: MonadIO m => NotebookMoveFocusOutCallback -> m (GClosure C_NotebookMoveFocusOutCallback) Source #
Wrap the callback into a GClosure
.
mk_NotebookMoveFocusOutCallback :: C_NotebookMoveFocusOutCallback -> IO (FunPtr C_NotebookMoveFocusOutCallback) Source #
Generate a function pointer callable from C code, from a C_NotebookMoveFocusOutCallback
.
noNotebookMoveFocusOutCallback :: Maybe NotebookMoveFocusOutCallback Source #
A convenience synonym for
.Nothing
:: Maybe
NotebookMoveFocusOutCallback
onNotebookMoveFocusOut :: (IsNotebook a, MonadIO m) => a -> NotebookMoveFocusOutCallback -> m SignalHandlerId Source #
Connect a signal handler for the moveFocusOut signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
notebook #moveFocusOut callback
wrap_NotebookMoveFocusOutCallback :: NotebookMoveFocusOutCallback -> C_NotebookMoveFocusOutCallback Source #
Wrap a NotebookMoveFocusOutCallback
into a C_NotebookMoveFocusOutCallback
.
pageAdded
type C_NotebookPageAddedCallback = Ptr () -> Ptr Widget -> Word32 -> Ptr () -> IO () Source #
Type for the callback on the (unwrapped) C side.
type NotebookPageAddedCallback Source #
the pageAdded signal is emitted in the notebook right after a page is added to the notebook.
Since: 2.10
afterNotebookPageAdded :: (IsNotebook a, MonadIO m) => a -> NotebookPageAddedCallback -> m SignalHandlerId Source #
Connect a signal handler for the pageAdded signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
notebook #pageAdded callback
genClosure_NotebookPageAdded :: MonadIO m => NotebookPageAddedCallback -> m (GClosure C_NotebookPageAddedCallback) Source #
Wrap the callback into a GClosure
.
mk_NotebookPageAddedCallback :: C_NotebookPageAddedCallback -> IO (FunPtr C_NotebookPageAddedCallback) Source #
Generate a function pointer callable from C code, from a C_NotebookPageAddedCallback
.
noNotebookPageAddedCallback :: Maybe NotebookPageAddedCallback Source #
A convenience synonym for
.Nothing
:: Maybe
NotebookPageAddedCallback
onNotebookPageAdded :: (IsNotebook a, MonadIO m) => a -> NotebookPageAddedCallback -> m SignalHandlerId Source #
Connect a signal handler for the pageAdded signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
notebook #pageAdded callback
wrap_NotebookPageAddedCallback :: NotebookPageAddedCallback -> C_NotebookPageAddedCallback Source #
Wrap a NotebookPageAddedCallback
into a C_NotebookPageAddedCallback
.
pageRemoved
type C_NotebookPageRemovedCallback = Ptr () -> Ptr Widget -> Word32 -> Ptr () -> IO () Source #
Type for the callback on the (unwrapped) C side.
type NotebookPageRemovedCallback Source #
the pageRemoved signal is emitted in the notebook right after a page is removed from the notebook.
Since: 2.10
afterNotebookPageRemoved :: (IsNotebook a, MonadIO m) => a -> NotebookPageRemovedCallback -> m SignalHandlerId Source #
Connect a signal handler for the pageRemoved signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
notebook #pageRemoved callback
genClosure_NotebookPageRemoved :: MonadIO m => NotebookPageRemovedCallback -> m (GClosure C_NotebookPageRemovedCallback) Source #
Wrap the callback into a GClosure
.
mk_NotebookPageRemovedCallback :: C_NotebookPageRemovedCallback -> IO (FunPtr C_NotebookPageRemovedCallback) Source #
Generate a function pointer callable from C code, from a C_NotebookPageRemovedCallback
.
noNotebookPageRemovedCallback :: Maybe NotebookPageRemovedCallback Source #
A convenience synonym for
.Nothing
:: Maybe
NotebookPageRemovedCallback
onNotebookPageRemoved :: (IsNotebook a, MonadIO m) => a -> NotebookPageRemovedCallback -> m SignalHandlerId Source #
Connect a signal handler for the pageRemoved signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
notebook #pageRemoved callback
wrap_NotebookPageRemovedCallback :: NotebookPageRemovedCallback -> C_NotebookPageRemovedCallback Source #
Wrap a NotebookPageRemovedCallback
into a C_NotebookPageRemovedCallback
.
pageReordered
type C_NotebookPageReorderedCallback = Ptr () -> Ptr Widget -> Word32 -> Ptr () -> IO () Source #
Type for the callback on the (unwrapped) C side.
type NotebookPageReorderedCallback Source #
the pageReordered signal is emitted in the notebook right after a page has been reordered.
Since: 2.10
afterNotebookPageReordered :: (IsNotebook a, MonadIO m) => a -> NotebookPageReorderedCallback -> m SignalHandlerId Source #
Connect a signal handler for the pageReordered signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
notebook #pageReordered callback
genClosure_NotebookPageReordered :: MonadIO m => NotebookPageReorderedCallback -> m (GClosure C_NotebookPageReorderedCallback) Source #
Wrap the callback into a GClosure
.
mk_NotebookPageReorderedCallback :: C_NotebookPageReorderedCallback -> IO (FunPtr C_NotebookPageReorderedCallback) Source #
Generate a function pointer callable from C code, from a C_NotebookPageReorderedCallback
.
noNotebookPageReorderedCallback :: Maybe NotebookPageReorderedCallback Source #
A convenience synonym for
.Nothing
:: Maybe
NotebookPageReorderedCallback
onNotebookPageReordered :: (IsNotebook a, MonadIO m) => a -> NotebookPageReorderedCallback -> m SignalHandlerId Source #
Connect a signal handler for the pageReordered signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
notebook #pageReordered callback
wrap_NotebookPageReorderedCallback :: NotebookPageReorderedCallback -> C_NotebookPageReorderedCallback Source #
Wrap a NotebookPageReorderedCallback
into a C_NotebookPageReorderedCallback
.
reorderTab
type C_NotebookReorderTabCallback = Ptr () -> CUInt -> CInt -> Ptr () -> IO CInt Source #
Type for the callback on the (unwrapped) C side.
type NotebookReorderTabCallback = DirectionType -> Bool -> IO Bool Source #
No description available in the introspection data.
afterNotebookReorderTab :: (IsNotebook a, MonadIO m) => a -> NotebookReorderTabCallback -> m SignalHandlerId Source #
Connect a signal handler for the reorderTab signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
notebook #reorderTab callback
genClosure_NotebookReorderTab :: MonadIO m => NotebookReorderTabCallback -> m (GClosure C_NotebookReorderTabCallback) Source #
Wrap the callback into a GClosure
.
mk_NotebookReorderTabCallback :: C_NotebookReorderTabCallback -> IO (FunPtr C_NotebookReorderTabCallback) Source #
Generate a function pointer callable from C code, from a C_NotebookReorderTabCallback
.
noNotebookReorderTabCallback :: Maybe NotebookReorderTabCallback Source #
A convenience synonym for
.Nothing
:: Maybe
NotebookReorderTabCallback
onNotebookReorderTab :: (IsNotebook a, MonadIO m) => a -> NotebookReorderTabCallback -> m SignalHandlerId Source #
Connect a signal handler for the reorderTab signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
notebook #reorderTab callback
wrap_NotebookReorderTabCallback :: NotebookReorderTabCallback -> C_NotebookReorderTabCallback Source #
Wrap a NotebookReorderTabCallback
into a C_NotebookReorderTabCallback
.
selectPage
type C_NotebookSelectPageCallback = Ptr () -> CInt -> Ptr () -> IO CInt Source #
Type for the callback on the (unwrapped) C side.
type NotebookSelectPageCallback = Bool -> IO Bool Source #
No description available in the introspection data.
afterNotebookSelectPage :: (IsNotebook a, MonadIO m) => a -> NotebookSelectPageCallback -> m SignalHandlerId Source #
Connect a signal handler for the selectPage signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
notebook #selectPage callback
genClosure_NotebookSelectPage :: MonadIO m => NotebookSelectPageCallback -> m (GClosure C_NotebookSelectPageCallback) Source #
Wrap the callback into a GClosure
.
mk_NotebookSelectPageCallback :: C_NotebookSelectPageCallback -> IO (FunPtr C_NotebookSelectPageCallback) Source #
Generate a function pointer callable from C code, from a C_NotebookSelectPageCallback
.
noNotebookSelectPageCallback :: Maybe NotebookSelectPageCallback Source #
A convenience synonym for
.Nothing
:: Maybe
NotebookSelectPageCallback
onNotebookSelectPage :: (IsNotebook a, MonadIO m) => a -> NotebookSelectPageCallback -> m SignalHandlerId Source #
Connect a signal handler for the selectPage signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
notebook #selectPage callback
wrap_NotebookSelectPageCallback :: NotebookSelectPageCallback -> C_NotebookSelectPageCallback Source #
Wrap a NotebookSelectPageCallback
into a C_NotebookSelectPageCallback
.
switchPage
type C_NotebookSwitchPageCallback = Ptr () -> Ptr Widget -> Word32 -> Ptr () -> IO () Source #
Type for the callback on the (unwrapped) C side.
type NotebookSwitchPageCallback Source #
Emitted when the user or a function changes the current page.
afterNotebookSwitchPage :: (IsNotebook a, MonadIO m) => a -> NotebookSwitchPageCallback -> m SignalHandlerId Source #
Connect a signal handler for the switchPage signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
notebook #switchPage callback
genClosure_NotebookSwitchPage :: MonadIO m => NotebookSwitchPageCallback -> m (GClosure C_NotebookSwitchPageCallback) Source #
Wrap the callback into a GClosure
.
mk_NotebookSwitchPageCallback :: C_NotebookSwitchPageCallback -> IO (FunPtr C_NotebookSwitchPageCallback) Source #
Generate a function pointer callable from C code, from a C_NotebookSwitchPageCallback
.
noNotebookSwitchPageCallback :: Maybe NotebookSwitchPageCallback Source #
A convenience synonym for
.Nothing
:: Maybe
NotebookSwitchPageCallback
onNotebookSwitchPage :: (IsNotebook a, MonadIO m) => a -> NotebookSwitchPageCallback -> m SignalHandlerId Source #
Connect a signal handler for the switchPage signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
notebook #switchPage callback