(width :int :initform 0)
(height :int :initform 0))
+(export (boxed-related-symbols 'rectangle))
+
(define-g-boxed-cstruct font "GdkFont"
(type font-type :initform :font)
(ascent :int :initform 0)
(descent :int :initform 0))
+(export (boxed-related-symbols 'font))
+
(define-g-boxed-cstruct color "GdkColor"
(pixel :uint32 :initform 0)
(red :uint16 :initform 0)
(green :uint16 :initform 0)
(blue :uint16 :initform 0))
+(export (boxed-related-symbols 'color))
+
(define-g-boxed-cstruct geometry "GdkGeometry"
(min-width :int :initform 0)
(min-height :int :initform 0)
(max-aspect :double :initform 0.0d0)
(gravity gravity :initform :north-west))
+(export (boxed-related-symbols 'geometry))
+
(defctype gdk-atom :pointer)
(define-foreign-type gdk-atom-as-string-type ()
;;;FIXME: Check correct type
(defctype native-window :uint32)
-(defcunion event-client-data-union
- (b :char :count 20)
- (s :short :count 10)
- (l :long :count 5))
-
(define-g-boxed-variant-cstruct event "GdkEvent"
(type event-type)
(window (g-object gdk-window))
(implicit :boolean)
(grab-window (g-object gdk-window)))))
+(export (boxed-related-symbols 'event))
+
(define-g-object-class "GdkDragContext" drag-context () ())
(define-g-flags "GdkWindowHints" window-hints ()
(export 'cell-layout-add-attribute)
(defcallback gtk-cell-layout-cell-data-func-callback :void
- ((cell-layout g-object) (cell g-object) (tree-model g-object) (iter (g-boxed-ref tree-iter)) (data :pointer))
+ ((cell-layout g-object) (cell g-object) (tree-model g-object) (iter (g-boxed-foreign tree-iter)) (data :pointer))
(restart-case
(funcall (get-stable-pointer-value data)
cell-layout cell tree-model iter)
(defcfun gtk-combo-box-get-active-iter :boolean
(combo-box g-object)
- (iter (g-boxed-ref tree-iter)))
+ (iter (g-boxed-foreign tree-iter)))
(defun combo-box-get-active-iter (combo-box)
(let ((i (make-instance 'tree-iter)))
(button-sensitivity combo-box-button-sensitivity
"button-sensitivity" "GtkSensitivityType" t t)
(:cffi active-iter combo-box-active-iter
- (g-boxed-ref tree-iter) combo-box-get-active-iter
+ (g-boxed-foreign tree-iter) combo-box-get-active-iter
"gtk_combo_box_set_active_iter")
(:cffi row-separator-func combo-box-separator-func nil
nil combo-box-set-separator-func)))
"background-set" "gboolean" t t)
(model cell-view-model "model" "GtkTreeModel" t t)
(:cffi displayed-row cell-view-displayed-row
- (g-boxed-ref tree-path)
+ (g-boxed-foreign tree-path)
"gtk_cell_view_get_displayed_row"
"gtk_cell_view_set_displayed_row")))
(defun icon-view-get-item-at-pos (icon-view x y)
(with-foreign-objects ((path :pointer) (cell :pointer))
(when (gtk-icon-view-get-item-at-pos icon-view x y path cell)
- (values (mem-ref path '(g-boxed-ref tree-path :owner :lisp))
+ (values (mem-ref path '(g-boxed-foreign tree-path :return))
(mem-ref cell 'g-object)))))
(export 'icon-view-get-item-at-pos)
(defcfun (icon-view-set-cursor "gtk_icon_view_set_cursor") :void
(icon-view g-object)
- (path (g-boxed-ref tree-path))
+ (path (g-boxed-foreign tree-path))
(cell g-object)
(start-editing :boolean))
(defun icon-view-get-cursor (icon-view)
(with-foreign-objects ((path :pointer) (cell :pointer))
(when (gtk-icon-view-get-cursor icon-view path cell)
- (values (mem-ref path '(g-boxed-ref tree-path))
+ (values (mem-ref path '(g-boxed-foreign tree-path :return))
(mem-ref cell 'g-object)))))
(export 'icon-view-get-cursor)
(defcallback gtk-icon-view-foreach-func-callback :void
- ((icon-view g-object) (path (g-boxed-ref tree-path)) (data :pointer))
+ ((icon-view g-object) (path (g-boxed-foreign tree-path)) (data :pointer))
(restart-case
(funcall (get-stable-pointer-value data)
icon-view
(defcfun (icon-view-select-path "gtk_icon_view_select_path") :void
(icon-view g-object)
- (path (g-boxed-ref tree-path)))
+ (path (g-boxed-foreign tree-path)))
(export 'icon-view-select-path)
(defcfun (icon-view-unselect-path "gtk_icon_view_unselect_path") :void
(icon-view g-object)
- (path (g-boxed-ref tree-path)))
+ (path (g-boxed-foreign tree-path)))
(export 'icon-view-unselect-path)
(defcfun (icon-view-path-selected-p "gtk_icon_view_path_is_selected") :boolean
(icon-view g-object)
- (path (g-boxed-ref tree-path)))
+ (path (g-boxed-foreign tree-path)))
(export 'icon-view-path-selected-p)
-(defcfun (icon-view-selected-items "gtk_icon_view_get_selected_items") (glist (g-boxed-ref tree-path) :free-from-foreign t)
+(defcfun (icon-view-selected-items "gtk_icon_view_get_selected_items") (glist (g-boxed-foreign tree-path) :free-from-foreign t)
(icon-view g-object))
(export 'icon-view-selected-items)
(defcfun gtk-icon-view-scroll-to-path :void
(icon-view g-object)
- (path (g-boxed-ref tree-path))
+ (path (g-boxed-foreign tree-path))
(use-align :boolean)
(row-align :float)
(col-align :float))
(defun icon-view-get-visible-range (icon-view)
(with-foreign-objects ((start-path :pointer) (end-path :pointer))
(when (gtk-icon-view-get-visible-range icon-view start-path end-path)
- (values (mem-ref start-path '(g-boxed-ref tree-path :owner :lisp))
- (mem-ref end-path '(g-boxed-ref tree-path :owner :lisp))))))
+ (values (mem-ref start-path '(g-boxed-foreign tree-path :return))
+ (mem-ref end-path '(g-boxed-foreign tree-path :return))))))
(export 'icon-view-get-visible-range)
; TODO: gtk_key_snooper_remove
-(defcfun (current-event "gtk_get_current_event") (g-boxed-ptr event))
+(defcfun (current-event "gtk_get_current_event") (g-boxed-foreign event :return))
(export 'current-event)
(export 'current-event-time)
(defcfun (event-widget "gtk_get_event_widget") g-object
- (event (g-boxed-ptr event)))
+ (event (g-boxed-foreign event)))
(export 'event-widget)
(defcfun (propagate-event "gtk_propagate_event") :void
(widget g-object)
- (event (g-boxed-ptr event)))
+ (event (g-boxed-foreign event)))
(export 'propagate-event)
(in-package :gtk)
-(define-g-boxed-class "GtkBorder" border ()
+(define-g-boxed-cstruct border "GtkBorder"
(left :int :initform 0)
(right :int :initform 0)
(top :int :initform 0)
(bottom :int :initform 0))
-(defcstruct tree-iter
- (stamp :int)
- (user-data :pointer)
- (user-data-2 :pointer)
- (user-data-3 :pointer))
-
-(defun tree-iter-get-stamp (i) (foreign-slot-value (pointer i) 'tree-iter 'stamp))
-(defun tree-iter-set-stamp (value i) (setf (foreign-slot-value (pointer i) 'tree-iter 'stamp) value))
-(defun tree-iter-get-user-data (i) (pointer-address (foreign-slot-value (pointer i) 'tree-iter 'user-data)))
-(defun tree-iter-set-user-data (value i) (setf (foreign-slot-value (pointer i) 'tree-iter 'user-data) (make-pointer value)))
-
-(defun tree-iter-alloc () (glib:g-malloc (foreign-type-size 'tree-iter)))
-(defun tree-iter-free (v) (glib:g-free v))
-
-(define-g-boxed-ref "GtkTreeIter" tree-iter
- (:slots (stamp :reader tree-iter-get-stamp :writer tree-iter-set-stamp :accessor tree-iter-stamp)
- (user-data :reader tree-iter-get-user-data :writer tree-iter-set-user-data :accessor tree-iter-user-data))
- (:alloc-function tree-iter-alloc)
- (:free-function tree-iter-free))
+(define-g-boxed-cstruct tree-iter "GtkTreeIter"
+ (stamp :int :initform 0)
+ (user-data :pointer :initform (null-pointer))
+ (user-data-2 :pointer :initform (null-pointer))
+ (user-data-3 :pointer :initform (null-pointer)))
(export 'tree-iter)
(export 'tree-iter-stamp)
(export 'tree-iter-user-data)
(defctype tree-path :pointer)
+
+(defcfun gtk-tree-path-new :pointer)
+(defcfun gtk-tree-path-free :void (path :pointer))
+
+(define-g-boxed-opaque tree-path "GtkTreePath"
+ :alloc (gtk-tree-path-new))
+
(defcfun (%gtk-tree-path-get-depth "gtk_tree_path_get_depth") :int
(path tree-path))
(defcfun (%gtk-tree-path-get-indices "gtk_tree_path_get_indices") (:pointer :int)
(path tree-path))
-(defcfun (%gtk-tree-path-new "gtk_tree_path_new") :pointer)
-
(defcfun (%gtk-tree-path-append-index "gtk_tree_path_append_index") :void
(path :pointer)
(index :int))
+(defun tree-path-indices (path)
+ (tree-path-get-indices path))
+
+(defun (setf tree-path-indices) (new-value path)
+ (tree-path-set-indices new-value path))
+
(defun tree-path-get-indices (path)
(setf path (pointer path))
(let ((n (%gtk-tree-path-get-depth path))
for index in indices
do(foreign-funcall "gtk_tree_path_append_index" :pointer path :int index :void)))
-(defcfun gtk-tree-path-new :pointer)
-(defcfun gtk-tree-path-free :void (path :pointer))
-
-(define-g-boxed-ref "GtkTreePath" tree-path
- (:alloc-function gtk-tree-path-new)
- (:free-function gtk-tree-path-free)
- (:slots (indices :reader tree-path-get-indices :writer tree-path-set-indices :accessor tree-path-indices)))
-
(export 'tree-path)
(export 'tree-path-indices)
(defmethod translate-to-foreign (value (type unichar))
(char-code value))
-(define-g-boxed-ref "GtkTextIter" text-iter
- (:free-function gtk-text-iter-free)
- (:alloc-function gtk-text-iter-alloc)
- (:slots (text-iter-buffer :reader "gtk_text_iter_get_buffer" :type (g-object text-buffer))
- (text-iter-offset :reader "gtk_text_iter_get_offset" :writer "gtk_text_iter_set_offset" :type :int)
- (text-iter-line :reader "gtk_text_iter_get_line" :writer "gtk_text_iter_set_line" :type :int)
- (text-iter-line-offset :reader "gtk_text_iter_get_line_offset" :writer "gtk_text_iter_set_line_offset" :type :int)
- (text-iter-visible-line-offset :reader "gtk_text_iter_get_visible_line_offset" :writer "gtk_text_iter_set_visible_line_offset" :type :int)
- (text-iter-char :reader "gtk_text_iter_get_char" :type unichar)
- (text-iter-pixbuf :reader "gtk_text_iter_get_pixbuf" :type (g-object pixbuf))
- (text-iter-marks :reader "gtk_text_iter_get_marks" :type (gslist (g-object text-mark) :free-from-foreign t))
- (text-iter-child-anchor :reader "gtk_text_iter_get_child_anchor" :type (g-object text-child-anchor))
- (text-iter-tags :reader "gtk_text_iter_get_tags" :type (gslist (g-object text-tag) :free-from-foreign t))
- (text-iter-chars-in-line :reader "gtk_text_iter_get_chars_in_line" :type :int)
- (text-iter-language :reader "gtk_text_iter_get_language" :type :pointer)
- (text-iter-is-end :reader "gtk_text_iter_is_end" :type :boolean)
- (text-iter-is-start :reader "gtk_text_iter_is_start" :type :boolean)
- (text-iter-can-insert :reader "gtk_text_iter_can_insert" :type :boolean)
- (text-iter-starts-word :reader "gtk_text_iter_starts_word" :type :boolean)
- (text-iter-ends-word :reader "gtk_text_iter_ends_word" :type :boolean)
- (text-iter-inside-word :reader "gtk_text_iter_inside_word" :type :boolean)
- (text-iter-starts-line :reader "gtk_text_iter_starts_line" :type :boolean)
- (text-iter-ends-line :reader "gtk_text_iter_ends_line" :type :boolean)
- (text-iter-starts-sentence :reader "gtk_text_iter_starts_sentence" :type :boolean)
- (text-iter-ends-sentence :reader "gtk_text_iter_ends_sentence" :type :boolean)
- (text-iter-inside-sentence :reader "gtk_text_iter_inside_sentence" :type :boolean)
- (text-iter-is-cursor-position :reader "gtk_text_iter_is_cursor_position" :type :boolean)
- ))
-(export '(text-iter text-iter-offset text-iter-line text-iter-line-offset text-iter-visible-line-offset text-iter-char text-iter-pixbuf text-iter-marks text-iter-toggled-tags text-iter-child-anchor text-iter-tags text-iter-chars-in-line text-iter-language))
+(define-g-boxed-opaque text-iter "GtkTextIter"
+ :alloc (gtk-text-iter-alloc))
+
+(define-boxed-opaque-accessor text-iter text-iter-buffer :reader "gtk_text_iter_get_buffer" :type (g-object text-buffer))
+(define-boxed-opaque-accessor text-iter text-iter-offset :reader "gtk_text_iter_get_offset" :writer "gtk_text_iter_set_offset" :type :int)
+(define-boxed-opaque-accessor text-iter text-iter-line :reader "gtk_text_iter_get_line" :writer "gtk_text_iter_set_line" :type :int)
+(define-boxed-opaque-accessor text-iter text-iter-line-offset :reader "gtk_text_iter_get_line_offset" :writer "gtk_text_iter_set_line_offset" :type :int)
+(define-boxed-opaque-accessor text-iter text-iter-visible-line-offset :reader "gtk_text_iter_get_visible_line_offset" :writer "gtk_text_iter_set_visible_line_offset" :type :int)
+(define-boxed-opaque-accessor text-iter text-iter-char :reader "gtk_text_iter_get_char" :type unichar)
+(define-boxed-opaque-accessor text-iter text-iter-pixbuf :reader "gtk_text_iter_get_pixbuf" :type (g-object pixbuf))
+(define-boxed-opaque-accessor text-iter text-iter-marks :reader "gtk_text_iter_get_marks" :type (gslist (g-object text-mark) :free-from-foreign t))
+(define-boxed-opaque-accessor text-iter text-iter-child-anchor :reader "gtk_text_iter_get_child_anchor" :type (g-object text-child-anchor))
+(define-boxed-opaque-accessor text-iter text-iter-tags :reader "gtk_text_iter_get_tags" :type (gslist (g-object text-tag) :free-from-foreign t))
+(define-boxed-opaque-accessor text-iter text-iter-chars-in-line :reader "gtk_text_iter_get_chars_in_line" :type :int)
+(define-boxed-opaque-accessor text-iter text-iter-language :reader "gtk_text_iter_get_language" :type :pointer)
+(define-boxed-opaque-accessor text-iter text-iter-is-end :reader "gtk_text_iter_is_end" :type :boolean)
+(define-boxed-opaque-accessor text-iter text-iter-is-start :reader "gtk_text_iter_is_start" :type :boolean)
+(define-boxed-opaque-accessor text-iter text-iter-can-insert :reader "gtk_text_iter_can_insert" :type :boolean)
+(define-boxed-opaque-accessor text-iter text-iter-starts-word :reader "gtk_text_iter_starts_word" :type :boolean)
+(define-boxed-opaque-accessor text-iter text-iter-ends-word :reader "gtk_text_iter_ends_word" :type :boolean)
+(define-boxed-opaque-accessor text-iter text-iter-inside-word :reader "gtk_text_iter_inside_word" :type :boolean)
+(define-boxed-opaque-accessor text-iter text-iter-starts-line :reader "gtk_text_iter_starts_line" :type :boolean)
+(define-boxed-opaque-accessor text-iter text-iter-ends-line :reader "gtk_text_iter_ends_line" :type :boolean)
+(define-boxed-opaque-accessor text-iter text-iter-starts-sentence :reader "gtk_text_iter_starts_sentence" :type :boolean)
+(define-boxed-opaque-accessor text-iter text-iter-ends-sentence :reader "gtk_text_iter_ends_sentence" :type :boolean)
+(define-boxed-opaque-accessor text-iter text-iter-inside-sentence :reader "gtk_text_iter_inside_sentence" :type :boolean)
+(define-boxed-opaque-accessor text-iter text-iter-is-cursor-position :reader "gtk_text_iter_is_cursor_position" :type :boolean)
+
+(export (boxed-related-symbols 'text-iter))
+(export '(text-iter-buffer text-iter-offset text-iter-line
+ text-iter-line-offset text-iter-visible-line-offset
+ text-iter-char text-iter-pixbuf text-iter-marks
+ text-iter-child-anchor text-iter-tags
+ text-iter-chars-in-line text-iter-language text-iter-is-end
+ text-iter-is-start text-iter-can-insert
+ text-iter-starts-word text-iter-ends-word
+ text-iter-inside-word text-iter-starts-line
+ text-iter-ends-line text-iter-starts-sentence
+ text-iter-ends-sentence text-iter-inside-sentence
+ text-iter-is-cursor-position ))
(defcstruct %text-iter
(dummy1 :pointer)
(defcfun gtk-text-iter-copy :pointer
(iter :pointer))
-(defcfun gtk-text-iter-free :void
- (iter :pointer))
-
(defun gtk-text-iter-alloc ()
(with-foreign-object (iter '%text-iter)
(gtk-text-iter-copy iter)))
(defcfun (text-iter-slice "gtk_text_iter_get_slice") (:string :free-from-foreign t)
- (start (g-boxed-ref text-iter))
- (end (g-boxed-ref text-iter)))
+ (start (g-boxed-foreign text-iter))
+ (end (g-boxed-foreign text-iter)))
(export 'text-iter-slice)
(defcfun (text-iter-text "gtk_text_iter_get_text") (:string :free-from-foreign t)
- (start (g-boxed-ref text-iter))
- (end (g-boxed-ref text-iter)))
+ (start (g-boxed-foreign text-iter))
+ (end (g-boxed-foreign text-iter)))
(export 'text-iter-text)
(defcfun (text-iter-visible-slice "gtk_text_iter_get_visible_slice") (:string :free-from-foreign t)
- (start (g-boxed-ref text-iter))
- (end (g-boxed-ref text-iter)))
+ (start (g-boxed-foreign text-iter))
+ (end (g-boxed-foreign text-iter)))
(export 'text-iter-visible-slice)
(defcfun (text-iter-visible-text "gtk_text_iter_get_visible_text") (:string :free-from-foreign t)
- (start (g-boxed-ref text-iter))
- (end (g-boxed-ref text-iter)))
+ (start (g-boxed-foreign text-iter))
+ (end (g-boxed-foreign text-iter)))
(export 'text-iter-visible-text)
(defcfun (text-iter-toggled-tags "gtk_text_iter_get_toggled_tags") (gslist (g-object text-tag))
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(toggled-on :boolean))
(export 'text-iter-toggled-tags)
(defcfun (text-iter-begins-tag "gtk_text_iter_begins_tag") :boolean
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(tag (g-object text-tag)))
(export 'text-iter-begins-tag)
(defcfun (text-iter-ends-tag "gtk_text_iter_ends_tag") :boolean
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(tag (g-object text-tag)))
(export 'text-iter-ends-tag)
(defcfun (text-iter-toggles-tag "gtk_text_iter_toggles_tag") :boolean
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(tag (g-object text-tag)))
(export 'text-iter-toggles-tag)
(defcfun (text-iter-has-tag "gtk_text_iter_has_tag") :boolean
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(tag (g-object text-tag)))
(export 'text-iter-has-tag)
(defcfun (text-iter-editable "gtk_text_iter_editable") :boolean
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(default :boolean))
(export 'text-iter-editable)
(defcfun gtk-text-iter-get-attributes :boolean
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(values (g-object text-attributes)))
(defun text-iter-attributes (iter default-attributes)
(export 'text-iter-attributes)
(defcfun gtk-text-iter-forward-chars :boolean
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(count :int))
(defcfun gtk-text-iter-forward-lines :boolean
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(count :int))
(defcfun gtk-text-iter-forward-word-ends :boolean
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(count :int))
(defcfun gtk-text-iter-backward-word-starts :boolean
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(count :int))
(defcfun gtk-text-iter-forward-cursor-positions :boolean
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(count :int))
(defcfun gtk-text-iter-forward-sentence-ends :boolean
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(count :int))
(defcfun gtk-text-iter-backward-sentence-starts :boolean
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(count :int))
(defcfun gtk-text-iter-forward-visible-word-ends :boolean
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(count :int))
(defcfun gtk-text-iter-backward-visible-word-starts :boolean
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(count :int))
(defcfun gtk-text-iter-forward-visible-cursor-positions :boolean
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(count :int))
(defcfun gtk-text-iter-forward-visible-lines :boolean
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(count :int))
(defun text-iter-move (iter &key (count 1) (by :char) (direction :forward))
(export 'text-iter-move)
(defcfun (text-iter-forward-to-end "gtk_text_iter_forward_to_end") :void
- (iter (g-boxed-ref text-iter)))
+ (iter (g-boxed-foreign text-iter)))
(export 'text-iter-forward-to-end)
(defcfun (text-iter-forward-to-line-end "gtk_text_iter_forward_to_line_end") :boolean
- (iter (g-boxed-ref text-iter)))
+ (iter (g-boxed-foreign text-iter)))
(export 'text-iter-forward-to-line-end)
(defcfun (text-iter-forward-to-tag-toggle "gtk_text_iter_forward_to_tag_toggle") :boolean
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(tag (g-object text-tag)))
(defcfun (text-iter-backward-to-tag-toggle "gtk_text_iter_backward_to_tag_toggle") :boolean
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(tag (g-object text-tag)))
(export '(text-iter-forward-to-tag-toggle text-iter-backward-to-tag-toggle))
(funcall function char)))
(defcfun gtk-text-iter-forward-find-char :boolean
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(pred :pointer)
(user-data :pointer)
- (limit (g-boxed-ref text-iter)))
+ (limit (g-boxed-foreign text-iter)))
(defcfun gtk-text-iter-backward-find-char :boolean
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(pred :pointer)
(user-data :pointer)
- (limit (g-boxed-ref text-iter)))
+ (limit (g-boxed-foreign text-iter)))
(defun text-iter-find-char (iter predicate &key limit (direction :forward))
(assert (typep direction '(member :forward :backward)))
(export 'text-iter-find-char)
(defcfun gtk-text-iter-forward-search :boolean
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(str (:string :free-to-foreign t))
(flags text-search-flags)
- (match-start (g-boxed-ref text-iter))
- (match-end (g-boxed-ref text-iter))
- (limit (g-boxed-ref text-iter)))
+ (match-start (g-boxed-foreign text-iter))
+ (match-end (g-boxed-foreign text-iter))
+ (limit (g-boxed-foreign text-iter)))
(defcfun gtk-text-iter-backward-search :boolean
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(str (:string :free-to-foreign t))
(flags text-search-flags)
- (match-start (g-boxed-ref text-iter))
- (match-end (g-boxed-ref text-iter))
- (limit (g-boxed-ref text-iter)))
+ (match-start (g-boxed-foreign text-iter))
+ (match-end (g-boxed-foreign text-iter))
+ (limit (g-boxed-foreign text-iter)))
(defun text-iter-search (start-position string &key flags limit (direction :forward))
(assert (typep direction '(member :forward :backward)))
(export 'text-iter-search)
(defcfun (text-iter-equal "gtk_text_iter_equal") :boolean
- (iter-1 (g-boxed-ref text-iter))
- (iter-2 (g-boxed-ref text-iter)))
+ (iter-1 (g-boxed-foreign text-iter))
+ (iter-2 (g-boxed-foreign text-iter)))
(export 'text-iter-equal)
(defcfun (text-iter-compare "gtk_text_iter_compare") :int
- (iter-1 (g-boxed-ref text-iter))
- (iter-2 (g-boxed-ref text-iter)))
+ (iter-1 (g-boxed-foreign text-iter))
+ (iter-2 (g-boxed-foreign text-iter)))
(export 'text-iter-compare)
(defcfun (text-iter-in-range "gtk_text_iter_in_range") :boolean
- (iter (g-boxed-ref text-iter))
- (start (g-boxed-ref text-iter))
- (end (g-boxed-ref text-iter)))
+ (iter (g-boxed-foreign text-iter))
+ (start (g-boxed-foreign text-iter))
+ (end (g-boxed-foreign text-iter)))
(export 'text-iter-in-range)
(defcfun (text-iter-order "gtk_text_iter_order") :void
- (iter-1 (g-boxed-ref text-iter))
- (iter-2 (g-boxed-ref text-iter)))
+ (iter-1 (g-boxed-foreign text-iter))
+ (iter-2 (g-boxed-foreign text-iter)))
(export 'text-iter-order)
(defcfun gtk-text-buffer-insert :void
(buffer (g-object text-buffer))
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(text (:string :free-to-foreign t))
(len :int))
(defcfun gtk-text-buffer-insert-interactive :boolean
(buffer (g-object text-buffer))
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(text (:string :free-to-foreign t))
(len :int)
(default-editable :boolean))
(defcfun gtk-text-buffer-insert-range :void
(buffer (g-object text-buffer))
- (iter (g-boxed-ref text-iter))
- (range-start (g-boxed-ref text-iter))
- (range-end (g-boxed-ref text-iter)))
+ (iter (g-boxed-foreign text-iter))
+ (range-start (g-boxed-foreign text-iter))
+ (range-end (g-boxed-foreign text-iter)))
(defcfun gtk-text-buffer-insert-range-interactive :boolean
(buffer (g-object text-buffer))
- (iter (g-boxed-ref text-iter))
- (range-start (g-boxed-ref text-iter))
- (range-end (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
+ (range-start (g-boxed-foreign text-iter))
+ (range-end (g-boxed-foreign text-iter))
(default-editable :boolean))
(defun text-buffer-insert-range (buffer position range-start range-end &key interactive default-editable)
(defcfun gtk-text-buffer-delete :void
(buffer (g-object text-buffer))
- (range-start (g-boxed-ref text-iter))
- (range-end (g-boxed-ref text-iter)))
+ (range-start (g-boxed-foreign text-iter))
+ (range-end (g-boxed-foreign text-iter)))
(defcfun gtk-text-buffer-delete-interactive :boolean
(buffer (g-object text-buffer))
- (range-start (g-boxed-ref text-iter))
- (range-end (g-boxed-ref text-iter))
+ (range-start (g-boxed-foreign text-iter))
+ (range-end (g-boxed-foreign text-iter))
(default-editable :boolean))
(defun text-buffer-delete (buffer range-start range-end &key interactive default-editable)
(defcfun gtk-text-buffer-backspace :boolean
(buffer (g-object text-buffer))
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(interactive :boolean)
(default-editable :boolean))
(defcfun gtk-text-buffer-get-slice (:string :free-from-foreign t)
(buffer (g-object text-buffer))
- (range-start (g-boxed-ref text-iter))
- (range-end (g-boxed-ref text-iter))
+ (range-start (g-boxed-foreign text-iter))
+ (range-end (g-boxed-foreign text-iter))
(include-hidden-chars :boolean))
(defun text-buffer-slice (buffer range-start range-end &key include-hidden-chars)
(defcfun (text-buffer-insert-pixbuf "gtk_text_buffer_insert_pixbuf") :void
(buffer (g-object text-buffer))
- (position (g-boxed-ref text-iter))
+ (position (g-boxed-foreign text-iter))
(pixbuf (g-object pixbuf)))
(export 'text-buffer-insert-pixbuf)
(defcfun gtk-text-buffer-insert-child-anchor :void
(buffer (g-object text-buffer))
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(anchor (g-object text-child-anchor)))
(defcfun gtk-text-buffer-create-child-anchor (g-object text-child-anchor)
(buffer (g-object text-buffer))
- (iter (g-boxed-ref text-iter)))
+ (iter (g-boxed-foreign text-iter)))
(defun text-buffer-insert-child-anchor (buffer position &optional anchor)
(if anchor
(defcfun gtk-text-buffer-create-mark (g-object text-mark)
(buffer (g-object text-buffer))
(name (:string :free-to-foreign t))
- (position (g-boxed-ref text-iter))
+ (position (g-boxed-foreign text-iter))
(left-gravity :boolean))
(defun text-buffer-create-mark (buffer name position &optional (left-gravity t))
(defcfun gtk-text-buffer-move-mark :void
(buffer (g-object text-buffer))
(mark (g-object text-mark))
- (position (g-boxed-ref text-iter)))
+ (position (g-boxed-foreign text-iter)))
(defcfun gtk-text-buffer-move-mark-by-name :void
(buffer (g-object text-buffer))
(name (:string :free-to-foreign t))
- (position (g-boxed-ref text-iter)))
+ (position (g-boxed-foreign text-iter)))
(defun text-buffer-move-mark (buffer mark position)
(etypecase mark
(defcfun (text-buffer-add-mark "gtk_text_buffer_add_mark") :void
(buffer (g-object text-buffer))
(mark (g-object text-mark))
- (position (g-boxed-ref text-iter)))
+ (position (g-boxed-foreign text-iter)))
(export 'text-buffer-add-mark)
(defcfun (text-buffer-place-cursor "gtk_text_buffer_place_cursor") :void
(buffer (g-object text-buffer))
- (position (g-boxed-ref text-iter)))
+ (position (g-boxed-foreign text-iter)))
(export 'text-buffer-place-cursor)
(defcfun (text-buffer-select-range "gtk_text_buffer_select_range") :void
(buffer (g-object text-buffer))
- (insertion-point (g-boxed-ref text-iter))
- (selection-bound (g-boxed-ref text-iter)))
+ (insertion-point (g-boxed-foreign text-iter))
+ (selection-bound (g-boxed-foreign text-iter)))
(export 'text-buffer-select-range)
(defcfun gtk-text-buffer-apply-tag :void
(buffer (g-object text-buffer))
(tag (g-object text-tag))
- (start (g-boxed-ref text-iter))
- (end (g-boxed-ref text-iter)))
+ (start (g-boxed-foreign text-iter))
+ (end (g-boxed-foreign text-iter)))
(defcfun gtk-text-buffer-apply-tag-by-name :void
(buffer (g-object text-buffer))
(name (:string :free-to-foreign t))
- (start (g-boxed-ref text-iter))
- (end (g-boxed-ref text-iter)))
+ (start (g-boxed-foreign text-iter))
+ (end (g-boxed-foreign text-iter)))
(defun text-buffer-apply-tag (buffer tag start end)
(etypecase tag
(defcfun gtk-text-buffer-remove-tag :void
(buffer (g-object text-buffer))
(tag (g-object text-tag))
- (start (g-boxed-ref text-iter))
- (end (g-boxed-ref text-iter)))
+ (start (g-boxed-foreign text-iter))
+ (end (g-boxed-foreign text-iter)))
(defcfun gtk-text-buffer-remove-tag-by-name :void
(buffer (g-object text-buffer))
(name (:string :free-to-foreign t))
- (start (g-boxed-ref text-iter))
- (end (g-boxed-ref text-iter)))
+ (start (g-boxed-foreign text-iter))
+ (end (g-boxed-foreign text-iter)))
(defun text-buffer-remove-tag (buffer tag start end)
(etypecase tag
(defcfun (text-buffer-remove-all-tags "gtk_text_buffer_remove_all_tags") :void
(buffer (g-object text-buffer))
- (start (g-boxed-ref text-iter))
- (end (g-boxed-ref text-iter)))
+ (start (g-boxed-foreign text-iter))
+ (end (g-boxed-foreign text-iter)))
(defcfun gtk-text-buffer-get-iter-at-line-offset :void
(buffer (g-object text-buffer))
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(line-number :int)
(char-offset :int))
(defcfun gtk-text-buffer-get-iter-at-offset :void
(buffer (g-object text-buffer))
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(char-offset :int))
(defun text-buffer-get-iter-at-offset (buffer offset)
(defcfun gtk-text-buffer-get-iter-at-line :void
(buffer (g-object text-buffer))
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(line-number :int))
(defun text-buffer-get-iter-at-line (buffer line-number)
(defcfun gtk-text-buffer-get-iter-at-mark :void
(buffer (g-object text-buffer))
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(mark (g-object text-mark)))
(defun text-buffer-get-iter-at-mark (buffer mark)
(defcfun gtk-text-buffer-get-iter-at-child-anchor :void
(buffer (g-object text-buffer))
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(anchor (g-object text-child-anchor)))
(defun text-buffer-get-iter-at-child-anchor (buffer anchor)
(defcfun gtk-text-buffer-get-start-iter :void
(buffer (g-object text-buffer))
- (iter (g-boxed-ref text-iter)))
+ (iter (g-boxed-foreign text-iter)))
(defun text-buffer-get-start-iter (buffer)
(let ((iter (make-instance 'text-iter)))
(defcfun gtk-text-buffer-get-end-iter :void
(buffer (g-object text-buffer))
- (iter (g-boxed-ref text-iter)))
+ (iter (g-boxed-foreign text-iter)))
(defun text-buffer-get-end-iter (buffer)
(let ((iter (make-instance 'text-iter)))
(defcfun gtk-text-buffer-get-bounds :void
(buffer (g-object text-buffer))
- (start (g-boxed-ref text-iter))
- (end (g-boxed-ref text-iter)))
+ (start (g-boxed-foreign text-iter))
+ (end (g-boxed-foreign text-iter)))
(defun text-buffer-get-bounds (buffer)
(let ((start (make-instance 'text-iter))
(defcfun gtk-text-buffer-paste-clipboard :void
(buffer (g-object text-buffer))
(clipboard (g-object clipboard))
- (override-location (g-boxed-ref text-iter))
+ (override-location (g-boxed-foreign text-iter))
(default-editable :boolean))
(defun text-buffer-paste-clipboard (buffer clipboard &key position default-editable)
(defcfun gtk-text-buffer-get-selection-bounds :boolean
(buffer (g-object text-buffer))
- (start (g-boxed-ref text-iter))
- (end (g-boxed-ref text-iter)))
+ (start (g-boxed-foreign text-iter))
+ (end (g-boxed-foreign text-iter)))
(defun text-buffer-get-selection-bounds (buffer)
(let ((i1 (make-instance 'text-iter))
(defcfun gtk-text-view-get-visible-rect :void
(text-view (g-object text-view))
- (visible-rect (g-boxed-ptr rectangle :in-out)))
+ (visible-rect (g-boxed-foreign rectangle)))
(defun text-view-visible-rect (text-view)
(let ((rect (make-rectangle :x 0 :y 0 :width 0 :height 0)))
(defcfun gtk-text-view-get-iter-location :void
(text-view (g-object text-view))
- (iter (g-boxed-ref text-iter))
- (location (g-boxed-ptr rectangle :in-out)))
+ (iter (g-boxed-foreign text-iter))
+ (location (g-boxed-foreign rectangle)))
(defun text-view-iter-location (text-view iter)
(let ((rect (make-rectangle :x 0 :y 0 :width 0 :height 0)))
(defcfun gtk-text-view-get-iter-at-location :void
(text-view (g-object text-view))
- (iter (g-boxed-ref text-iter))
+ (iter (g-boxed-foreign text-iter))
(x :int)
(y :int))
(defcfun (tooltip-set-tip-area "gtk_tooltip_set_tip_area") :void
(tooltip g-object)
- (rectangle (g-boxed-ptr rectangle)))
+ (rectangle (g-boxed-foreign rectangle)))
(export 'tooltip-set-tip-area)
\ No newline at end of file
(tree-model-get-flags-impl tree-model-get-flags-cb tree-model-flags (tree-model g-object))
(tree-model-get-n-columns-impl tree-model-get-n-columns-cb :int (tree-model g-object))
(tree-model-get-column-type-impl tree-model-get-column-type-cb g-type-designator (tree-model g-object) (index :int))
- (tree-model-get-iter-impl tree-model-get-iter-cb :boolean (tree-model g-object) (iter (g-boxed-ref tree-iter)) (path (g-boxed-ref tree-path)))
- (tree-model-get-path-impl tree-model-get-path-cb (g-boxed-ref tree-path) (tree-model g-object) (iter (g-boxed-ref tree-iter)))
- (tree-model-get-value-impl tree-model-get-value-cb :void (tree-model g-object) (iter (g-boxed-ref tree-iter)) (n :int) (value (:pointer g-value)))
- (tree-model-iter-next-impl tree-model-iter-next-cb :boolean (tree-model g-object) (iter (g-boxed-ref tree-iter)))
- (tree-model-iter-children-impl tree-model-iter-children-cb :boolean (tree-model g-object) (iter (g-boxed-ref tree-iter)) (parent (g-boxed-ref tree-iter)))
- (tree-model-iter-has-child-impl tree-model-iter-has-child-cb :boolean (tree-model g-object) (iter (g-boxed-ref tree-iter)))
- (tree-model-iter-n-children-impl tree-model-iter-n-children-cb :int (tree-model g-object) (iter (g-boxed-ref tree-iter)))
- (tree-model-iter-nth-child-impl tree-model-iter-nth-child-cb :boolean (tree-model g-object) (iter (g-boxed-ref tree-iter)) (parent (g-boxed-ref tree-iter)) (n :int))
- (tree-model-iter-parent-impl tree-model-iter-parent-cb :boolean (tree-model g-object) (iter (g-boxed-ref tree-iter)) (child (g-boxed-ref tree-iter)))
- (tree-model-ref-node-impl tree-model-ref-node-cb :void (tree-model g-object) (iter (g-boxed-ref tree-iter)))
- (tree-model-unref-node-impl tree-model-unref-node-cb :void (tree-model g-object) (iter (g-boxed-ref tree-iter))))
+ (tree-model-get-iter-impl tree-model-get-iter-cb :boolean (tree-model g-object) (iter (g-boxed-foreign tree-iter)) (path (g-boxed-foreign tree-path)))
+ (tree-model-get-path-impl tree-model-get-path-cb (g-boxed-foreign tree-path :return) (tree-model g-object) (iter (g-boxed-foreign tree-iter)))
+ (tree-model-get-value-impl tree-model-get-value-cb :void (tree-model g-object) (iter (g-boxed-foreign tree-iter)) (n :int) (value (:pointer g-value)))
+ (tree-model-iter-next-impl tree-model-iter-next-cb :boolean (tree-model g-object) (iter (g-boxed-foreign tree-iter)))
+ (tree-model-iter-children-impl tree-model-iter-children-cb :boolean (tree-model g-object) (iter (g-boxed-foreign tree-iter)) (parent (g-boxed-foreign tree-iter)))
+ (tree-model-iter-has-child-impl tree-model-iter-has-child-cb :boolean (tree-model g-object) (iter (g-boxed-foreign tree-iter)))
+ (tree-model-iter-n-children-impl tree-model-iter-n-children-cb :int (tree-model g-object) (iter (g-boxed-foreign tree-iter)))
+ (tree-model-iter-nth-child-impl tree-model-iter-nth-child-cb :boolean (tree-model g-object) (iter (g-boxed-foreign tree-iter)) (parent (g-boxed-foreign tree-iter)) (n :int))
+ (tree-model-iter-parent-impl tree-model-iter-parent-cb :boolean (tree-model g-object) (iter (g-boxed-foreign tree-iter)) (child (g-boxed-foreign tree-iter)))
+ (tree-model-ref-node-impl tree-model-ref-node-cb :void (tree-model g-object) (iter (g-boxed-foreign tree-iter)))
+ (tree-model-unref-node-impl tree-model-unref-node-cb :void (tree-model g-object) (iter (g-boxed-foreign tree-iter))))
; TODO: GtkTreeSortable
0))
(defmethod tree-model-get-path-impl ((model array-list-store) iter)
- (using* (iter)
- (let ((path (make-instance 'tree-path)))
- (setf (tree-path-indices path) (list (tree-iter-user-data iter)))
- (disown-boxed-ref path)
- path)))
+ (let ((path (make-instance 'tree-path)))
+ (setf (tree-path-indices path) (list (tree-iter-user-data iter)))
+ path))
(defmethod tree-model-iter-has-child-impl ((model array-list-store) iter)
(release iter)
(defcfun (tree-model-set-iter-to-path "gtk_tree_model_get_iter") :boolean
(tree-model g-object)
- (iter (g-boxed-ref tree-iter))
- (path (g-boxed-ref tree-path)))
+ (iter (g-boxed-foreign tree-iter))
+ (path (g-boxed-foreign tree-path)))
(defun tree-model-iter-by-path (tree-model tree-path)
(let ((iter (make-instance 'tree-iter)))
(defcfun (tree-model-set-iter-from-string "gtk_tree_model_get_iter_from_string") :boolean
(tree-model g-object)
- (iter (g-boxed-ref tree-iter))
+ (iter (g-boxed-foreign tree-iter))
(path-string :string))
(defun tree-model-iter-from-string (tree-model path-string)
(defcfun (tree-model-set-iter-to-first "gtk_tree_model_get_iter_first") :boolean
(model g-object)
- (iter (g-boxed-ref tree-iter)))
+ (iter (g-boxed-foreign tree-iter)))
(defun tree-model-iter-first (tree-model)
(let ((iter (make-instance 'tree-iter)))
(export 'tree-model-iter-first)
-(defcfun (tree-model-path "gtk_tree_model_get_path") (g-boxed-ref tree-path :owner :lisp)
+(defcfun (tree-model-path "gtk_tree_model_get_path") (g-boxed-foreign tree-path :return)
(tree-model g-object)
- (iter (g-boxed-ref tree-iter)))
+ (iter (g-boxed-foreign tree-iter)))
(export 'tree-model-path)
(defcfun gtk-tree-model-get-value :void
(model g-object)
- (iter (g-boxed-ref tree-iter))
+ (iter (g-boxed-foreign tree-iter))
(column :int)
(value (:pointer g-value)))
(defcfun (tree-model-iter-next "gtk_tree_model_iter_next") :boolean
(tree-model g-object)
- (iter (g-boxed-ref tree-iter)))
+ (iter (g-boxed-foreign tree-iter)))
(export 'tree-model-iter-next)
(defcfun gtk-tree-model-iter-children :boolean
(tree-model g-object)
- (iter (g-boxed-ref tree-iter))
- (parent (g-boxed-ref tree-iter)))
+ (iter (g-boxed-foreign tree-iter))
+ (parent (g-boxed-foreign tree-iter)))
(defun tree-model-iter-first-child (tree-model parent)
(let ((iter (make-instance 'tree-iter)))
(defcfun (tree-model-iter-has-child "gtk_tree_model_iter_has_child") :boolean
(tree-model g-object)
- (iter (g-boxed-ref tree-iter)))
+ (iter (g-boxed-foreign tree-iter)))
(export 'tree-model-iter-has-child)
(defcfun (tree-model-iter-n-children "gtk_tree_model_iter_n_children") :int
(tree-model g-object)
- (iter (g-boxed-ref tree-iter)))
+ (iter (g-boxed-foreign tree-iter)))
(export 'tree-model-iter-n-children)
(defcfun gtk-tree-model-iter-nth-child :boolean
(tree-model g-object)
- (iter (g-boxed-ref tree-iter))
- (parent (g-boxed-ref tree-iter))
+ (iter (g-boxed-foreign tree-iter))
+ (parent (g-boxed-foreign tree-iter))
(n :int))
(defun tree-model-iter-nth-child (tree-model parent n)
(defcfun gtk-tree-model-iter-parent :boolean
(tree-model g-object)
- (iter (g-boxed-ref tree-iter))
- (parent (g-boxed-ref tree-iter)))
+ (iter (g-boxed-foreign tree-iter))
+ (parent (g-boxed-foreign tree-iter)))
(defun tree-model-iter-parent (tree-model iter)
(let ((parent (make-instance 'tree-iter)))
(defcfun (tree-model-iter-to-string "gtk_tree_model_get_string_from_iter") (g-string :free-from-foreign t)
(tree-model g-object)
- (iter (g-boxed-ref tree-iter)))
+ (iter (g-boxed-foreign tree-iter)))
(export 'tree-model-iter-to-string)
(defcfun (tree-model-ref-node "gtk_tree_model_ref_node") :void
(tree-model g-object)
- (iter (g-boxed-ref tree-iter)))
+ (iter (g-boxed-foreign tree-iter)))
(export 'tree-model-ref-node)
(defcfun (tree-model-unref-node "gtk_tree_model_unref_node") :void
(tree-model g-object)
- (iter (g-boxed-ref tree-iter)))
+ (iter (g-boxed-foreign tree-iter)))
(export 'tree-model-unref-node)
-(defcallback gtk-tree-model-foreach-cb :boolean ((model g-object) (path (g-boxed-ref tree-path)) (iter (g-boxed-ref tree-iter)) (data :pointer))
+(defcallback gtk-tree-model-foreach-cb :boolean ((model g-object) (path (g-boxed-foreign tree-path)) (iter (g-boxed-foreign tree-iter)) (data :pointer))
(let ((fn (get-stable-pointer-value data)))
(restart-case
(funcall fn model path iter)
(get-node-by-id tree (tree-iter-user-data iter)))
(defmethod tree-model-get-path-impl ((store array-list-store) iter)
- (using* (iter)
- (let* ((path (make-instance 'tree-path))
- (node (get-node-by-iter store iter))
- (indices (get-node-path node)))
- (setf (tree-path-indices path) indices)
- (disown-boxed-ref path)
- path)))
+ (let* ((path (make-instance 'tree-path))
+ (node (get-node-by-iter store iter))
+ (indices (get-node-path node)))
+ (setf (tree-path-indices path) indices)
+ path))
(defmethod tree-model-get-value-impl ((store tree-lisp-store) iter n value)
(using* (iter)
(destroy-notify :pointer))
(defcallback gtk-tree-selection-select-function-callback :boolean
- ((selection g-object) (model g-object) (path (g-boxed-ref tree-path)) (path-currently-selected :boolean) (data :pointer))
+ ((selection g-object) (model g-object) (path (g-boxed-foreign tree-path)) (path-currently-selected :boolean) (data :pointer))
(let ((fn (get-stable-pointer-value data)))
(restart-case
(funcall fn selection model path path-currently-selected)
(defcfun gtk-tree-selection-get-selected :boolean
(selection g-object)
(model :pointer)
- (iter (g-boxed-ref tree-iter)))
+ (iter (g-boxed-foreign tree-iter)))
(defun tree-selection-selected (tree-selection)
(let ((iter (make-instance 'tree-iter)))
(data :pointer))
(defcallback gtk-tree-selection-foreach-callback :void
- ((model g-object) (path (g-boxed-ref tree-path)) (iter (g-boxed-ref tree-iter)) (data :pointer))
+ ((model g-object) (path (g-boxed-foreign tree-path)) (iter (g-boxed-foreign tree-iter)) (data :pointer))
(let ((fn (get-stable-pointer-value data)))
(funcall fn model path iter)))
(export 'map-tree-selection-rows)
-(defcfun gtk-tree-selection-get-selected-rows (glist (g-boxed-ref tree-path) :free-from-foreign t)
+(defcfun gtk-tree-selection-get-selected-rows (glist (g-boxed-foreign tree-path) :free-from-foreign t)
(selection g-object)
(model :pointer))
(defcfun (tree-selection-select-path "gtk_tree_selection_select_path") :void
(selection g-object)
- (path (g-boxed-ref tree-path)))
+ (path (g-boxed-foreign tree-path)))
(export 'tree-selection-select-path)
(defcfun (tree-selection-unselect-path "gtk_tree_selection_unselect_path") :void
(selection g-object)
- (path (g-boxed-ref tree-path)))
+ (path (g-boxed-foreign tree-path)))
(export 'tree-selection-unselect-path)
(defcfun (tree-selection-path-selected-p "gtk_tree_selection_path_is_selected") :boolean
(selection g-object)
- (path (g-boxed-ref tree-path)))
+ (path (g-boxed-foreign tree-path)))
(export 'tree-selection-path-selected-p)
(defcfun (tree-selection-select-iter "gtk_tree_selection_select_iter") :void
(selection g-object)
- (iter (g-boxed-ref tree-iter)))
+ (iter (g-boxed-foreign tree-iter)))
(export 'tree-selection-select-iter)
(defcfun (tree-selection-unselect-iter "gtk_tree_selection_unselect_iter") :void
(selection g-object)
- (iter (g-boxed-ref tree-iter)))
+ (iter (g-boxed-foreign tree-iter)))
(export 'tree-selection-unselect-iter)
(defcfun (tree-selection-iter-selected-p "gtk_tree_selection_iter_is_selected") :boolean
(selection g-object)
- (iter (g-boxed-ref tree-iter)))
+ (iter (g-boxed-foreign tree-iter)))
(export 'tree-selection-iter-selected-p)
(defcfun (tree-selection-select-range "gtk_tree_selection_select_range") :void
(selection g-object)
- (start-path (g-boxed-ref tree-path))
- (end-path (g-boxed-ref tree-path)))
+ (start-path (g-boxed-foreign tree-path))
+ (end-path (g-boxed-foreign tree-path)))
(export 'tree-selection-select-range)
(defcfun (tree-selection-unselect-range "gtk_tree_selection_unselect_range") :void
(selection g-object)
- (start-path (g-boxed-ref tree-path))
- (end-path (g-boxed-ref tree-path)))
+ (start-path (g-boxed-foreign tree-path))
+ (end-path (g-boxed-foreign tree-path)))
(export 'tree-selection-unselect-range)
\ No newline at end of file
((tree-column (g-object tree-column))
(cell (g-object cell-renderer))
(tree-model (g-object tree-model))
- (iter (g-boxed-ref tree-iter))
+ (iter (g-boxed-foreign tree-iter))
(data :pointer))
(let ((fn (get-stable-pointer-value data)))
(restart-case
(defcfun (tree-view-column-cell-set-cell-data "gtk_tree_view_column_cell_set_cell_data") :void
(tree-column (g-object tree-view-column))
(tree-model (g-object tree-model))
- (iter (g-boxed-ref tree-iter))
+ (iter (g-boxed-foreign tree-iter))
(is-expander :boolean)
(is-expanded :boolean))
(defcfun gtk-tree-view-scroll-to-cell :void
(tree-view g-object)
- (path (g-boxed-ref tree-path))
+ (path (g-boxed-foreign tree-path))
(column g-object)
(use-align :boolean)
(row-align :float)
(defcfun gtk-tree-view-set-cursor :void
(tree-view g-object)
- (path (g-boxed-ref tree-path))
+ (path (g-boxed-foreign tree-path))
(focus-column g-object)
(start-editing :boolean))
(defcfun gtk-tree-view-set-cursor-on-cell :void
(tree-view g-object)
- (path (g-boxed-ref tree-path))
+ (path (g-boxed-foreign tree-path))
(focus-column g-object)
(focus-cell g-object)
(start-editing :boolean))
(defun tree-view-get-cursor (tree-view)
(with-foreign-objects ((path :pointer) (focus-column :pointer))
(gtk-tree-view-get-cursor tree-view path focus-column)
- (values (mem-ref path '(g-boxed-ref tree-path :owner :lisp))
+ (values (mem-ref path '(g-boxed-foreign tree-path :return))
(mem-ref focus-column 'g-object))))
(export 'tree-view-get-cursor)
(defcfun (tree-view-expand-to-path "gtk_tree_view_expand_to_path") :void
(tree-view g-object)
- (path (g-boxed-ref tree-path)))
+ (path (g-boxed-foreign tree-path)))
(export 'tree-view-expand-to-path)
(defcfun (tree-view-expand-row "gtk_tree_view_expand_row") :boolean
(tree-view g-object)
- (path (g-boxed-ref tree-path)))
+ (path (g-boxed-foreign tree-path)))
(export 'tree-view-expand-row)
(defcfun (tree-view-collapse-row "gtk_tree_view_collapse_row") :boolean
(tree-view g-object)
- (path (g-boxed-ref tree-path)))
+ (path (g-boxed-foreign tree-path)))
(export 'tree-view-collapse-row)
(defcallback gtk-tree-view-mapping-func-callback :void
- ((tree-view g-object) (path (g-boxed-ref tree-path)) (data :pointer))
+ ((tree-view g-object) (path (g-boxed-foreign tree-path)) (data :pointer))
(funcall (get-stable-pointer-value data)
tree-view path))
(defcfun (tree-view-row-expanded-p "gtk_tree_view_row_expanded") :boolean
(tree-view g-object)
- (path (g-boxed-ref tree-path)))
+ (path (g-boxed-foreign tree-path)))
(export 'tree-view-row-expanded-p)
(defun tree-view-get-path-at-pos (tree-view x y)
(with-foreign-objects ((path :pointer) (column :pointer) (cell-x :int) (cell-y :int))
(when (gtk-tree-view-get-path-at-pos tree-view x y path column cell-x cell-y)
- (values (mem-ref path '(g-boxed-ref tree-path :owner :lisp))
+ (values (mem-ref path '(g-boxed-foreign tree-path :return))
(mem-ref column 'g-object)
(mem-ref cell-x :int)
(mem-ref cell-y :int)))))
(defcfun gtk-tree-view-get-cell-area :void
(tree-view g-object)
- (path (g-boxed-ref tree-path))
+ (path (g-boxed-foreign tree-path))
(column g-object)
- (rectangle (g-boxed-ptr rectangle)))
+ (rectangle (g-boxed-foreign rectangle)))
(defun tree-view-get-cell-area (tree-view path column)
(let ((rect (make-rectangle :x 0 :y 0 :width 0 :height 0)))
(defcfun gtk-tree-view-get-background-area :void
(tree-view g-object)
- (path (g-boxed-ref tree-path))
+ (path (g-boxed-foreign tree-path))
(column g-object)
- (rectangle (g-boxed-ptr rectangle)))
+ (rectangle (g-boxed-foreign rectangle)))
(defun tree-view-get-background-area (tree-view path column)
(let ((rect (make-rectangle :x 0 :y 0 :width 0 :height 0)))
(defcfun gtk-tree-view-get-visible-rect :void
(tree-view g-object)
- (rectangle (g-boxed-ptr rectangle)))
+ (rectangle (g-boxed-foreign rectangle)))
(defun tree-view-get-visible-rect (tree-view)
(let ((rect (make-rectangle :x 0 :y 0 :width 0 :height 0)))
(defun tree-view-get-visible-range (tree-view)
(with-foreign-objects ((start-path :pointer) (end-path :pointer))
(when (gtk-tree-view-get-visible-range tree-view start-path end-path)
- (values (mem-ref start-path '(g-boxed-ref tree-path :owner :lisp))
- (mem-ref end-path '(g-boxed-ref tree-path :owner :lisp))))))
+ (values (mem-ref start-path '(g-boxed-foreign tree-path :return))
+ (mem-ref end-path '(g-boxed-foreign tree-path :return))))))
(export 'tree-view-get-visible-range)
; TOOD: gtk_tree_view_create_drag_icon
(defcallback gtk-tree-view-search-equal-func-callback :boolean
- ((model g-object) (column :int) (key (:string :free-from-foreign nil)) (iter (g-boxed-ref tree-iter)) (data :pointer))
+ ((model g-object) (column :int) (key (:string :free-from-foreign nil)) (iter (g-boxed-foreign tree-iter)) (data :pointer))
(restart-case
(funcall (get-stable-pointer-value data)
model column key iter)
; TODO: gtk_tree_view_set_destroy_count_func
(defcallback gtk-tree-view-row-separator-func-callback :boolean
- ((tree-model g-object) (iter (g-boxed-ref tree-iter)) (data :pointer))
+ ((tree-model g-object) (iter (g-boxed-foreign tree-iter)) (data :pointer))
(restart-case
(funcall (get-stable-pointer-value data)
tree-model
(defcfun (tree-view-set-tooltip-row "gtk_tree_view_set_tooltip_row") :void
(tree-view g-object)
(tooltip g-object)
- (tree-path (g-boxed-ref tree-path)))
+ (tree-path (g-boxed-foreign tree-path)))
(export 'tree-view-set-tooltip-row)
(defcfun (tree-view-set-tooltip-cell "gtk_tree_view_set_tooltip_cell") :void
(tree-view g-object)
(tooltip g-object)
- (path (g-boxed-ref tree-path))
+ (path (g-boxed-foreign tree-path))
(column g-object)
(cell g-object))
(mem-ref y :int)
(mem-ref keyboard-tip :boolean)
(mem-ref model 'g-object)
- (mem-ref path '(g-boxed-ref tree-path :owner :lisp))
- (mem-ref iter '(g-boxed-ref tree-iter :owner :lisp))))))
+ (mem-ref path '(g-boxed-foreign tree-path :return))
+ (mem-ref iter '(g-boxed-foreign tree-iter :return))))))
(export 'tree-view-get-tooltip-context)
(defcfun gtk-widget-intersect :boolean
(widget g-object)
- (area (g-boxed-ptr rectangle))
- (intersection (g-boxed-ptr rectangle :in-out)))
+ (area (g-boxed-foreign rectangle))
+ (intersection (g-boxed-foreign rectangle :in-out)))
(defun widget-intersect (widget rectangle)
(let ((result (make-rectangle :x 0 :y 0 :width 0 :height 0)))
(class (g-type-class-ref type)))
(unwind-protect
(let ((g-param-spec (gtk-widget-class-find-style-property class property-name)))
- (unless g-param-spec (error "Widget ~A has no style-property named '~A'" widget property-name))
+ (when (null-pointer-p g-param-spec) (error "Widget ~A has no style-property named '~A'" widget property-name))
(foreign-slot-value g-param-spec 'gobject:g-param-spec :value-type))
(g-type-class-unref class))))
(defcfun gtk-widget-get-snapshot g-object
(widget g-object)
- (clip-rectangle (g-boxed-ptr rectangle)))
+ (clip-rectangle (g-boxed-foreign rectangle)))
(defun widget-snapshot (widget &optional clip-rectangle)
(gtk-widget-get-snapshot widget clip-rectangle))
(defcfun (window-set-geometry-hints "gtk_window_set_geometry_hints") :void
(window (g-object gtk-window))
(geometry-widget (g-object widget))
- (geometry geometry)
+ (geometry (g-boxed-foreign geometry))
(geometry-mask window-hints))
(export 'window-set-geometry-hints)
(defcfun (window-activate-key "gtk_window_activate_key") :boolean
(window (g-object gtk-window))
- (event (g-boxed-ptr event-key)))
+ (event (g-boxed-foreign event)))
(export 'window-activate-key)
(defcfun (window-propagate-key-event "gtk_window_propagate_key_event") :boolean
(window (g-object gtk-window))
- (event (g-boxed-ptr event-key)))
+ (event (g-boxed-foreign event)))
(export 'window-propagate-key-event)