TreeViewProtocol
public protocol TreeViewProtocol : ScrollableProtocol, WidgetProtocol
A widget for displaying both trees and lists
Widget that displays any object that implements the [ifaceGtk.TreeModel
] interface.
Please refer to the tree widget conceptual overview for an overview of all the objects and data types related to the tree widget and how they work together.
Coordinate systems in GtkTreeView API
Several different coordinate systems are exposed in the GtkTreeView
API.
These are:
Widget coordinates: Coordinates relative to the widget (usually
widget->window
).Bin window coordinates: Coordinates relative to the window that GtkTreeView renders to.
Tree coordinates: Coordinates relative to the entire scrollable area of GtkTreeView. These coordinates start at (0, 0) for row 0 of the tree.
Several functions are available for converting between the different
coordinate systems. The most common translations are between widget and bin
window coordinates and between bin window and tree coordinates. For the
former you can use methodGtk.TreeView.convert_widget_to_bin_window_coords
, for the latter methodGtk.TreeView.convert_bin_window_to_tree_coords
.
GtkTreeView
as GtkBuildable
The GtkTreeView
implementation of the GtkBuildable
interface accepts
[classGtk.TreeViewColumn
] objects as <child>
elements and exposes the
internal [classGtk.TreeSelection
] in UI definitions.
An example of a UI definition fragment with GtkTreeView
:
<object class="GtkTreeView" id="treeview">
<property name="model">liststore1</property>
<child>
<object class="GtkTreeViewColumn" id="test-column">
<property name="title">Test</property>
<child>
<object class="GtkCellRendererText" id="test-renderer"/>
<attributes>
<attribute name="text">1</attribute>
</attributes>
</child>
</object>
</child>
<child internal-child="selection">
<object class="GtkTreeSelection" id="selection">
<signal name="changed" handler="on_treeview_selection_changed"/>
</object>
</child>
</object>
CSS nodes
treeview.view
├── header
│ ├── button
│ │ ╰── [sort-indicator]
┊ ┊
│ ╰── button
│ ╰── [sort-indicator]
│
├── [rubberband]
╰── [dndtarget]
GtkTreeView
has a main CSS node with name treeview
and style class .view
.
It has a subnode with name header
, which is the parent for all the column
header widgets’ CSS nodes.
Each column header consists of a button
, which among other content, has a
child with name sort-indicator
, which carries the .ascending
or .descending
style classes when the column header should show a sort indicator. The CSS
is expected to provide a suitable image using the -gtk-icon-source
property.
For rubberband selection, a subnode with name rubberband
is used.
For the drop target location during DND, a subnode with name dndtarget
is used.
The TreeViewProtocol
protocol exposes the methods and properties of an underlying GtkTreeView
instance.
The default implementation of these can be found in the protocol extension below.
For a concrete class that implements these methods and properties, see TreeView
.
Alternatively, use TreeViewRef
as a lighweight, unowned
reference if you already have an instance you just want to use.
-
Untyped pointer to the underlying
GtkTreeView
instance.Declaration
Swift
var ptr: UnsafeMutableRawPointer! { get }
-
tree_view_ptr
Default implementationTyped pointer to the underlying
GtkTreeView
instance.Default Implementation
Return the stored, untyped pointer as a typed pointer to the
GtkTreeView
instance.Declaration
Swift
var tree_view_ptr: UnsafeMutablePointer<GtkTreeView>! { get }
-
Required Initialiser for types conforming to
TreeViewProtocol
Declaration
Swift
init(raw: UnsafeMutableRawPointer)
-
bind(property:
Extension methodto: _: flags: transformFrom: transformTo: ) Bind a
TreeViewPropertyName
source property to a given target object.Declaration
Swift
@discardableResult @inlinable func bind<Q, T>(property source_property: TreeViewPropertyName, to target: T, _ target_property: Q, flags f: BindingFlags = .default, transformFrom transform_from: @escaping GLibObject.ValueTransformer = { $0.transform(destValue: $1) }, transformTo transform_to: @escaping GLibObject.ValueTransformer = { $0.transform(destValue: $1) }) -> BindingRef! where Q : PropertyNameProtocol, T : ObjectProtocol
Parameters
source_property
the source property to bind
target
the target object to bind to
target_property
the target property to bind to
flags
the flags to pass to the
Binding
transform_from
ValueTransformer
to use for forward transformationtransform_to
ValueTransformer
to use for backwards transformationReturn Value
binding reference or
nil
in case of an error -
get(property:
Extension method) Get the value of a TreeView property
Declaration
Swift
@inlinable func get(property: TreeViewPropertyName) -> GLibObject.Value
Parameters
property
the property to get the value for
Return Value
the value of the named property
-
set(property:
Extension methodvalue: ) Set the value of a TreeView property. Note that this will only have an effect on properties that are writable and not construct-only!
Declaration
Swift
@inlinable func set(property: TreeViewPropertyName, value v: GLibObject.Value)
Parameters
property
the property to get the value for
Return Value
the value of the named property
-
connect(signal:
Extension methodflags: handler: ) Connect a Swift signal handler to the given, typed
TreeViewSignalName
signalDeclaration
Swift
@discardableResult @inlinable func connect(signal s: TreeViewSignalName, flags f: ConnectFlags = ConnectFlags(0), handler h: @escaping SignalHandler) -> Int
Parameters
signal
The signal to connect
flags
The connection flags to use
data
A pointer to user data to provide to the callback
destroyData
A
GClosureNotify
C function to destroy the data pointed to byuserData
handler
The Swift signal handler (function or callback) to invoke on the given signal
Return Value
The signal handler ID (always greater than 0 for successful connections)
-
connect(signal:
Extension methodflags: data: destroyData: signalHandler: ) Connect a C signal handler to the given, typed
TreeViewSignalName
signalDeclaration
Swift
@discardableResult @inlinable func connect(signal s: TreeViewSignalName, flags f: ConnectFlags = ConnectFlags(0), data userData: gpointer!, destroyData destructor: GClosureNotify? = nil, signalHandler h: @escaping GCallback) -> Int
Parameters
signal
The signal to connect
flags
The connection flags to use
data
A pointer to user data to provide to the callback
destroyData
A
GClosureNotify
C function to destroy the data pointed to byuserData
signalHandler
The C function to be called on the given signal
Return Value
The signal handler ID (always greater than 0 for successful connections)
-
onColumnsChanged(flags:
Extension methodhandler: ) The number of columns of the treeview has changed.
Note
This represents the underlyingcolumns-changed
signalDeclaration
Swift
@discardableResult @inlinable func onColumnsChanged(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef) -> Void) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
handler
The signal handler to call Run the given callback whenever the
columnsChanged
signal is emitted -
columnsChangedSignal
Extension methodTyped
columns-changed
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var columnsChangedSignal: TreeViewSignalName { get }
-
onCursorChanged(flags:
Extension methodhandler: ) The position of the cursor (focused cell) has changed.
Note
This represents the underlyingcursor-changed
signalDeclaration
Swift
@discardableResult @inlinable func onCursorChanged(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef) -> Void) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
handler
The signal handler to call Run the given callback whenever the
cursorChanged
signal is emitted -
cursorChangedSignal
Extension methodTyped
cursor-changed
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var cursorChangedSignal: TreeViewSignalName { get }
-
onExpandCollapseCursorRow(flags:
Extension methodhandler: ) Note
This represents the underlyingexpand-collapse-cursor-row
signalDeclaration
Swift
@discardableResult @inlinable func onExpandCollapseCursorRow(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ object: Bool, _ p0: Bool, _ p1: Bool) -> Bool) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
object
none
p0
none
p1
none
handler
The signal handler to call Run the given callback whenever the
expandCollapseCursorRow
signal is emitted -
expandCollapseCursorRowSignal
Extension methodTyped
expand-collapse-cursor-row
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var expandCollapseCursorRowSignal: TreeViewSignalName { get }
-
onMoveCursor(flags:
Extension methodhandler: ) The
GtkTreeView
move-cursor
signal is a keybinding signal which gets emitted when the user presses one of the cursor keys.Applications should not connect to it, but may emit it with
g_signal_emit_by_name()
if they need to control the cursor programmatically. In contrast togtk_tree_view_set_cursor()
andgtk_tree_view_set_cursor_on_cell()
when moving horizontallyGtkTreeView
move-cursor
does not reset the current selection.Note
This represents the underlyingmove-cursor
signalDeclaration
Swift
@discardableResult @inlinable func onMoveCursor(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ step: MovementStep, _ direction: Int, _ extend: Bool, _ modify: Bool) -> Bool) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
step
the granularity of the move, as a
GtkMovementStep
.GTK_MOVEMENT_LOGICAL_POSITIONS
,GTK_MOVEMENT_VISUAL_POSITIONS
,GTK_MOVEMENT_DISPLAY_LINES
,GTK_MOVEMENT_PAGES
andGTK_MOVEMENT_BUFFER_ENDS
are supported.GTK_MOVEMENT_LOGICAL_POSITIONS
andGTK_MOVEMENT_VISUAL_POSITIONS
are treated identically.direction
the direction to move: +1 to move forwards; -1 to move backwards. The resulting movement is undefined for all other values.
extend
whether to extend the selection
modify
whether to modify the selection
handler
true
ifstep
is supported,false
otherwise. Run the given callback whenever themoveCursor
signal is emitted -
moveCursorSignal
Extension methodTyped
move-cursor
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var moveCursorSignal: TreeViewSignalName { get }
-
onRowActivated(flags:
Extension methodhandler: ) The “row-activated” signal is emitted when the method
gtk_tree_view_row_activated()
is called.This signal is emitted when the user double-clicks a treeview row with the [property
Gtk.TreeView:activate-on-single-click
] property set tofalse
, or when the user single-clicks a row when that property set totrue
.This signal is also emitted when a non-editable row is selected and one of the keys: <kbd>Space</kbd>, <kbd>Shift</kbd>+<kbd>Space</kbd>, <kbd>Return</kbd> or <kbd>Enter</kbd> is pressed.
For selection handling refer to the tree widget conceptual overview as well as
GtkTreeSelection
.Note
This represents the underlyingrow-activated
signalDeclaration
Swift
@discardableResult @inlinable func onRowActivated(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ path: TreePathRef, _ column: TreeViewColumnRef?) -> Void) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
path
the
GtkTreePath
for the activated rowcolumn
the
GtkTreeViewColumn
in which the activation occurredhandler
The signal handler to call Run the given callback whenever the
rowActivated
signal is emitted -
rowActivatedSignal
Extension methodTyped
row-activated
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var rowActivatedSignal: TreeViewSignalName { get }
-
onRowCollapsed(flags:
Extension methodhandler: ) The given row has been collapsed (child nodes are hidden).
Note
This represents the underlyingrow-collapsed
signalDeclaration
Swift
@discardableResult @inlinable func onRowCollapsed(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ iter: TreeIterRef, _ path: TreePathRef) -> Void) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
iter
the tree iter of the collapsed row
path
a tree path that points to the row
handler
The signal handler to call Run the given callback whenever the
rowCollapsed
signal is emitted -
rowCollapsedSignal
Extension methodTyped
row-collapsed
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var rowCollapsedSignal: TreeViewSignalName { get }
-
onRowExpanded(flags:
Extension methodhandler: ) The given row has been expanded (child nodes are shown).
Note
This represents the underlyingrow-expanded
signalDeclaration
Swift
@discardableResult @inlinable func onRowExpanded(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ iter: TreeIterRef, _ path: TreePathRef) -> Void) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
iter
the tree iter of the expanded row
path
a tree path that points to the row
handler
The signal handler to call Run the given callback whenever the
rowExpanded
signal is emitted -
rowExpandedSignal
Extension methodTyped
row-expanded
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var rowExpandedSignal: TreeViewSignalName { get }
-
onSelectAll(flags:
Extension methodhandler: ) Note
This represents the underlyingselect-all
signalDeclaration
Swift
@discardableResult @inlinable func onSelectAll(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef) -> Bool) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
handler
The signal handler to call Run the given callback whenever the
selectAll
signal is emitted -
selectAllSignal
Extension methodTyped
select-all
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var selectAllSignal: TreeViewSignalName { get }
-
onSelectCursorParent(flags:
Extension methodhandler: ) Note
This represents the underlyingselect-cursor-parent
signalDeclaration
Swift
@discardableResult @inlinable func onSelectCursorParent(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef) -> Bool) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
handler
The signal handler to call Run the given callback whenever the
selectCursorParent
signal is emitted -
selectCursorParentSignal
Extension methodTyped
select-cursor-parent
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var selectCursorParentSignal: TreeViewSignalName { get }
-
onSelectCursorRow(flags:
Extension methodhandler: ) Note
This represents the underlyingselect-cursor-row
signalDeclaration
Swift
@discardableResult @inlinable func onSelectCursorRow(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ object: Bool) -> Bool) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
object
none
handler
The signal handler to call Run the given callback whenever the
selectCursorRow
signal is emitted -
selectCursorRowSignal
Extension methodTyped
select-cursor-row
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var selectCursorRowSignal: TreeViewSignalName { get }
-
onStartInteractiveSearch(flags:
Extension methodhandler: ) Note
This represents the underlyingstart-interactive-search
signalDeclaration
Swift
@discardableResult @inlinable func onStartInteractiveSearch(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef) -> Bool) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
handler
The signal handler to call Run the given callback whenever the
startInteractiveSearch
signal is emitted -
startInteractiveSearchSignal
Extension methodTyped
start-interactive-search
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var startInteractiveSearchSignal: TreeViewSignalName { get }
-
onTestCollapseRow(flags:
Extension methodhandler: ) The given row is about to be collapsed (hide its children nodes). Use this signal if you need to control the collapsibility of individual rows.
Note
This represents the underlyingtest-collapse-row
signalDeclaration
Swift
@discardableResult @inlinable func onTestCollapseRow(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ iter: TreeIterRef, _ path: TreePathRef) -> Bool) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
iter
the tree iter of the row to collapse
path
a tree path that points to the row
handler
false
to allow collapsing,true
to reject Run the given callback whenever thetestCollapseRow
signal is emitted -
testCollapseRowSignal
Extension methodTyped
test-collapse-row
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var testCollapseRowSignal: TreeViewSignalName { get }
-
onTestExpandRow(flags:
Extension methodhandler: ) The given row is about to be expanded (show its children nodes). Use this signal if you need to control the expandability of individual rows.
Note
This represents the underlyingtest-expand-row
signalDeclaration
Swift
@discardableResult @inlinable func onTestExpandRow(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ iter: TreeIterRef, _ path: TreePathRef) -> Bool) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
iter
the tree iter of the row to expand
path
a tree path that points to the row
handler
false
to allow expansion,true
to reject Run the given callback whenever thetestExpandRow
signal is emitted -
testExpandRowSignal
Extension methodTyped
test-expand-row
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var testExpandRowSignal: TreeViewSignalName { get }
-
onToggleCursorRow(flags:
Extension methodhandler: ) Note
This represents the underlyingtoggle-cursor-row
signalDeclaration
Swift
@discardableResult @inlinable func onToggleCursorRow(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef) -> Bool) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
handler
The signal handler to call Run the given callback whenever the
toggleCursorRow
signal is emitted -
toggleCursorRowSignal
Extension methodTyped
toggle-cursor-row
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var toggleCursorRowSignal: TreeViewSignalName { get }
-
onUnselectAll(flags:
Extension methodhandler: ) Note
This represents the underlyingunselect-all
signalDeclaration
Swift
@discardableResult @inlinable func onUnselectAll(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef) -> Bool) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
handler
The signal handler to call Run the given callback whenever the
unselectAll
signal is emitted -
unselectAllSignal
Extension methodTyped
unselect-all
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var unselectAllSignal: TreeViewSignalName { get }
-
onNotifyActivateOnSingleClick(flags:
Extension methodhandler: ) The notify signal is emitted on an object when one of its properties has its value set through
g_object_set_property()
,g_object_set()
, et al.Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with
G_PARAM_EXPLICIT_NOTIFY
, then any call tog_object_set_property()
results innotify
being emitted, even if the new value is the same as the old. If they did passG_PARAM_EXPLICIT_NOTIFY
, then this signal is emitted only when they explicitly callg_object_notify()
org_object_notify_by_pspec()
, and common practice is to do that only when the value has actually changed.This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the
g_signal_connect()
call, like this:(C Language Example):
g_signal_connect (text_view->buffer, "notify::paste-target-list", G_CALLBACK (gtk_text_view_target_list_notify), text_view)
It is important to note that you must use canonical parameter names as detail strings for the notify signal.
Note
This represents the underlyingnotify::activate-on-single-click
signalDeclaration
Swift
@discardableResult @inlinable func onNotifyActivateOnSingleClick(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ pspec: ParamSpecRef) -> Void) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
pspec
the
GParamSpec
of the property which changed.handler
The signal handler to call Run the given callback whenever the
notifyActivateOnSingleClick
signal is emitted -
notifyActivateOnSingleClickSignal
Extension methodTyped
notify::activate-on-single-click
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var notifyActivateOnSingleClickSignal: TreeViewSignalName { get }
-
onNotifyEnableGridLines(flags:
Extension methodhandler: ) The notify signal is emitted on an object when one of its properties has its value set through
g_object_set_property()
,g_object_set()
, et al.Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with
G_PARAM_EXPLICIT_NOTIFY
, then any call tog_object_set_property()
results innotify
being emitted, even if the new value is the same as the old. If they did passG_PARAM_EXPLICIT_NOTIFY
, then this signal is emitted only when they explicitly callg_object_notify()
org_object_notify_by_pspec()
, and common practice is to do that only when the value has actually changed.This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the
g_signal_connect()
call, like this:(C Language Example):
g_signal_connect (text_view->buffer, "notify::paste-target-list", G_CALLBACK (gtk_text_view_target_list_notify), text_view)
It is important to note that you must use canonical parameter names as detail strings for the notify signal.
Note
This represents the underlyingnotify::enable-grid-lines
signalDeclaration
Swift
@discardableResult @inlinable func onNotifyEnableGridLines(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ pspec: ParamSpecRef) -> Void) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
pspec
the
GParamSpec
of the property which changed.handler
The signal handler to call Run the given callback whenever the
notifyEnableGridLines
signal is emitted -
notifyEnableGridLinesSignal
Extension methodTyped
notify::enable-grid-lines
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var notifyEnableGridLinesSignal: TreeViewSignalName { get }
-
onNotifyEnableSearch(flags:
Extension methodhandler: ) The notify signal is emitted on an object when one of its properties has its value set through
g_object_set_property()
,g_object_set()
, et al.Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with
G_PARAM_EXPLICIT_NOTIFY
, then any call tog_object_set_property()
results innotify
being emitted, even if the new value is the same as the old. If they did passG_PARAM_EXPLICIT_NOTIFY
, then this signal is emitted only when they explicitly callg_object_notify()
org_object_notify_by_pspec()
, and common practice is to do that only when the value has actually changed.This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the
g_signal_connect()
call, like this:(C Language Example):
g_signal_connect (text_view->buffer, "notify::paste-target-list", G_CALLBACK (gtk_text_view_target_list_notify), text_view)
It is important to note that you must use canonical parameter names as detail strings for the notify signal.
Note
This represents the underlyingnotify::enable-search
signalDeclaration
Swift
@discardableResult @inlinable func onNotifyEnableSearch(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ pspec: ParamSpecRef) -> Void) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
pspec
the
GParamSpec
of the property which changed.handler
The signal handler to call Run the given callback whenever the
notifyEnableSearch
signal is emitted -
notifyEnableSearchSignal
Extension methodTyped
notify::enable-search
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var notifyEnableSearchSignal: TreeViewSignalName { get }
-
onNotifyEnableTreeLines(flags:
Extension methodhandler: ) The notify signal is emitted on an object when one of its properties has its value set through
g_object_set_property()
,g_object_set()
, et al.Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with
G_PARAM_EXPLICIT_NOTIFY
, then any call tog_object_set_property()
results innotify
being emitted, even if the new value is the same as the old. If they did passG_PARAM_EXPLICIT_NOTIFY
, then this signal is emitted only when they explicitly callg_object_notify()
org_object_notify_by_pspec()
, and common practice is to do that only when the value has actually changed.This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the
g_signal_connect()
call, like this:(C Language Example):
g_signal_connect (text_view->buffer, "notify::paste-target-list", G_CALLBACK (gtk_text_view_target_list_notify), text_view)
It is important to note that you must use canonical parameter names as detail strings for the notify signal.
Note
This represents the underlyingnotify::enable-tree-lines
signalDeclaration
Swift
@discardableResult @inlinable func onNotifyEnableTreeLines(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ pspec: ParamSpecRef) -> Void) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
pspec
the
GParamSpec
of the property which changed.handler
The signal handler to call Run the given callback whenever the
notifyEnableTreeLines
signal is emitted -
notifyEnableTreeLinesSignal
Extension methodTyped
notify::enable-tree-lines
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var notifyEnableTreeLinesSignal: TreeViewSignalName { get }
-
onNotifyExpanderColumn(flags:
Extension methodhandler: ) The notify signal is emitted on an object when one of its properties has its value set through
g_object_set_property()
,g_object_set()
, et al.Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with
G_PARAM_EXPLICIT_NOTIFY
, then any call tog_object_set_property()
results innotify
being emitted, even if the new value is the same as the old. If they did passG_PARAM_EXPLICIT_NOTIFY
, then this signal is emitted only when they explicitly callg_object_notify()
org_object_notify_by_pspec()
, and common practice is to do that only when the value has actually changed.This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the
g_signal_connect()
call, like this:(C Language Example):
g_signal_connect (text_view->buffer, "notify::paste-target-list", G_CALLBACK (gtk_text_view_target_list_notify), text_view)
It is important to note that you must use canonical parameter names as detail strings for the notify signal.
Note
This represents the underlyingnotify::expander-column
signalDeclaration
Swift
@discardableResult @inlinable func onNotifyExpanderColumn(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ pspec: ParamSpecRef) -> Void) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
pspec
the
GParamSpec
of the property which changed.handler
The signal handler to call Run the given callback whenever the
notifyExpanderColumn
signal is emitted -
notifyExpanderColumnSignal
Extension methodTyped
notify::expander-column
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var notifyExpanderColumnSignal: TreeViewSignalName { get }
-
onNotifyFixedHeightMode(flags:
Extension methodhandler: ) The notify signal is emitted on an object when one of its properties has its value set through
g_object_set_property()
,g_object_set()
, et al.Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with
G_PARAM_EXPLICIT_NOTIFY
, then any call tog_object_set_property()
results innotify
being emitted, even if the new value is the same as the old. If they did passG_PARAM_EXPLICIT_NOTIFY
, then this signal is emitted only when they explicitly callg_object_notify()
org_object_notify_by_pspec()
, and common practice is to do that only when the value has actually changed.This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the
g_signal_connect()
call, like this:(C Language Example):
g_signal_connect (text_view->buffer, "notify::paste-target-list", G_CALLBACK (gtk_text_view_target_list_notify), text_view)
It is important to note that you must use canonical parameter names as detail strings for the notify signal.
Note
This represents the underlyingnotify::fixed-height-mode
signalDeclaration
Swift
@discardableResult @inlinable func onNotifyFixedHeightMode(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ pspec: ParamSpecRef) -> Void) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
pspec
the
GParamSpec
of the property which changed.handler
The signal handler to call Run the given callback whenever the
notifyFixedHeightMode
signal is emitted -
notifyFixedHeightModeSignal
Extension methodTyped
notify::fixed-height-mode
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var notifyFixedHeightModeSignal: TreeViewSignalName { get }
-
onNotifyHeadersClickable(flags:
Extension methodhandler: ) The notify signal is emitted on an object when one of its properties has its value set through
g_object_set_property()
,g_object_set()
, et al.Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with
G_PARAM_EXPLICIT_NOTIFY
, then any call tog_object_set_property()
results innotify
being emitted, even if the new value is the same as the old. If they did passG_PARAM_EXPLICIT_NOTIFY
, then this signal is emitted only when they explicitly callg_object_notify()
org_object_notify_by_pspec()
, and common practice is to do that only when the value has actually changed.This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the
g_signal_connect()
call, like this:(C Language Example):
g_signal_connect (text_view->buffer, "notify::paste-target-list", G_CALLBACK (gtk_text_view_target_list_notify), text_view)
It is important to note that you must use canonical parameter names as detail strings for the notify signal.
Note
This represents the underlyingnotify::headers-clickable
signalDeclaration
Swift
@discardableResult @inlinable func onNotifyHeadersClickable(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ pspec: ParamSpecRef) -> Void) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
pspec
the
GParamSpec
of the property which changed.handler
The signal handler to call Run the given callback whenever the
notifyHeadersClickable
signal is emitted -
notifyHeadersClickableSignal
Extension methodTyped
notify::headers-clickable
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var notifyHeadersClickableSignal: TreeViewSignalName { get }
-
onNotifyHeadersVisible(flags:
Extension methodhandler: ) The notify signal is emitted on an object when one of its properties has its value set through
g_object_set_property()
,g_object_set()
, et al.Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with
G_PARAM_EXPLICIT_NOTIFY
, then any call tog_object_set_property()
results innotify
being emitted, even if the new value is the same as the old. If they did passG_PARAM_EXPLICIT_NOTIFY
, then this signal is emitted only when they explicitly callg_object_notify()
org_object_notify_by_pspec()
, and common practice is to do that only when the value has actually changed.This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the
g_signal_connect()
call, like this:(C Language Example):
g_signal_connect (text_view->buffer, "notify::paste-target-list", G_CALLBACK (gtk_text_view_target_list_notify), text_view)
It is important to note that you must use canonical parameter names as detail strings for the notify signal.
Note
This represents the underlyingnotify::headers-visible
signalDeclaration
Swift
@discardableResult @inlinable func onNotifyHeadersVisible(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ pspec: ParamSpecRef) -> Void) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
pspec
the
GParamSpec
of the property which changed.handler
The signal handler to call Run the given callback whenever the
notifyHeadersVisible
signal is emitted -
notifyHeadersVisibleSignal
Extension methodTyped
notify::headers-visible
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var notifyHeadersVisibleSignal: TreeViewSignalName { get }
-
onNotifyHoverExpand(flags:
Extension methodhandler: ) The notify signal is emitted on an object when one of its properties has its value set through
g_object_set_property()
,g_object_set()
, et al.Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with
G_PARAM_EXPLICIT_NOTIFY
, then any call tog_object_set_property()
results innotify
being emitted, even if the new value is the same as the old. If they did passG_PARAM_EXPLICIT_NOTIFY
, then this signal is emitted only when they explicitly callg_object_notify()
org_object_notify_by_pspec()
, and common practice is to do that only when the value has actually changed.This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the
g_signal_connect()
call, like this:(C Language Example):
g_signal_connect (text_view->buffer, "notify::paste-target-list", G_CALLBACK (gtk_text_view_target_list_notify), text_view)
It is important to note that you must use canonical parameter names as detail strings for the notify signal.
Note
This represents the underlyingnotify::hover-expand
signalDeclaration
Swift
@discardableResult @inlinable func onNotifyHoverExpand(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ pspec: ParamSpecRef) -> Void) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
pspec
the
GParamSpec
of the property which changed.handler
The signal handler to call Run the given callback whenever the
notifyHoverExpand
signal is emitted -
notifyHoverExpandSignal
Extension methodTyped
notify::hover-expand
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var notifyHoverExpandSignal: TreeViewSignalName { get }
-
onNotifyHoverSelection(flags:
Extension methodhandler: ) The notify signal is emitted on an object when one of its properties has its value set through
g_object_set_property()
,g_object_set()
, et al.Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with
G_PARAM_EXPLICIT_NOTIFY
, then any call tog_object_set_property()
results innotify
being emitted, even if the new value is the same as the old. If they did passG_PARAM_EXPLICIT_NOTIFY
, then this signal is emitted only when they explicitly callg_object_notify()
org_object_notify_by_pspec()
, and common practice is to do that only when the value has actually changed.This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the
g_signal_connect()
call, like this:(C Language Example):
g_signal_connect (text_view->buffer, "notify::paste-target-list", G_CALLBACK (gtk_text_view_target_list_notify), text_view)
It is important to note that you must use canonical parameter names as detail strings for the notify signal.
Note
This represents the underlyingnotify::hover-selection
signalDeclaration
Swift
@discardableResult @inlinable func onNotifyHoverSelection(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ pspec: ParamSpecRef) -> Void) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
pspec
the
GParamSpec
of the property which changed.handler
The signal handler to call Run the given callback whenever the
notifyHoverSelection
signal is emitted -
notifyHoverSelectionSignal
Extension methodTyped
notify::hover-selection
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var notifyHoverSelectionSignal: TreeViewSignalName { get }
-
onNotifyLevelIndentation(flags:
Extension methodhandler: ) The notify signal is emitted on an object when one of its properties has its value set through
g_object_set_property()
,g_object_set()
, et al.Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with
G_PARAM_EXPLICIT_NOTIFY
, then any call tog_object_set_property()
results innotify
being emitted, even if the new value is the same as the old. If they did passG_PARAM_EXPLICIT_NOTIFY
, then this signal is emitted only when they explicitly callg_object_notify()
org_object_notify_by_pspec()
, and common practice is to do that only when the value has actually changed.This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the
g_signal_connect()
call, like this:(C Language Example):
g_signal_connect (text_view->buffer, "notify::paste-target-list", G_CALLBACK (gtk_text_view_target_list_notify), text_view)
It is important to note that you must use canonical parameter names as detail strings for the notify signal.
Note
This represents the underlyingnotify::level-indentation
signalDeclaration
Swift
@discardableResult @inlinable func onNotifyLevelIndentation(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ pspec: ParamSpecRef) -> Void) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
pspec
the
GParamSpec
of the property which changed.handler
The signal handler to call Run the given callback whenever the
notifyLevelIndentation
signal is emitted -
notifyLevelIndentationSignal
Extension methodTyped
notify::level-indentation
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var notifyLevelIndentationSignal: TreeViewSignalName { get }
-
onNotifyModel(flags:
Extension methodhandler: ) The notify signal is emitted on an object when one of its properties has its value set through
g_object_set_property()
,g_object_set()
, et al.Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with
G_PARAM_EXPLICIT_NOTIFY
, then any call tog_object_set_property()
results innotify
being emitted, even if the new value is the same as the old. If they did passG_PARAM_EXPLICIT_NOTIFY
, then this signal is emitted only when they explicitly callg_object_notify()
org_object_notify_by_pspec()
, and common practice is to do that only when the value has actually changed.This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the
g_signal_connect()
call, like this:(C Language Example):
g_signal_connect (text_view->buffer, "notify::paste-target-list", G_CALLBACK (gtk_text_view_target_list_notify), text_view)
It is important to note that you must use canonical parameter names as detail strings for the notify signal.
Note
This represents the underlyingnotify::model
signalDeclaration
Swift
@discardableResult @inlinable func onNotifyModel(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ pspec: ParamSpecRef) -> Void) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
pspec
the
GParamSpec
of the property which changed.handler
The signal handler to call Run the given callback whenever the
notifyModel
signal is emitted -
notifyModelSignal
Extension methodTyped
notify::model
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var notifyModelSignal: TreeViewSignalName { get }
-
onNotifyReorderable(flags:
Extension methodhandler: ) The notify signal is emitted on an object when one of its properties has its value set through
g_object_set_property()
,g_object_set()
, et al.Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with
G_PARAM_EXPLICIT_NOTIFY
, then any call tog_object_set_property()
results innotify
being emitted, even if the new value is the same as the old. If they did passG_PARAM_EXPLICIT_NOTIFY
, then this signal is emitted only when they explicitly callg_object_notify()
org_object_notify_by_pspec()
, and common practice is to do that only when the value has actually changed.This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the
g_signal_connect()
call, like this:(C Language Example):
g_signal_connect (text_view->buffer, "notify::paste-target-list", G_CALLBACK (gtk_text_view_target_list_notify), text_view)
It is important to note that you must use canonical parameter names as detail strings for the notify signal.
Note
This represents the underlyingnotify::reorderable
signalDeclaration
Swift
@discardableResult @inlinable func onNotifyReorderable(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ pspec: ParamSpecRef) -> Void) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
pspec
the
GParamSpec
of the property which changed.handler
The signal handler to call Run the given callback whenever the
notifyReorderable
signal is emitted -
notifyReorderableSignal
Extension methodTyped
notify::reorderable
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var notifyReorderableSignal: TreeViewSignalName { get }
-
onNotifyRubberBanding(flags:
Extension methodhandler: ) The notify signal is emitted on an object when one of its properties has its value set through
g_object_set_property()
,g_object_set()
, et al.Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with
G_PARAM_EXPLICIT_NOTIFY
, then any call tog_object_set_property()
results innotify
being emitted, even if the new value is the same as the old. If they did passG_PARAM_EXPLICIT_NOTIFY
, then this signal is emitted only when they explicitly callg_object_notify()
org_object_notify_by_pspec()
, and common practice is to do that only when the value has actually changed.This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the
g_signal_connect()
call, like this:(C Language Example):
g_signal_connect (text_view->buffer, "notify::paste-target-list", G_CALLBACK (gtk_text_view_target_list_notify), text_view)
It is important to note that you must use canonical parameter names as detail strings for the notify signal.
Note
This represents the underlyingnotify::rubber-banding
signalDeclaration
Swift
@discardableResult @inlinable func onNotifyRubberBanding(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ pspec: ParamSpecRef) -> Void) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
pspec
the
GParamSpec
of the property which changed.handler
The signal handler to call Run the given callback whenever the
notifyRubberBanding
signal is emitted -
notifyRubberBandingSignal
Extension methodTyped
notify::rubber-banding
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var notifyRubberBandingSignal: TreeViewSignalName { get }
-
onNotifySearchColumn(flags:
Extension methodhandler: ) The notify signal is emitted on an object when one of its properties has its value set through
g_object_set_property()
,g_object_set()
, et al.Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with
G_PARAM_EXPLICIT_NOTIFY
, then any call tog_object_set_property()
results innotify
being emitted, even if the new value is the same as the old. If they did passG_PARAM_EXPLICIT_NOTIFY
, then this signal is emitted only when they explicitly callg_object_notify()
org_object_notify_by_pspec()
, and common practice is to do that only when the value has actually changed.This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the
g_signal_connect()
call, like this:(C Language Example):
g_signal_connect (text_view->buffer, "notify::paste-target-list", G_CALLBACK (gtk_text_view_target_list_notify), text_view)
It is important to note that you must use canonical parameter names as detail strings for the notify signal.
Note
This represents the underlyingnotify::search-column
signalDeclaration
Swift
@discardableResult @inlinable func onNotifySearchColumn(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ pspec: ParamSpecRef) -> Void) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
pspec
the
GParamSpec
of the property which changed.handler
The signal handler to call Run the given callback whenever the
notifySearchColumn
signal is emitted -
notifySearchColumnSignal
Extension methodTyped
notify::search-column
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var notifySearchColumnSignal: TreeViewSignalName { get }
-
onNotifyShowExpanders(flags:
Extension methodhandler: ) The notify signal is emitted on an object when one of its properties has its value set through
g_object_set_property()
,g_object_set()
, et al.Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with
G_PARAM_EXPLICIT_NOTIFY
, then any call tog_object_set_property()
results innotify
being emitted, even if the new value is the same as the old. If they did passG_PARAM_EXPLICIT_NOTIFY
, then this signal is emitted only when they explicitly callg_object_notify()
org_object_notify_by_pspec()
, and common practice is to do that only when the value has actually changed.This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the
g_signal_connect()
call, like this:(C Language Example):
g_signal_connect (text_view->buffer, "notify::paste-target-list", G_CALLBACK (gtk_text_view_target_list_notify), text_view)
It is important to note that you must use canonical parameter names as detail strings for the notify signal.
Note
This represents the underlyingnotify::show-expanders
signalDeclaration
Swift
@discardableResult @inlinable func onNotifyShowExpanders(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ pspec: ParamSpecRef) -> Void) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
pspec
the
GParamSpec
of the property which changed.handler
The signal handler to call Run the given callback whenever the
notifyShowExpanders
signal is emitted -
notifyShowExpandersSignal
Extension methodTyped
notify::show-expanders
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var notifyShowExpandersSignal: TreeViewSignalName { get }
-
onNotifyTooltipColumn(flags:
Extension methodhandler: ) The notify signal is emitted on an object when one of its properties has its value set through
g_object_set_property()
,g_object_set()
, et al.Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with
G_PARAM_EXPLICIT_NOTIFY
, then any call tog_object_set_property()
results innotify
being emitted, even if the new value is the same as the old. If they did passG_PARAM_EXPLICIT_NOTIFY
, then this signal is emitted only when they explicitly callg_object_notify()
org_object_notify_by_pspec()
, and common practice is to do that only when the value has actually changed.This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the
g_signal_connect()
call, like this:(C Language Example):
g_signal_connect (text_view->buffer, "notify::paste-target-list", G_CALLBACK (gtk_text_view_target_list_notify), text_view)
It is important to note that you must use canonical parameter names as detail strings for the notify signal.
Note
This represents the underlyingnotify::tooltip-column
signalDeclaration
Swift
@discardableResult @inlinable func onNotifyTooltipColumn(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TreeViewRef, _ pspec: ParamSpecRef) -> Void) -> Int
Parameters
flags
Flags
unownedSelf
Reference to instance of self
pspec
the
GParamSpec
of the property which changed.handler
The signal handler to call Run the given callback whenever the
notifyTooltipColumn
signal is emitted -
notifyTooltipColumnSignal
Extension methodTyped
notify::tooltip-column
signal for using theconnect(signal:)
methodsDeclaration
Swift
static var notifyTooltipColumnSignal: TreeViewSignalName { get }
-
append(column:
Extension method) Appends
column
to the list of columns. Iftree_view
has “fixed_height” mode enabled, thencolumn
must have its “sizing” property set to be GTK_TREE_VIEW_COLUMN_FIXED.Declaration
Swift
@inlinable func append<TreeViewColumnT>(column: TreeViewColumnT) -> Int where TreeViewColumnT : TreeViewColumnProtocol
-
collapseAll()
Extension methodRecursively collapses all visible, expanded nodes in
tree_view
.Declaration
Swift
@inlinable func collapseAll()
-
collapseRow(path:
Extension method) Collapses a row (hides its child rows, if they exist).
Declaration
Swift
@inlinable func collapseRow<TreePathT>(path: TreePathT) -> Bool where TreePathT : TreePathProtocol
-
columnsAutosize()
Extension methodResizes all columns to their optimal width. Only works after the treeview has been realized.
Declaration
Swift
@inlinable func columnsAutosize()
-
convertBinWindowToTreeCoords(bx:
Extension methodby: tx: ty: ) Converts bin_window coordinates to coordinates for the tree (the full scrollable area of the tree).
Declaration
Swift
@inlinable func convertBinWindowToTreeCoords(bx: Int, by: Int, tx: UnsafeMutablePointer<gint>!, ty: UnsafeMutablePointer<gint>!)
-
convertBinWindowToWidgetCoords(bx:
Extension methodby: wx: wy: ) Converts bin_window coordinates to widget relative coordinates.
Declaration
Swift
@inlinable func convertBinWindowToWidgetCoords(bx: Int, by: Int, wx: UnsafeMutablePointer<gint>!, wy: UnsafeMutablePointer<gint>!)
-
convertTreeToBinWindowCoords(tx:
Extension methodty: bx: by: ) Converts tree coordinates (coordinates in full scrollable area of the tree) to bin_window coordinates.
Declaration
Swift
@inlinable func convertTreeToBinWindowCoords(tx: Int, ty: Int, bx: UnsafeMutablePointer<gint>!, by: UnsafeMutablePointer<gint>!)
-
convertTreeToWidgetCoords(tx:
Extension methodty: wx: wy: ) Converts tree coordinates (coordinates in full scrollable area of the tree) to widget coordinates.
Declaration
Swift
@inlinable func convertTreeToWidgetCoords(tx: Int, ty: Int, wx: UnsafeMutablePointer<gint>!, wy: UnsafeMutablePointer<gint>!)
-
convertWidgetToBinWindowCoords(wx:
Extension methodwy: bx: by: ) Converts widget coordinates to coordinates for the bin_window.
Declaration
Swift
@inlinable func convertWidgetToBinWindowCoords(wx: Int, wy: Int, bx: UnsafeMutablePointer<gint>!, by: UnsafeMutablePointer<gint>!)
-
convertWidgetToTreeCoords(wx:
Extension methodwy: tx: ty: ) Converts widget coordinates to coordinates for the tree (the full scrollable area of the tree).
Declaration
Swift
@inlinable func convertWidgetToTreeCoords(wx: Int, wy: Int, tx: UnsafeMutablePointer<gint>!, ty: UnsafeMutablePointer<gint>!)
-
createRowDragIcon(path:
Extension method) Creates a
cairo_surface_t
representation of the row atpath
. This image is used for a drag icon.Declaration
Swift
@inlinable func createRowDragIcon<TreePathT>(path: TreePathT) -> Gdk.PaintableRef! where TreePathT : TreePathProtocol
-
enableModelDragDest(formats:
Extension methodactions: ) Turns
tree_view
into a drop destination for automatic DND. Calling this method setsGtkTreeView
:reorderable tofalse
.Declaration
Swift
@inlinable func enableModelDragDest<ContentFormatsT>(formats: ContentFormatsT, actions: Gdk.DragAction) where ContentFormatsT : ContentFormatsProtocol
-
enableModelDragSource(startButtonMask:
Extension methodformats: actions: ) Turns
tree_view
into a drag source for automatic DND. Calling this method setsGtkTreeView
:reorderable tofalse
.Declaration
Swift
@inlinable func enableModelDragSource<ContentFormatsT>(startButtonMask: Gdk.ModifierType, formats: ContentFormatsT, actions: Gdk.DragAction) where ContentFormatsT : ContentFormatsProtocol
-
expandAll()
Extension methodRecursively expands all nodes in the
tree_view
.Declaration
Swift
@inlinable func expandAll()
-
expandRow(path:
Extension methodopenAll: ) Opens the row so its children are visible.
Declaration
Swift
@inlinable func expandRow<TreePathT>(path: TreePathT, openAll: Bool) -> Bool where TreePathT : TreePathProtocol
-
expandTo(path:
Extension method) Expands the row at
path
. This will also expand all parent rows ofpath
as necessary.Declaration
Swift
@inlinable func expandTo<TreePathT>(path: TreePathT) where TreePathT : TreePathProtocol
-
getActivateOnSingleClick()
Extension methodGets the setting set by
gtk_tree_view_set_activate_on_single_click()
.Declaration
Swift
@inlinable func getActivateOnSingleClick() -> Bool
-
getBackgroundArea(path:
Extension methodcolumn: rect: ) Fills the bounding rectangle in bin_window coordinates for the cell at the row specified by
path
and the column specified bycolumn
. Ifpath
isnil
, or points to a node not found in the tree, they
andheight
fields of the rectangle will be filled with 0. Ifcolumn
isnil
, thex
andwidth
fields will be filled with 0. The returned rectangle is equivalent to thebackground_area
passed togtk_cell_renderer_render()
. These background areas tile to cover the entire bin window. Contrast with thecell_area
, returned bygtk_tree_view_get_cell_area()
, which returns only the cell itself, excluding surrounding borders and the tree expander area.Declaration
Swift
@inlinable func getBackgroundArea<RectangleT>(path: TreePathRef? = nil, column: TreeViewColumnRef? = nil, rect: RectangleT) where RectangleT : RectangleProtocol
-
getBackgroundArea(path:
Extension methodcolumn: rect: ) Fills the bounding rectangle in bin_window coordinates for the cell at the row specified by
path
and the column specified bycolumn
. Ifpath
isnil
, or points to a node not found in the tree, they
andheight
fields of the rectangle will be filled with 0. Ifcolumn
isnil
, thex
andwidth
fields will be filled with 0. The returned rectangle is equivalent to thebackground_area
passed togtk_cell_renderer_render()
. These background areas tile to cover the entire bin window. Contrast with thecell_area
, returned bygtk_tree_view_get_cell_area()
, which returns only the cell itself, excluding surrounding borders and the tree expander area.Declaration
Swift
@inlinable func getBackgroundArea<RectangleT, TreePathT, TreeViewColumnT>(path: TreePathT?, column: TreeViewColumnT?, rect: RectangleT) where RectangleT : RectangleProtocol, TreePathT : TreePathProtocol, TreeViewColumnT : TreeViewColumnProtocol
-
getCellArea(path:
Extension methodcolumn: rect: ) Fills the bounding rectangle in bin_window coordinates for the cell at the row specified by
path
and the column specified bycolumn
. Ifpath
isnil
, or points to a path not currently displayed, they
andheight
fields of the rectangle will be filled with 0. Ifcolumn
isnil
, thex
andwidth
fields will be filled with 0. The sum of all cell rects does not cover the entire tree; there are extra pixels in between rows, for example. The returned rectangle is equivalent to thecell_area
passed togtk_cell_renderer_render()
. This function is only valid iftree_view
is realized.Declaration
Swift
@inlinable func getCellArea<RectangleT>(path: TreePathRef? = nil, column: TreeViewColumnRef? = nil, rect: RectangleT) where RectangleT : RectangleProtocol
-
getCellArea(path:
Extension methodcolumn: rect: ) Fills the bounding rectangle in bin_window coordinates for the cell at the row specified by
path
and the column specified bycolumn
. Ifpath
isnil
, or points to a path not currently displayed, they
andheight
fields of the rectangle will be filled with 0. Ifcolumn
isnil
, thex
andwidth
fields will be filled with 0. The sum of all cell rects does not cover the entire tree; there are extra pixels in between rows, for example. The returned rectangle is equivalent to thecell_area
passed togtk_cell_renderer_render()
. This function is only valid iftree_view
is realized.Declaration
Swift
@inlinable func getCellArea<RectangleT, TreePathT, TreeViewColumnT>(path: TreePathT?, column: TreeViewColumnT?, rect: RectangleT) where RectangleT : RectangleProtocol, TreePathT : TreePathProtocol, TreeViewColumnT : TreeViewColumnProtocol
-
getColumn(n:
Extension method) Gets the
GtkTreeViewColumn
at the given position in thetree_view
.Declaration
Swift
@inlinable func getColumn(n: Int) -> TreeViewColumnRef!
-
getColumns()
Extension methodReturns a
GList
of all theGtkTreeViewColumn
s currently intree_view
. The returned list must be freed with g_list_free ().Declaration
Swift
@inlinable func getColumns() -> GLib.ListRef!
-
getCursor(path:
Extension methodfocusColumn: ) Fills in
path
andfocus_column
with the current path and focus column. If the cursor isn’t currently set, then *path
will benil
. If no column currently has focus, then *focus_column
will benil
.The returned
GtkTreePath
must be freed withgtk_tree_path_free()
when you are done with it.Declaration
Swift
@inlinable func getCursor(path: UnsafeMutablePointer<UnsafeMutablePointer<GtkTreePath>?>? = nil, focusColumn: UnsafeMutablePointer<UnsafeMutablePointer<GtkTreeViewColumn>?>? = nil)
-
getDestRowAtPos(dragX:
Extension methoddragY: path: pos: ) Determines the destination row for a given position.
drag_x
anddrag_y
are expected to be in widget coordinates. This function is only meaningful iftree_view
is realized. Therefore this function will always returnfalse
iftree_view
is not realized or does not have a model.Declaration
Swift
@inlinable func getDestRowAtPos(dragX: Int, dragY: Int, path: UnsafeMutablePointer<UnsafeMutablePointer<GtkTreePath>?>? = nil, pos: UnsafeMutablePointer<GtkTreeViewDropPosition>! = nil) -> Bool
-
getDragDestRow(path:
Extension methodpos: ) Gets information about the row that is highlighted for feedback.
Declaration
Swift
@inlinable func getDragDestRow(path: UnsafeMutablePointer<UnsafeMutablePointer<GtkTreePath>?>? = nil, pos: UnsafeMutablePointer<GtkTreeViewDropPosition>! = nil)
-
getEnableSearch()
Extension methodReturns whether or not the tree allows to start interactive searching by typing in text.
Declaration
Swift
@inlinable func getEnableSearch() -> Bool
-
getEnableTreeLines()
Extension methodReturns whether or not tree lines are drawn in
tree_view
.Declaration
Swift
@inlinable func getEnableTreeLines() -> Bool
-
getExpanderColumn()
Extension methodReturns the column that is the current expander column, or
nil
if none has been set. This column has the expander arrow drawn next to it.Declaration
Swift
@inlinable func getExpanderColumn() -> TreeViewColumnRef!
-
getFixedHeightMode()
Extension methodReturns whether fixed height mode is turned on for
tree_view
.Declaration
Swift
@inlinable func getFixedHeightMode() -> Bool
-
getGridLines()
Extension methodReturns which grid lines are enabled in
tree_view
.Declaration
Swift
@inlinable func getGridLines() -> GtkTreeViewGridLines
-
getHeadersClickable()
Extension methodReturns whether all header columns are clickable.
Declaration
Swift
@inlinable func getHeadersClickable() -> Bool
-
getHeadersVisible()
Extension methodReturns
true
if the headers on thetree_view
are visible.Declaration
Swift
@inlinable func getHeadersVisible() -> Bool
-
getHoverExpand()
Extension methodReturns whether hover expansion mode is turned on for
tree_view
.Declaration
Swift
@inlinable func getHoverExpand() -> Bool
-
getHoverSelection()
Extension methodReturns whether hover selection mode is turned on for
tree_view
.Declaration
Swift
@inlinable func getHoverSelection() -> Bool
-
getLevelIndentation()
Extension methodReturns the amount, in pixels, of extra indentation for child levels in
tree_view
.Declaration
Swift
@inlinable func getLevelIndentation() -> Int
-
getModel()
Extension methodReturns the model the
GtkTreeView
is based on. Returnsnil
if the model is unset.Declaration
Swift
@inlinable func getModel() -> TreeModelRef!
-
getNColumns()
Extension methodQueries the number of columns in the given
tree_view
.Declaration
Swift
@inlinable func getNColumns() -> Int
-
getPathAtPos(x:
Extension methody: path: column: cellX: cellY: ) Finds the path at the point (
x
,y
), relative to bin_window coordinates. That is,x
andy
are relative to an events coordinates. Widget-relative coordinates must be converted usinggtk_tree_view_convert_widget_to_bin_window_coords()
. It is primarily for things like popup menus. Ifpath
is non-nil
, then it will be filled with theGtkTreePath
at that point. This path should be freed withgtk_tree_path_free()
. Ifcolumn
is non-nil
, then it will be filled with the column at that point.cell_x
andcell_y
return the coordinates relative to the cell background (i.e. thebackground_area
passed togtk_cell_renderer_render()
). This function is only meaningful iftree_view
is realized. Therefore this function will always returnfalse
iftree_view
is not realized or does not have a model.For converting widget coordinates (eg. the ones you get from GtkWidget
query-tooltip
), please seegtk_tree_view_convert_widget_to_bin_window_coords()
.Declaration
Swift
@inlinable func getPathAtPos(x: Int, y: Int, path: UnsafeMutablePointer<UnsafeMutablePointer<GtkTreePath>?>? = nil, column: UnsafeMutablePointer<UnsafeMutablePointer<GtkTreeViewColumn>?>? = nil, cellX: UnsafeMutablePointer<gint>! = nil, cellY: UnsafeMutablePointer<gint>! = nil) -> Bool
-
getReorderable()
Extension methodRetrieves whether the user can reorder the tree via drag-and-drop. See
gtk_tree_view_set_reorderable()
.Declaration
Swift
@inlinable func getReorderable() -> Bool
-
getRowSeparatorFunc()
Extension methodReturns the current row separator function.
Declaration
Swift
@inlinable func getRowSeparatorFunc() -> GtkTreeViewRowSeparatorFunc!
-
getRubberBanding()
Extension methodReturns whether rubber banding is turned on for
tree_view
. If the selection mode isGTK_SELECTION_MULTIPLE
, rubber banding will allow the user to select multiple rows by dragging the mouse.Declaration
Swift
@inlinable func getRubberBanding() -> Bool
-
getSearchColumn()
Extension methodGets the column searched on by the interactive search code.
Declaration
Swift
@inlinable func getSearchColumn() -> Int
-
getSearchEntry()
Extension methodReturns the
GtkEntry
which is currently in use as interactive search entry fortree_view
. In case the built-in entry is being used,nil
will be returned.Declaration
Swift
@inlinable func getSearchEntry() -> EditableRef!
-
getSearchEqualFunc()
Extension methodReturns the compare function currently in use.
Declaration
Swift
@inlinable func getSearchEqualFunc() -> GtkTreeViewSearchEqualFunc!
-
getSelection()
Extension methodGets the
GtkTreeSelection
associated withtree_view
.Declaration
Swift
@inlinable func getSelection() -> TreeSelectionRef!
-
getShowExpanders()
Extension methodReturns whether or not expanders are drawn in
tree_view
.Declaration
Swift
@inlinable func getShowExpanders() -> Bool
-
getTooltipColumn()
Extension methodReturns the column of
tree_view
’s model which is being used for displaying tooltips ontree_view
’s rows.Declaration
Swift
@inlinable func getTooltipColumn() -> Int
-
getTooltipContext(x:
Extension methody: keyboardTip: model: path: iter: ) This function is supposed to be used in a
query-tooltip
signal handler forGtkTreeView
. Thex
,y
andkeyboard_tip
values which are received in the signal handler, should be passed to this function without modification.The return value indicates whether there is a tree view row at the given coordinates (
true
) or not (false
) for mouse tooltips. For keyboard tooltips the row returned will be the cursor row. Whentrue
, then any ofmodel
,path
anditer
which have been provided will be set to point to that row and the corresponding model.x
andy
will always be converted to be relative totree_view
’s bin_window ifkeyboard_tooltip
isfalse
.Declaration
Swift
@inlinable func getTooltipContext(x: Int, y: Int, keyboardTip: Bool, model: UnsafeMutablePointer<UnsafeMutablePointer<GtkTreeModel>?>? = nil, path: UnsafeMutablePointer<UnsafeMutablePointer<GtkTreePath>?>! = nil, iter: TreeIterRef? = nil) -> Bool
-
getTooltipContext(x:
Extension methody: keyboardTip: model: path: iter: ) This function is supposed to be used in a
query-tooltip
signal handler forGtkTreeView
. Thex
,y
andkeyboard_tip
values which are received in the signal handler, should be passed to this function without modification.The return value indicates whether there is a tree view row at the given coordinates (
true
) or not (false
) for mouse tooltips. For keyboard tooltips the row returned will be the cursor row. Whentrue
, then any ofmodel
,path
anditer
which have been provided will be set to point to that row and the corresponding model.x
andy
will always be converted to be relative totree_view
’s bin_window ifkeyboard_tooltip
isfalse
.Declaration
Swift
@inlinable func getTooltipContext<TreeIterT>(x: Int, y: Int, keyboardTip: Bool, model: UnsafeMutablePointer<UnsafeMutablePointer<GtkTreeModel>?>? = nil, path: UnsafeMutablePointer<UnsafeMutablePointer<GtkTreePath>?>! = nil, iter: TreeIterT?) -> Bool where TreeIterT : TreeIterProtocol
-
getVisibleRange(startPath:
Extension methodendPath: ) Sets
start_path
andend_path
to be the first and last visible path. Note that there may be invisible paths in between.The paths should be freed with
gtk_tree_path_free()
after use.Declaration
Swift
@inlinable func getVisibleRange(startPath: UnsafeMutablePointer<UnsafeMutablePointer<GtkTreePath>?>! = nil, endPath: UnsafeMutablePointer<UnsafeMutablePointer<GtkTreePath>?>! = nil) -> Bool
-
get(visibleRect:
Extension method) Fills
visible_rect
with the currently-visible region of the buffer, in tree coordinates. Convert to bin_window coordinates withgtk_tree_view_convert_tree_to_bin_window_coords()
. Tree coordinates start at 0,0 for row 0 of the tree, and cover the entire scrollable area of the tree.Declaration
Swift
@inlinable func get<RectangleT>(visibleRect: RectangleT) where RectangleT : RectangleProtocol
-
insert(column:
Extension methodposition: ) This inserts the
column
into thetree_view
atposition
. Ifposition
is -1, then the column is inserted at the end. Iftree_view
has “fixed_height” mode enabled, thencolumn
must have its “sizing” property set to be GTK_TREE_VIEW_COLUMN_FIXED.Declaration
Swift
@inlinable func insert<TreeViewColumnT>(column: TreeViewColumnT, position: Int) -> Int where TreeViewColumnT : TreeViewColumnProtocol
-
insertColumnWithDataFunc(position:
Extension methodtitle: cell: func: data: dnotify: ) Convenience function that inserts a new column into the
GtkTreeView
with the given cell renderer and aGtkTreeCellDataFunc
to set cell renderer attributes (normally using data from the model). See alsogtk_tree_view_column_set_cell_data_func()
,gtk_tree_view_column_pack_start()
. Iftree_view
has “fixed_height” mode enabled, then the new column will have its “sizing” property set to be GTK_TREE_VIEW_COLUMN_FIXED.Declaration
Swift
@inlinable func insertColumnWithDataFunc<CellRendererT>(position: Int, title: UnsafePointer<CChar>!, cell: CellRendererT, func: GtkTreeCellDataFunc?, data: gpointer! = nil, dnotify: GDestroyNotify?) -> Int where CellRendererT : CellRendererProtocol
-
isBlankAtPos(x:
Extension methody: path: column: cellX: cellY: ) Determine whether the point (
x
,y
) intree_view
is blank, that is no cell content nor an expander arrow is drawn at the location. If so, the location can be considered as the background. You might wish to take special action on clicks on the background, such as clearing a current selection, having a custom context menu or starting rubber banding.The
x
andy
coordinate that are provided must be relative to bin_window coordinates. Widget-relative coordinates must be converted usinggtk_tree_view_convert_widget_to_bin_window_coords()
.For converting widget coordinates (eg. the ones you get from GtkWidget
query-tooltip
), please seegtk_tree_view_convert_widget_to_bin_window_coords()
.The
path
,column
,cell_x
andcell_y
arguments will be filled in likewise as forgtk_tree_view_get_path_at_pos()
. Please seegtk_tree_view_get_path_at_pos()
for more information.Declaration
Swift
@inlinable func isBlankAtPos(x: Int, y: Int, path: UnsafeMutablePointer<UnsafeMutablePointer<GtkTreePath>?>? = nil, column: UnsafeMutablePointer<UnsafeMutablePointer<GtkTreeViewColumn>?>? = nil, cellX: UnsafeMutablePointer<gint>! = nil, cellY: UnsafeMutablePointer<gint>! = nil) -> Bool
-
mapExpandedRows(func:
Extension methoddata: ) Calls
func
on all expanded rows.Declaration
Swift
@inlinable func mapExpandedRows(func: GtkTreeViewMappingFunc?, data: gpointer! = nil)
-
moveColumnAfter(column:
Extension methodbaseColumn: ) Moves
column
to be after tobase_column
. Ifbase_column
isnil
, thencolumn
is placed in the first position.Declaration
Swift
@inlinable func moveColumnAfter<TreeViewColumnT>(column: TreeViewColumnT, baseColumn: TreeViewColumnT?) where TreeViewColumnT : TreeViewColumnProtocol
-
remove(column:
Extension method) Removes
column
fromtree_view
.Declaration
Swift
@inlinable func remove<TreeViewColumnT>(column: TreeViewColumnT) -> Int where TreeViewColumnT : TreeViewColumnProtocol
-
rowActivated(path:
Extension methodcolumn: ) Activates the cell determined by
path
andcolumn
.Declaration
Swift
@inlinable func rowActivated<TreePathT>(path: TreePathT, column: TreeViewColumnRef? = nil) where TreePathT : TreePathProtocol
-
rowActivated(path:
Extension methodcolumn: ) Activates the cell determined by
path
andcolumn
.Declaration
Swift
@inlinable func rowActivated<TreePathT, TreeViewColumnT>(path: TreePathT, column: TreeViewColumnT?) where TreePathT : TreePathProtocol, TreeViewColumnT : TreeViewColumnProtocol
-
rowExpanded(path:
Extension method) Returns
true
if the node pointed to bypath
is expanded intree_view
.Declaration
Swift
@inlinable func rowExpanded<TreePathT>(path: TreePathT) -> Bool where TreePathT : TreePathProtocol
-
scrollToCell(path:
Extension methodcolumn: useAlign: rowAlign: colAlign: ) Moves the alignments of
tree_view
to the position specified bycolumn
andpath
. Ifcolumn
isnil
, then no horizontal scrolling occurs. Likewise, ifpath
isnil
no vertical scrolling occurs. At a minimum, one ofcolumn
orpath
need to be non-nil
.row_align
determines where the row is placed, andcol_align
determines wherecolumn
is placed. Both are expected to be between 0.0 and 1.0. 0.0 means left/top alignment, 1.0 means right/bottom alignment, 0.5 means center.If
use_align
isfalse
, then the alignment arguments are ignored, and the tree does the minimum amount of work to scroll the cell onto the screen. This means that the cell will be scrolled to the edge closest to its current position. If the cell is currently visible on the screen, nothing is done.This function only works if the model is set, and
path
is a valid row on the model. If the model changes before thetree_view
is realized, the centered path will be modified to reflect this change.Declaration
Swift
@inlinable func scrollToCell(path: TreePathRef? = nil, column: TreeViewColumnRef? = nil, useAlign: Bool, rowAlign: CFloat, colAlign: CFloat)
-
scrollToCell(path:
Extension methodcolumn: useAlign: rowAlign: colAlign: ) Moves the alignments of
tree_view
to the position specified bycolumn
andpath
. Ifcolumn
isnil
, then no horizontal scrolling occurs. Likewise, ifpath
isnil
no vertical scrolling occurs. At a minimum, one ofcolumn
orpath
need to be non-nil
.row_align
determines where the row is placed, andcol_align
determines wherecolumn
is placed. Both are expected to be between 0.0 and 1.0. 0.0 means left/top alignment, 1.0 means right/bottom alignment, 0.5 means center.If
use_align
isfalse
, then the alignment arguments are ignored, and the tree does the minimum amount of work to scroll the cell onto the screen. This means that the cell will be scrolled to the edge closest to its current position. If the cell is currently visible on the screen, nothing is done.This function only works if the model is set, and
path
is a valid row on the model. If the model changes before thetree_view
is realized, the centered path will be modified to reflect this change.Declaration
Swift
@inlinable func scrollToCell<TreePathT, TreeViewColumnT>(path: TreePathT?, column: TreeViewColumnT?, useAlign: Bool, rowAlign: CFloat, colAlign: CFloat) where TreePathT : TreePathProtocol, TreeViewColumnT : TreeViewColumnProtocol
-
scrollToPoint(treeX:
Extension methodtreeY: ) Scrolls the tree view such that the top-left corner of the visible area is
tree_x
,tree_y
, wheretree_x
andtree_y
are specified in tree coordinates. Thetree_view
must be realized before this function is called. If it isn’t, you probably want to be usinggtk_tree_view_scroll_to_cell()
.If either
tree_x
ortree_y
are -1, then that direction isn’t scrolled.Declaration
Swift
@inlinable func scrollToPoint(treeX: Int, treeY: Int)
-
setActivateOnSingleClick(single:
Extension method) Cause the
GtkTreeView
row-activated
signal to be emitted on a single click instead of a double click.Declaration
Swift
@inlinable func setActivateOnSingleClick(single: Bool)
-
setColumnDragFunction(func:
Extension methoduserData: destroy: ) Sets a user function for determining where a column may be dropped when dragged. This function is called on every column pair in turn at the beginning of a column drag to determine where a drop can take place. The arguments passed to
func
are: thetree_view
, theGtkTreeViewColumn
being dragged, the twoGtkTreeViewColumn
s determining the drop spot, anduser_data
. If either of theGtkTreeViewColumn
arguments for the drop spot arenil
, then they indicate an edge. Iffunc
is set to benil
, thentree_view
reverts to the default behavior of allowing all columns to be dropped everywhere.Declaration
Swift
@inlinable func setColumnDragFunction(func: GtkTreeViewColumnDropFunc? = nil, userData: gpointer! = nil, destroy: GDestroyNotify? = nil)
-
setCursor(path:
Extension methodfocusColumn: startEditing: ) Sets the current keyboard focus to be at
path
, and selects it. This is useful when you want to focus the user’s attention on a particular row. Iffocus_column
is notnil
, then focus is given to the column specified by it. Additionally, iffocus_column
is specified, andstart_editing
istrue
, then editing should be started in the specified cell. This function is often followed bygtk_widget_grab_focus
(tree_view
) in order to give keyboard focus to the widget. Please note that editing can only happen when the widget is realized.If
path
is invalid formodel
, the current cursor (if any) will be unset and the function will return without failing.Declaration
Swift
@inlinable func setCursor<TreePathT>(path: TreePathT, focusColumn: TreeViewColumnRef? = nil, startEditing: Bool) where TreePathT : TreePathProtocol
-
setCursor(path:
Extension methodfocusColumn: startEditing: ) Sets the current keyboard focus to be at
path
, and selects it. This is useful when you want to focus the user’s attention on a particular row. Iffocus_column
is notnil
, then focus is given to the column specified by it. Additionally, iffocus_column
is specified, andstart_editing
istrue
, then editing should be started in the specified cell. This function is often followed bygtk_widget_grab_focus
(tree_view
) in order to give keyboard focus to the widget. Please note that editing can only happen when the widget is realized.If
path
is invalid formodel
, the current cursor (if any) will be unset and the function will return without failing.Declaration
Swift
@inlinable func setCursor<TreePathT, TreeViewColumnT>(path: TreePathT, focusColumn: TreeViewColumnT?, startEditing: Bool) where TreePathT : TreePathProtocol, TreeViewColumnT : TreeViewColumnProtocol
-
setCursorOnCell(path:
Extension methodfocusColumn: focusCell: startEditing: ) Sets the current keyboard focus to be at
path
, and selects it. This is useful when you want to focus the user’s attention on a particular row. Iffocus_column
is notnil
, then focus is given to the column specified by it. Iffocus_column
andfocus_cell
are notnil
, andfocus_column
contains 2 or more editable or activatable cells, then focus is given to the cell specified byfocus_cell
. Additionally, iffocus_column
is specified, andstart_editing
istrue
, then editing should be started in the specified cell. This function is often followed bygtk_widget_grab_focus
(tree_view
) in order to give keyboard focus to the widget. Please note that editing can only happen when the widget is realized.If
path
is invalid formodel
, the current cursor (if any) will be unset and the function will return without failing.Declaration
Swift
@inlinable func setCursorOnCell<TreePathT>(path: TreePathT, focusColumn: TreeViewColumnRef? = nil, focusCell: CellRendererRef? = nil, startEditing: Bool) where TreePathT : TreePathProtocol
-
setCursorOnCell(path:
Extension methodfocusColumn: focusCell: startEditing: ) Sets the current keyboard focus to be at
path
, and selects it. This is useful when you want to focus the user’s attention on a particular row. Iffocus_column
is notnil
, then focus is given to the column specified by it. Iffocus_column
andfocus_cell
are notnil
, andfocus_column
contains 2 or more editable or activatable cells, then focus is given to the cell specified byfocus_cell
. Additionally, iffocus_column
is specified, andstart_editing
istrue
, then editing should be started in the specified cell. This function is often followed bygtk_widget_grab_focus
(tree_view
) in order to give keyboard focus to the widget. Please note that editing can only happen when the widget is realized.If
path
is invalid formodel
, the current cursor (if any) will be unset and the function will return without failing.Declaration
Swift
@inlinable func setCursorOnCell<CellRendererT, TreePathT, TreeViewColumnT>(path: TreePathT, focusColumn: TreeViewColumnT?, focusCell: CellRendererT?, startEditing: Bool) where CellRendererT : CellRendererProtocol, TreePathT : TreePathProtocol, TreeViewColumnT : TreeViewColumnProtocol
-
setDragDestRow(path:
Extension methodpos: ) Sets the row that is highlighted for feedback. If
path
isnil
, an existing highlight is removed.Declaration
Swift
@inlinable func setDragDestRow(path: TreePathRef? = nil, pos: GtkTreeViewDropPosition)
-
setDragDestRow(path:
Extension methodpos: ) Sets the row that is highlighted for feedback. If
path
isnil
, an existing highlight is removed.Declaration
Swift
@inlinable func setDragDestRow<TreePathT>(path: TreePathT?, pos: GtkTreeViewDropPosition) where TreePathT : TreePathProtocol
-
set(enableSearch:
Extension method) If
enable_search
is set, then the user can type in text to search through the tree interactively (this is sometimes called “typeahead find”).Note that even if this is
false
, the user can still initiate a search using the “start-interactive-search” key binding.Declaration
Swift
@inlinable func set(enableSearch: Bool)
-
setEnableTreeLines(enabled:
Extension method) Sets whether to draw lines interconnecting the expanders in
tree_view
. This does not have any visible effects for lists.Declaration
Swift
@inlinable func setEnableTreeLines(enabled: Bool)
-
setExpander(column:
Extension method) Sets the column to draw the expander arrow at. It must be in
tree_view
. Ifcolumn
isnil
, then the expander arrow is always at the first visible column.If you do not want expander arrow to appear in your tree, set the expander column to a hidden column.
Declaration
Swift
@inlinable func setExpander(column: TreeViewColumnRef? = nil)
-
setExpander(column:
Extension method) Sets the column to draw the expander arrow at. It must be in
tree_view
. Ifcolumn
isnil
, then the expander arrow is always at the first visible column.If you do not want expander arrow to appear in your tree, set the expander column to a hidden column.
Declaration
Swift
@inlinable func setExpander<TreeViewColumnT>(column: TreeViewColumnT?) where TreeViewColumnT : TreeViewColumnProtocol
-
setFixedHeightMode(enable:
Extension method) Enables or disables the fixed height mode of
tree_view
. Fixed height mode speeds upGtkTreeView
by assuming that all rows have the same height. Only enable this option if all rows are the same height and all columns are of typeGTK_TREE_VIEW_COLUMN_FIXED
.Declaration
Swift
@inlinable func setFixedHeightMode(enable: Bool)
-
set(gridLines:
Extension method) Sets which grid lines to draw in
tree_view
.Declaration
Swift
@inlinable func set(gridLines: GtkTreeViewGridLines)
-
setHeadersClickable(setting:
Extension method) Allow the column title buttons to be clicked.
Declaration
Swift
@inlinable func setHeadersClickable(setting: Bool)
-
set(headersVisible:
Extension method) Sets the visibility state of the headers.
Declaration
Swift
@inlinable func set(headersVisible: Bool)
-
setHover(expand:
Extension method) Enables or disables the hover expansion mode of
tree_view
. Hover expansion makes rows expand or collapse if the pointer moves over them.Declaration
Swift
@inlinable func setHover(expand: Bool)
-
setHoverSelection(hover:
Extension method) Enables or disables the hover selection mode of
tree_view
. Hover selection makes the selected row follow the pointer. Currently, this works only for the selection modesGTK_SELECTION_SINGLE
andGTK_SELECTION_BROWSE
.Declaration
Swift
@inlinable func setHoverSelection(hover: Bool)
-
setLevel(indentation:
Extension method) Sets the amount of extra indentation for child levels to use in
tree_view
in addition to the default indentation. The value should be specified in pixels, a value of 0 disables this feature and in this case only the default indentation will be used. This does not have any visible effects for lists.Declaration
Swift
@inlinable func setLevel(indentation: Int)
-
set(model:
Extension method) Sets the model for a
GtkTreeView
. If thetree_view
already has a model set, it will remove it before setting the new model. Ifmodel
isnil
, then it will unset the old model.Declaration
Swift
@inlinable func set(model: TreeModelRef? = nil)
-
set(model:
Extension method) Sets the model for a
GtkTreeView
. If thetree_view
already has a model set, it will remove it before setting the new model. Ifmodel
isnil
, then it will unset the old model.Declaration
Swift
@inlinable func set<TreeModelT>(model: TreeModelT?) where TreeModelT : TreeModelProtocol
-
set(reorderable:
Extension method) This function is a convenience function to allow you to reorder models that support the
GtkTreeDragSourceIface
and theGtkTreeDragDestIface
. BothGtkTreeStore
andGtkListStore
support these. Ifreorderable
istrue
, then the user can reorder the model by dragging and dropping rows. The developer can listen to these changes by connecting to the model’sGtkTreeModel
row-insertedand `GtkTreeModel`row-deleted
signals. The reordering is implemented by setting up the tree view as a drag source and destination. Therefore, drag and drop can not be used in a reorderable view for any other purpose.This function does not give you any degree of control over the order – any reordering is allowed. If more control is needed, you should probably handle drag and drop manually.
Declaration
Swift
@inlinable func set(reorderable: Bool)
-
setRowSeparatorFunc(func:
Extension methoddata: destroy: ) Sets the row separator function, which is used to determine whether a row should be drawn as a separator. If the row separator function is
nil
, no separators are drawn. This is the default value.Declaration
Swift
@inlinable func setRowSeparatorFunc(func: GtkTreeViewRowSeparatorFunc? = nil, data: gpointer! = nil, destroy: GDestroyNotify? = nil)
-
setRubberBanding(enable:
Extension method) Enables or disables rubber banding in
tree_view
. If the selection mode isGTK_SELECTION_MULTIPLE
, rubber banding will allow the user to select multiple rows by dragging the mouse.Declaration
Swift
@inlinable func setRubberBanding(enable: Bool)
-
setSearch(column:
Extension method) Sets
column
as the column where the interactive search code should search in for the current model.If the search column is set, users can use the “start-interactive-search” key binding to bring up search popup. The enable-search property controls whether simply typing text will also start an interactive search.
Note that
column
refers to a column of the current model. The search column is reset to -1 when the model is changed.Declaration
Swift
@inlinable func setSearch(column: Int)
-
setSearch(entry:
Extension method) Sets the entry which the interactive search code will use for this
tree_view
. This is useful when you want to provide a search entry in our interface at all time at a fixed position. Passingnil
forentry
will make the interactive search code use the built-in popup entry again.Declaration
Swift
@inlinable func setSearch(entry: EditableRef? = nil)
-
setSearch(entry:
Extension method) Sets the entry which the interactive search code will use for this
tree_view
. This is useful when you want to provide a search entry in our interface at all time at a fixed position. Passingnil
forentry
will make the interactive search code use the built-in popup entry again.Declaration
Swift
@inlinable func setSearch<EditableT>(entry: EditableT?) where EditableT : EditableProtocol
-
set(searchEqualFunc:
Extension methodsearchUserData: searchDestroy: ) Sets the compare function for the interactive search capabilities; note that somewhat like
strcmp()
returning 0 for equalityGtkTreeView
SearchEqualFunc returnsfalse
on matches.Declaration
Swift
@inlinable func set(searchEqualFunc: GtkTreeViewSearchEqualFunc?, searchUserData: gpointer! = nil, searchDestroy: GDestroyNotify? = nil)
-
setShowExpanders(enabled:
Extension method) Sets whether to draw and enable expanders and indent child rows in
tree_view
. When disabled there will be no expanders visible in trees and there will be no way to expand and collapse rows by default. Also note that hiding the expanders will disable the default indentation. You can set a custom indentation in this case usinggtk_tree_view_set_level_indentation()
. This does not have any visible effects for lists.Declaration
Swift
@inlinable func setShowExpanders(enabled: Bool)
-
setTooltipCell(tooltip:
Extension methodpath: column: cell: ) Sets the tip area of
tooltip
to the areapath
,column
andcell
have in common. For example ifpath
isnil
andcolumn
is set, the tip area will be set to the full area covered bycolumn
. See alsogtk_tooltip_set_tip_area()
.Note that if
path
is not specified andcell
is set and part of a column containing the expander, the tooltip might not show and hide at the correct position. In such casespath
must be set to the current node under the mouse cursor for this function to operate correctly.See also
gtk_tree_view_set_tooltip_column()
for a simpler alternative.Declaration
Swift
@inlinable func setTooltipCell<TooltipT>(tooltip: TooltipT, path: TreePathRef? = nil, column: TreeViewColumnRef? = nil, cell: CellRendererRef? = nil) where TooltipT : TooltipProtocol
-
setTooltipCell(tooltip:
Extension methodpath: column: cell: ) Sets the tip area of
tooltip
to the areapath
,column
andcell
have in common. For example ifpath
isnil
andcolumn
is set, the tip area will be set to the full area covered bycolumn
. See alsogtk_tooltip_set_tip_area()
.Note that if
path
is not specified andcell
is set and part of a column containing the expander, the tooltip might not show and hide at the correct position. In such casespath
must be set to the current node under the mouse cursor for this function to operate correctly.See also
gtk_tree_view_set_tooltip_column()
for a simpler alternative.Declaration
Swift
@inlinable func setTooltipCell<CellRendererT, TooltipT, TreePathT, TreeViewColumnT>(tooltip: TooltipT, path: TreePathT?, column: TreeViewColumnT?, cell: CellRendererT?) where CellRendererT : CellRendererProtocol, TooltipT : TooltipProtocol, TreePathT : TreePathProtocol, TreeViewColumnT : TreeViewColumnProtocol
-
setTooltip(column:
Extension method) If you only plan to have simple (text-only) tooltips on full rows, you can use this function to have
GtkTreeView
handle these automatically for you.column
should be set to the column intree_view
’s model containing the tooltip texts, or -1 to disable this feature.When enabled,
GtkWidget:has-tooltip
will be set totrue
andtree_view
will connect aGtkWidget
query-tooltip`` signal handler.Note that the signal handler sets the text with
gtk_tooltip_set_markup()
, so &, <, etc have to be escaped in the text.Declaration
Swift
@inlinable func setTooltip(column: Int)
-
setTooltipRow(tooltip:
Extension methodpath: ) Sets the tip area of
tooltip
to be the area covered by the row atpath
. See alsogtk_tree_view_set_tooltip_column()
for a simpler alternative. See alsogtk_tooltip_set_tip_area()
.Declaration
Swift
@inlinable func setTooltipRow<TooltipT, TreePathT>(tooltip: TooltipT, path: TreePathT) where TooltipT : TooltipProtocol, TreePathT : TreePathProtocol
-
unsetRowsDragDest()
Extension methodUndoes the effect of
gtk_tree_view_enable_model_drag_dest()
. Calling this method setsGtkTreeView
:reorderable tofalse
.Declaration
Swift
@inlinable func unsetRowsDragDest()
-
unsetRowsDragSource()
Extension methodUndoes the effect of
gtk_tree_view_enable_model_drag_source()
. Calling this method setsGtkTreeView
:reorderable tofalse
.Declaration
Swift
@inlinable func unsetRowsDragSource()
-
activateOnSingleClick
Extension methodGets the setting set by
gtk_tree_view_set_activate_on_single_click()
.Declaration
Swift
@inlinable var activateOnSingleClick: Bool { get nonmutating set }
-
columns
Extension methodReturns a
GList
of all theGtkTreeViewColumn
s currently intree_view
. The returned list must be freed with g_list_free ().Declaration
Swift
@inlinable var columns: GLib.ListRef! { get }
-
enableSearch
Extension methodReturns whether or not the tree allows to start interactive searching by typing in text.
Declaration
Swift
@inlinable var enableSearch: Bool { get nonmutating set }
-
enableTreeLines
Extension methodReturns whether or not tree lines are drawn in
tree_view
.Declaration
Swift
@inlinable var enableTreeLines: Bool { get nonmutating set }
-
expanderColumn
Extension methodReturns the column that is the current expander column, or
nil
if none has been set. This column has the expander arrow drawn next to it.Declaration
Swift
@inlinable var expanderColumn: TreeViewColumnRef! { get nonmutating set }
-
fixedHeightMode
Extension methodReturns whether fixed height mode is turned on for
tree_view
.Declaration
Swift
@inlinable var fixedHeightMode: Bool { get nonmutating set }
-
gridLines
Extension methodReturns which grid lines are enabled in
tree_view
.Declaration
Swift
@inlinable var gridLines: GtkTreeViewGridLines { get nonmutating set }
-
headersClickable
Extension methodReturns whether all header columns are clickable.
Declaration
Swift
@inlinable var headersClickable: Bool { get nonmutating set }
-
headersVisible
Extension methodReturns
true
if the headers on thetree_view
are visible.Declaration
Swift
@inlinable var headersVisible: Bool { get nonmutating set }
-
hoverExpand
Extension methodReturns whether hover expansion mode is turned on for
tree_view
.Declaration
Swift
@inlinable var hoverExpand: Bool { get nonmutating set }
-
hoverSelection
Extension methodReturns whether hover selection mode is turned on for
tree_view
.Declaration
Swift
@inlinable var hoverSelection: Bool { get nonmutating set }
-
isRubberBandingActive
Extension methodReturns whether a rubber banding operation is currently being done in
tree_view
.Declaration
Swift
@inlinable var isRubberBandingActive: Bool { get }
-
levelIndentation
Extension methodReturns the amount, in pixels, of extra indentation for child levels in
tree_view
.Declaration
Swift
@inlinable var levelIndentation: Int { get nonmutating set }
-
model
Extension methodUndocumented
Declaration
Swift
@inlinable var model: TreeModelRef! { get nonmutating set }
-
nColumns
Extension methodQueries the number of columns in the given
tree_view
.Declaration
Swift
@inlinable var nColumns: Int { get }
-
reorderable
Extension methodUndocumented
Declaration
Swift
@inlinable var reorderable: Bool { get nonmutating set }
-
rowSeparatorFunc
Extension methodReturns the current row separator function.
Declaration
Swift
@inlinable var rowSeparatorFunc: GtkTreeViewRowSeparatorFunc! { get }
-
rubberBanding
Extension methodReturns whether rubber banding is turned on for
tree_view
. If the selection mode isGTK_SELECTION_MULTIPLE
, rubber banding will allow the user to select multiple rows by dragging the mouse.Declaration
Swift
@inlinable var rubberBanding: Bool { get nonmutating set }
-
searchColumn
Extension methodGets the column searched on by the interactive search code.
Declaration
Swift
@inlinable var searchColumn: Int { get nonmutating set }
-
searchEntry
Extension methodReturns the
GtkEntry
which is currently in use as interactive search entry fortree_view
. In case the built-in entry is being used,nil
will be returned.Declaration
Swift
@inlinable var searchEntry: EditableRef! { get nonmutating set }
-
searchEqualFunc
Extension methodReturns the compare function currently in use.
Declaration
Swift
@inlinable var searchEqualFunc: GtkTreeViewSearchEqualFunc! { get }
-
selection
Extension methodGets the
GtkTreeSelection
associated withtree_view
.Declaration
Swift
@inlinable var selection: TreeSelectionRef! { get }
-
showExpanders
Extension methodReturns whether or not expanders are drawn in
tree_view
.Declaration
Swift
@inlinable var showExpanders: Bool { get nonmutating set }
-
tooltipColumn
Extension methodReturns the column of
tree_view
’s model which is being used for displaying tooltips ontree_view
’s rows.Declaration
Swift
@inlinable var tooltipColumn: Int { get nonmutating set }
-
parentInstance
Extension methodUndocumented
Declaration
Swift
@inlinable var parentInstance: GtkWidget { get }