;;;; ;;;; L e n t r y . s t k -- Labeled Entry composite widget ;;;; ;;;; Copyright © 1993-1998 Erick Gallesio - I3S-CNRS/ESSI ;;;; ;;;; Permission to use, copy, and/or distribute this software and its ;;;; documentation for any purpose and without fee is hereby granted, provided ;;;; that both the above copyright notice and this permission notice appear in ;;;; all copies and derived works. Fees for distribution or use of this ;;;; software or derived works may only be charged with express written ;;;; permission of the copyright holder. ;;;; This software is provided ``as is'' without express or implied warranty. ;;;; ;;;; $Id: Lentry.stklos 1.4 Wed, 04 Feb 1998 10:34:59 +0000 eg $ ;;;; ;;;; Author: Erick Gallesio [eg@kaolin.unice.fr] ;;;; Creation date: 22-Mar-1994 13:05 ;;;; Last file update: 3-Feb-1998 19:15 (require "Basics") (select-module STklos+Tk) ;============================================================================= ; ; ; ;============================================================================= ;; ;; Resources ;; (option 'add "*LabeledEntry.Entry.Background" "white" "widgetDefault") (option 'add "*LabeledEntry.Entry.Font" "fixed" "widgetDefault") (option 'add "*LabeledEntry.Entry.Relief" "sunken" "widgetDefault") ;; ;; Class definition ;; (define-class ( ) ((entry :accessor entry-of) (label :accessor label-of) (class :init-keyword :class :init-form "LabeledEntry") ;; Fictive slots (title :accessor title :init-keyword :title :allocation :propagated :propagate-to ((label text))) (title-width :accessor title-width :init-keyword :title-width :allocation :propagated :propagate-to ((label width))) (title-anchor :accessor title-anchor :init-keyword :title-anchor :allocation :propagated :propagate-to ((label anchor))) (anchor :accessor anchor :init-keyword :anchor :allocation :propagated :propagate-to (label)) (background :accessor background :init-keyword :background :allocation :propagated :propagate-to (frame entry label)) (foreground :accessor foreground :init-keyword :foreground :allocation :propagated :propagate-to (entry label)) (border-width :accessor border-width :allocation :propagated :init-keyword :border-width :propagate-to (frame)) (relief :accessor relief :init-keyword :relief :allocation :propagated :propagate-to (frame)) (entry-relief :accessor entry-relief :init-keyword :entry-relief :allocation :propagated :propagate-to ((entry relief))) )) (define-method initialize-composite-widget ((self ) initargs frame) (let* ((e (make :parent frame)) (l (make