Stack -package:ghc

Access to GHC's call-stack simulation
TextShow instances for CallStack and SrcLoc values. Since: 3.0.1
A widget which controls the alignment and size of its child
This is a simple process type that knows how to push back input.
GtkStack is a container which only shows one of its children at a time. In contrast to GtkNotebook, GtkStack does not provide a means for users to change the visible child. Instead, a separate widget such as StackSwitcher or StackSidebar can be used with GtkStack to provide this functionality. Transitions between pages can be animated as slides or fades. This can be controlled with stackSetTransitionType. These animations respect the Settings:gtkEnableAnimations setting. GtkStack maintains a StackPage object for each added child, which holds additional per-child properties. You obtain the GtkStackPage for a child with stackGetPage and you can obtain a GtkSelectionModel containing all the pages with stackGetPages.

GtkStack as GtkBuildable

To set child-specific properties in a .ui file, create GtkStackPage objects explicitly, and set the child widget as a property on it:

xml code

<object class="GtkStack" id="stack">
<child>
<object class="GtkStackPage">
<property name="name">page1</property>
<property name="title">In the beginning…</property>
<property name="child">
<object class="GtkLabel">
<property name="label">It was dark</property>
</object>
</property>
</object>
</child>

CSS nodes

GtkStack has a single CSS node named stack.

Accessibility

GtkStack uses the AccessibleRoleTabPanel for the stack pages, which are the accessible parent objects of the child widgets.
Memory-managed wrapper type.
A stack is a cursor onto a window list. The data structure tracks focus by construction, and the master window is by convention the top-most item. Focus operations will not reorder the list that results from flattening the cursor. The structure can be envisaged as:
+-- master:  < '7' >
up |            [ '2' ]
+---------   [ '3' ]
focus:          < '4' >
dn +----------- [ '8' ]
A Stack can be viewed as a list with a hole punched in it to make the focused position. Under the zipper/calculus view of such structures, it is the differentiation of a [a], and integrating it back has a natural implementation used in index.
Access to GHC's call-stack simulation
Internal monad for the resolution algorithm
  • we keep some state for the list of created values
  • we collect the applied functions as Operations
  • we might exit with a Left value if we can't build a value
Monadic stack for the resolution algorithm