summaryrefslogtreecommitdiff
path: root/src/Gtk/Widgets.dcl
diff options
context:
space:
mode:
authorCamil Staps2019-10-27 19:27:06 +0100
committerCamil Staps2019-10-27 19:27:06 +0100
commit667008c9fdc04a3564edc5f7c4076efe4ed5bc77 (patch)
treea55454c484372b4e12bea755181013be3cae8a45 /src/Gtk/Widgets.dcl
parentAdd withShared (diff)
Add basic support for GtkListStore and GtkTreeView
Diffstat (limited to 'src/Gtk/Widgets.dcl')
-rw-r--r--src/Gtk/Widgets.dcl23
1 files changed, 18 insertions, 5 deletions
diff --git a/src/Gtk/Widgets.dcl b/src/Gtk/Widgets.dcl
index 5f2baa5..a80d9a6 100644
--- a/src/Gtk/Widgets.dcl
+++ b/src/Gtk/Widgets.dcl
@@ -7,11 +7,13 @@ from System._Pointer import :: Pointer
from Gtk.State import :: GtkM
from Gtk.Tune import class tune
-from Gtk.Types import :: GtkButtonsType, :: GtkCSSClass, :: GtkDirection,
- :: GtkExpand, :: GtkFileChooserAction, :: GtkLabel, :: GtkMargins,
- :: GtkMessageType, :: GtkModal, :: GtkOrientation, :: GtkPanedHandleWidth,
- :: GtkResize, :: GtkResponse, :: GtkScrollbarPolicy, :: GtkShrink,
- :: GtkStylePriority, :: GtkTitle, :: GtkWrapMode
+from Gtk.Types import
+ :: GType, :: GValue,
+ :: GtkButtonsType, :: GtkCSSClass, :: GtkDirection, :: GtkExpand,
+ :: GtkFileChooserAction, :: GtkLabel, :: GtkMargins, :: GtkMessageType,
+ :: GtkModal, :: GtkOrientation, :: GtkPanedHandleWidth, :: GtkResize,
+ :: GtkResponse, :: GtkScrollbarPolicy, :: GtkShrink, :: GtkStylePriority,
+ :: GtkTitle, :: GtkWrapMode
class ptr a
where
@@ -63,6 +65,11 @@ instance ptr GtkFrame
newFrame :: !GtkLabel !w -> GtkM GtkFrame | gtkWidget w
framed :: !GtkLabel !(GtkM w) -> GtkM (w, GtkFrame) | gtkWidget w
+:: GtkListStore
+
+newListStore :: ![GType] -> GtkM GtkListStore
+appendToListStore :: ![GValue] !GtkListStore -> GtkM GtkListStore
+
:: GtkMenu
instance gtkWidget GtkMenu
@@ -147,6 +154,12 @@ getTextBuffer :: !GtkTextView -> GtkTextBuffer
instance tune GtkTextView GtkWrapMode
+:: GtkTreeView
+instance gtkWidget GtkTreeView
+
+newTreeView :: !GtkListStore -> GtkM GtkTreeView
+appendColumnToTreeView :: !String !Int !GtkExpand !GtkTreeView -> GtkM GtkTreeView
+
:: GtkWidget
class gtkWidget a :: !a -> GtkWidget