;;;;
;;;; checkbutton.stk            -- GTklos check-button
;;;;
;;;; Copyright © 2001-2021 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;;
;;;; This program is free software; you can redistribute it and/or modify
;;;; it under the terms of the GNU General Public License as published by
;;;; the Free Software Foundation; either version 2 of the License, or
;;;; (at your option) any later version.
;;;;
;;;; This program is distributed in the hope that it will be useful,
;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
;;;; GNU General Public License for more details.
;;;;
;;;; You should have received a copy of the GNU General Public License
;;;; along with this program; if not, write to the Free Software
;;;; Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
;;;; USA.
;;;;
;;;;           Author: Erick Gallesio [eg@unice.fr]
;;;;    Creation date: 10-Jul-2001 07:30 (eg)
;;;;

;;;
;;; GTK bindings
;;;

(define-gtk gtk-check-button-new-with-mnemonic (#:string) #:pointer
  "gtk_check_button_new_with_mnemonic")

;======================================================================
;
;           C l a s s   < c h e c k b u t t o n >
;
;======================================================================

(define-class <check-button> (<button>)
  ((value #:accessor     value
          #:init-keyword #:value
          #:allocation   #:gtk-property
          #:gtk-name     "active")))

(define-method realize-widget ((self <check-button>) initargs)
  (let ((cb (gtk-check-button-new-with-mnemonic "")))
    (cpointer-type-set! cb 'gtk-check-button)
    (slot-set! self 'wid cb)))

;;;
;;; Exports
;;;
(export <check-button> value)
