("GtkAssistant"
(:cffi gtk::current-page gtk::assistant-current-page :int "gtk_assistant_get_current_page" "gtk_assistant_set_current_page")
(:cffi gtk::n-pages gtk::assistant-n-pages :int "gtk_assistant_get_n_pages" nil)
- (:cffi gtk::forward-page-function gtk::assistant-forward-page-function nil nil gtk::set-assistant-forward-page-function))))))
+ (:cffi gtk::forward-page-function gtk::assistant-forward-page-function nil nil gtk::set-assistant-forward-page-function))
+ ("GtkLabel"
+ (:cffi gtk::line-wrap gtk::label-line-wrap :boolean "gtk_label_get_line_wrap" "gtk_label_set_line_wrap")
+ (:cffi gtk::line-wrap-mode gtk::label-line-wrap-mode gtk::pango-wrap-mode "gtk_label_line_wrap_mode" "gtk_label_set_line_wrap_mode")
+ (:cffi gtk::layout gtk::label-layout g-object "gtk_label_get_layout" nil)
+ (:cffi gtk::selection-bounds gtk::label-selection-bounds nil gtk::gtk-label-get-selection-bounds nil)
+ (:cffi gtk::layout-offsets gtk::label-layout-offsets nil gtk::gtk-label-get-layout-offsets nil))))))
(defun gtk-generate-child-properties (filename)
(with-open-file (stream filename :direction :output :if-exists :supersede)
t)
(wrap label-wrap "wrap" "gboolean" t t)
(wrap-mode label-wrap-mode "wrap-mode" "PangoWrapMode"
- t t)))
+ t t)
+ (:cffi line-wrap label-line-wrap :boolean
+ "gtk_label_get_line_wrap" "gtk_label_set_line_wrap")
+ (:cffi line-wrap-mode label-line-wrap-mode
+ pango-wrap-mode "gtk_label_line_wrap_mode"
+ "gtk_label_set_line_wrap_mode")
+ (:cffi layout label-layout g-object
+ "gtk_label_get_layout" nil)
+ (:cffi selection-bounds label-selection-bounds nil
+ gtk-label-get-selection-bounds nil)
+ (:cffi layout-offsets label-layout-offsets nil
+ gtk-label-get-layout-offsets nil)))
(define-g-object-class "GtkAccelLabel" accel-label
(:superclass label :export t :interfaces
(in-package :gtk)
-(defcfun gtk-label-get-layout-offsets :void
+(defcfun (%gtk-label-get-layout-offsets "gtk_label_get_layout_offsets") :void
(label (g-object label))
(x (:pointer :int))
(y (:pointer :int)))
-(defun label-layout-offsets (label)
+(defun gtk-label-get-layout-offsets (label)
(with-foreign-objects ((x :int) (y :int))
(gtk-label-get-layout-offsets label x y)
- (values (mem-ref x :int) (mem-ref y :int))))
-
-(export 'label-layout-offsets)
+ (list (mem-ref x :int) (mem-ref y :int))))
(defcfun (label-select-region "gtk_label_select_region") :void
(label (g-object label))
(export 'label-select-region)
-(defcfun (label-layout "gtk_label_get_layout") g-object ;(g-object pango-layout)
- (label (g-object label)))
+(defcfun (%gtk-label-get-selection-bounds "gtk_label_get_selection_bounds") :boolean
+ (label (g-object label))
+ (start (:pointer :int))
+ (end (:pointer :int)))
-(export 'label-layout)
\ No newline at end of file
+(defun gtk-label-get-selection-bounds (label)
+ (with-foreign-objects ((start :int) (end :int))
+ (when (%gtk-label-get-selection-bounds label start end)
+ (list (mem-ref start :int) (mem-ref end :int)))))
(export 'tree-path)
(export 'tree-path-indices)
+
+(define-g-enum "PangoWrapMode" pango-wrap-mode
+ (:export t :type-initializer
+ "pango_wrap_mode_get_type")
+ (:word 0) (:char 1) (:word-char 2))
+
+(define-g-enum "PangoEllipsizeMode" pango-ellipsize-mode
+ (:export t :type-initializer
+ "pango_ellipsize_mode_get_type")
+ (:none 0) (:start 1) (:middle 2) (:end 3))
\ No newline at end of file