Class TreeListModel
- Namespace
- Gtk
- Assembly
- Gtk-4.0.dll
public class TreeListModel : Object, ListModel, NativeObject, IDisposable, GTypeProvider, InstanceFactory
- Inheritance
-
TreeListModel
- Implements
- Inherited Members
Constructors
TreeListModel(params ConstructArgument[])
[Obsolete("Regular C# constructors on native classes will be removed in a future version. Please see the linked documentation for more details. It contains scenarios and possible solutions to prepare for the upcoming changes.", DiagnosticId = "GirCore1007", UrlFormat = "https://gircore.github.io/docs/integration/diagnostic/1007.html")]
public TreeListModel(params ConstructArgument[] constructArguments)
Parameters
constructArgumentsConstructArgument[]
TreeListModel(CreationData)
[Obsolete("This constructor is a workaround to keep legacy APIs alive. Do not use it.")]
protected TreeListModel(CreationData data)
Parameters
dataCreationData
TreeListModel(TreeListModelHandle)
protected TreeListModel(TreeListModelHandle handle)
Parameters
handleTreeListModelHandle
Fields
AutoexpandPropertyDefinition
public static readonly Property<bool, TreeListModel> AutoexpandPropertyDefinition
Field Value
ItemsChangedSignal
Signal Descriptor for OnItemsChanged.
public static readonly Signal<ListModel, ListModel.ItemsChangedSignalArgs> ItemsChangedSignal
Field Value
ModelPropertyDefinition
public static readonly Property<ListModel, TreeListModel> ModelPropertyDefinition
Field Value
NItemsPropertyDefinition
public static readonly Property<uint, TreeListModel> NItemsPropertyDefinition
Field Value
PassthroughPropertyDefinition
public static readonly Property<bool, TreeListModel> PassthroughPropertyDefinition
Field Value
Properties
Autoexpand
public bool Autoexpand { get; set; }
Property Value
Model
public ListModel Model { get; }
Property Value
NItems
public uint NItems { get; }
Property Value
Passthrough
public bool Passthrough { get; }
Property Value
Methods
GetAutoexpand()
public bool GetAutoexpand()
Returns
GetChildRow(uint)
public TreeListRow? GetChildRow(uint position)
Parameters
positionuint
Returns
GetGType()
public static Type GetGType()
Returns
GetItem(uint)
[Version("2.44")]
public nint GetItem(uint position)
Parameters
positionuint
Returns
GetItemType()
[Version("2.44")]
public Type GetItemType()
Returns
GetModel()
public ListModel GetModel()
Returns
GetNItems()
[Version("2.44")]
public uint GetNItems()
Returns
GetObject(uint)
[Version("2.44")]
public Object? GetObject(uint position)
Parameters
positionuint
Returns
GetPassthrough()
public bool GetPassthrough()
Returns
GetRow(uint)
public TreeListRow? GetRow(uint position)
Parameters
positionuint
Returns
ItemsChanged(uint, uint, uint)
[Version("2.44")]
public void ItemsChanged(uint position, uint removed, uint added)
Parameters
New(ListModel, bool, bool, TreeListModelCreateModelFunc)
public static TreeListModel New(ListModel root, bool passthrough, bool autoexpand, TreeListModelCreateModelFunc createFunc)
Parameters
rootListModelpassthroughboolautoexpandboolcreateFuncTreeListModelCreateModelFunc
Returns
NewFromPointer(nint, bool)
Creates a new managed TreeListModel instance for a given pointer.
public static TreeListModel NewFromPointer(nint ptr, bool ownsHandle)
Parameters
Returns
NewWithProperties(ConstructArgument[])
Creates a new TreeListModel and sets the properties specified by the construct arguments.
public static TreeListModel NewWithProperties(ConstructArgument[] constructArguments)
Parameters
constructArgumentsConstructArgument[]The properties to set.
Returns
SetAutoexpand(bool)
public void SetAutoexpand(bool autoexpand)
Parameters
autoexpandbool
Events
OnItemsChanged
public event SignalHandler<ListModel, ListModel.ItemsChangedSignalArgs> OnItemsChanged