From: espen Date: Thu, 5 Jul 2007 11:34:27 +0000 (+0000) Subject: Added bindings to GtkAssistant X-Git-Url: https://git.distorted.org.uk/~mdw/clg/commitdiff_plain/7d2f9e31f958431da7dc2ab4ce7091747ad96510 Added bindings to GtkAssistant --- diff --git a/gtk/gtk.lisp b/gtk/gtk.lisp index 327a5f7..16b6530 100644 --- a/gtk/gtk.lisp +++ b/gtk/gtk.lisp @@ -20,7 +20,7 @@ ;; TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE ;; SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -;; $Id: gtk.lisp,v 1.76 2007-06-25 10:36:43 espen Exp $ +;; $Id: gtk.lisp,v 1.77 2007-07-05 11:34:27 espen Exp $ (in-package "GTK") @@ -521,6 +521,56 @@ (right unsigned-int)) +;;; Assistant + +#?(pkg-exists-p "gtk+-2.0" :atleast-version "2.10.0") +(progn + (defbinding assistant-get-nth-page () widget + (assistant assistant) + (page-num int)) + + (defbinding %assistant-insert-page () int + (assistant assistant) + (page widget) + (pos int)) + + (defun assistant-insert-page (assistant page position &rest child-args) + (let ((pos (case position + (:first 0) + (:last -1) + (t position)))) + (prog1 + (%assistant-insert-page assistant page pos) + (init-child-slots assistant page child-args)))) + + (defun assistant-append-page (assistant page &rest child-args) + (apply #'assistant-insert-page assistant page :last child-args)) + + (defun assistant-prepend-page (assistant page &rest child-args) + (apply #'assistant-insert-page assistant page :first child-args)) + + (define-callback-marshal %assistant-page-func-callback int + ((current-page int))) + + (defbinding assistant-set-forward-func (assistant function) nil + (assistant assistant) + (%assistant-page-func-callback callback) + ((register-callback-function function) pointer-data) + (user-data-destroy-callback callback)) + + (defbinding assistant-add-action-widget () nil + (assistant assistant) + (child widget)) + + (defbinding assistant-remove-action-widget () nil + (assistant assistant) + (child widget)) + + (defbinding assistant-update-buttons-state () nil + (assistant assistant))) + + + ;;; Aspect frame diff --git a/gtk/gtktypes.lisp b/gtk/gtktypes.lisp index 14d4f9a..64caa0c 100644 --- a/gtk/gtktypes.lisp +++ b/gtk/gtktypes.lisp @@ -20,7 +20,7 @@ ;; TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE ;; SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -;; $Id: gtktypes.lisp,v 1.54 2007-05-10 20:21:25 espen Exp $ +;; $Id: gtktypes.lisp,v 1.55 2007-07-05 11:34:27 espen Exp $ (in-package "GTK") @@ -1072,6 +1072,22 @@ :initarg :pixbuf-column :accessor icon-view-pixbuf-column))) + #?(pkg-exists-p "gtk+-2.0" :atleast-version "2.10.0") + ("GtkAssistant" + :slots + ((current-page + :allocation :virtual + :getter "gtk_assistant_get_current_page" + :setter "gtk_assistant_set_current_page" + :accessor assistant-current-page + :type int) + (num-pages + :allocation :virtual + :getter "gtk_assistant_get_n_page" + :reader assistant-current-page + :type int))) + + ;; Not needed ("GtkFundamentalType" :ignore t) ("GtkArgFlags" :ignore t)