PageRenderTime 18ms CodeModel.GetById 11ms app.highlight 6ms RepoModel.GetById 0ms app.codeStats 0ms

/packages/gtk2/src/gtk+/gtk/gtktreesortable.inc

https://github.com/slibre/freepascal
Pascal | 82 lines | 46 code | 20 blank | 16 comment | 0 complexity | c335dd16978fdfa60881c36a1de3d1e6 MD5 | raw file
Possible License(s): LGPL-2.0, LGPL-2.1, LGPL-3.0
 1// included by gtk2.pas
 2
 3{$IFDEF read_forward_definitions}
 4{$ENDIF read_forward_definitions}
 5
 6//------------------------------------------------------------------------------
 7
 8{$IFDEF read_interface_types}
 9   // internal type
10   PGtkTreeSortable = pointer;
11
12   TGtkTreeIterCompareFunc = function (model:PGtkTreeModel; a:PGtkTreeIter; b:PGtkTreeIter; user_data:gpointer):gint; cdecl;
13{ signals  }
14{ virtual table  }
15   PGtkTreeSortableIface = ^TGtkTreeSortableIface;
16   TGtkTreeSortableIface = record
17        g_iface : TGTypeInterface;
18        sort_column_changed : procedure (sortable:PGtkTreeSortable); cdecl;
19        get_sort_column_id : function (sortable:PGtkTreeSortable; sort_column_id:Pgint; order:PGtkSortType):gboolean; cdecl;
20        set_sort_column_id : procedure (sortable:PGtkTreeSortable; sort_column_id:gint; order:TGtkSortType); cdecl;
21        set_sort_func : procedure (sortable:PGtkTreeSortable; sort_column_id:gint; func:TGtkTreeIterCompareFunc; data:gpointer; destroy:TGtkDestroyNotify); cdecl;
22        set_default_sort_func : procedure (sortable:PGtkTreeSortable; func:TGtkTreeIterCompareFunc; data:gpointer; destroy:TGtkDestroyNotify); cdecl;
23        has_default_sort_func : function (sortable:PGtkTreeSortable):gboolean; cdecl;
24     end;
25
26{$ENDIF read_interface_types}
27
28//------------------------------------------------------------------------------
29
30{$IFDEF read_interface_rest}
31const
32  GTK_TREE_SORTABLE_DEFAULT_SORT_COLUMN_ID = -(1);
33
34
35function GTK_TYPE_TREE_SORTABLE : GType;
36function GTK_TREE_SORTABLE(obj: pointer) : PGtkTreeSortable;
37function GTK_TREE_SORTABLE_CLASS(obj: pointer) : PGtkTreeSortableIface;
38function GTK_IS_TREE_SORTABLE(obj: pointer) : boolean;
39function GTK_TREE_SORTABLE_GET_IFACE(obj: pointer) : PGtkTreeSortableIface;
40
41
42
43function gtk_tree_sortable_get_type:GType; cdecl; external gtklib;
44procedure gtk_tree_sortable_sort_column_changed(sortable:PGtkTreeSortable); cdecl; external gtklib;
45function gtk_tree_sortable_get_sort_column_id(sortable:PGtkTreeSortable; sort_column_id:Pgint; order:PGtkSortType):gboolean; cdecl; external gtklib;
46procedure gtk_tree_sortable_set_sort_column_id(sortable:PGtkTreeSortable; sort_column_id:gint; order:TGtkSortType); cdecl; external gtklib;
47procedure gtk_tree_sortable_set_sort_func(sortable:PGtkTreeSortable; sort_column_id:gint; sort_func:TGtkTreeIterCompareFunc; user_data:gpointer; destroy:TGtkDestroyNotify); cdecl; external gtklib;
48procedure gtk_tree_sortable_set_default_sort_func(sortable:PGtkTreeSortable; sort_func:TGtkTreeIterCompareFunc; user_data:gpointer; destroy:TGtkDestroyNotify); cdecl; external gtklib;
49function gtk_tree_sortable_has_default_sort_func(sortable:PGtkTreeSortable):gboolean; cdecl; external gtklib;
50{$ENDIF read_interface_rest}
51
52//------------------------------------------------------------------------------
53
54{$IFDEF read_implementation}
55function GTK_TYPE_TREE_SORTABLE : GType;
56begin
57   GTK_TYPE_TREE_SORTABLE:=gtk_tree_sortable_get_type;
58end;
59
60function GTK_TREE_SORTABLE(obj: pointer) : PGtkTreeSortable;
61begin
62   GTK_TREE_SORTABLE:=PGtkTreeSortable(G_TYPE_CHECK_INSTANCE_CAST(obj,GTK_TYPE_TREE_SORTABLE));
63end;
64
65function GTK_TREE_SORTABLE_CLASS(obj: pointer) : PGtkTreeSortableIface;
66begin
67   GTK_TREE_SORTABLE_CLASS:=PGtkTreeSortableIface(G_TYPE_CHECK_CLASS_CAST(obj,GTK_TYPE_TREE_SORTABLE));
68end;
69
70function GTK_IS_TREE_SORTABLE(obj: pointer) : boolean;
71begin
72   GTK_IS_TREE_SORTABLE:=G_TYPE_CHECK_INSTANCE_TYPE(obj,GTK_TYPE_TREE_SORTABLE);
73end;
74
75function GTK_TREE_SORTABLE_GET_IFACE(obj: pointer) : PGtkTreeSortableIface;
76begin
77   GTK_TREE_SORTABLE_GET_IFACE:=PGtkTreeSortableIface(G_TYPE_INSTANCE_GET_INTERFACE(obj,GTK_TYPE_TREE_SORTABLE));
78end;
79{$ENDIF read_implementation}
80// included by gtk2.pas
81
82