From c7066267e3baedd05b2a394f5b2dbdf2246278c7 Mon Sep 17 00:00:00 2001 From: Dmitry Kalyanov Date: Tue, 12 May 2009 17:33:54 +0400 Subject: [PATCH] Change gtk-demo:test-notebook --- gtk/gtk.demo.lisp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/gtk/gtk.demo.lisp b/gtk/gtk.demo.lisp index 8c52342..57f38b1 100644 --- a/gtk/gtk.demo.lisp +++ b/gtk/gtk.demo.lisp @@ -456,7 +456,15 @@ (iter (for i from 0 to 5) (for page = (make-instance 'label :label (format nil "Label for page ~A" i))) (for tab-label = (make-instance 'label :label (format nil "Tab ~A" i))) - (for tab-button = (make-instance 'button :use-stock t :label "gtk-close" :relief :none)) + (for tab-button = (make-instance 'button + :image (make-instance 'image :stock "gtk-close" :icon-size 1) + :relief :none)) + (g-signal-connect tab-button "clicked" + (let ((page page)) + (lambda (button) + (declare (ignore button)) + (format t "Removing page ~A~%" page) + (notebook-remove-page notebook page)))) (for tab-hbox = (make-instance 'h-box)) (box-pack-start tab-hbox tab-label) (box-pack-start tab-hbox tab-button) -- 1.7.10.4