NextPrevUpTopContentsIndex

10.3.1 Extended Stream Pane Options

CLIM extended stream panes accept the :foreground , :background , and :text-style options as well as those options applicable to layout panes. The space requirement options ( :width , :height , and so forth) can also take a size specification of :compute , which causes CLIM to run the display function for the pane and make the pane large enough to hold the output of the display function.

In addition to those listed previously, CLIM extended stream frames accept the following options:

:display-after-commands 

Summary: This specifies how the display function will be run. If t , the "print" part of the read-eval-print loop runs the display function; this is the default for most pane types. If nil , you are responsible for implementing the display after commands.

Do not use :display-after-commands with accept-values panes, as the redisplay for those panes is managed at a slightly lower level for efficiency. Avoid code such as the following:

        (in-package :clim-user)
        
        (define-application-frame test-frame () () 
          (:command-table (test-frame :inherit-from 
                                      (clim:accept-values-pane)))
          (:command-definer t)
          (:panes 
           (test-input-pane :accept-values :display-function 
                            '(clim:accept-values-pane-displayer
                              :displayer test-input)
                            ;; THIS WILL NOT WORK
                            :display-after-commands t)
           (dummy :application)
           (menu :command-menu
                 :display-function '(display-command-menu :n-rows 1))
           (mouse :pointer-documentation))
          (:layouts (:default
                     (vertically () 
                                 menu test-input-pane DUMMY mouse))))
        (defmethod test-input ((frame test-frame) stream)
          (accept 'integer :stream stream :prompt "prompt" :default 1)
          (terpri stream)
          (accept 'integer :stream stream :prompt "foo" :default 1)
          (terpri stream))
        
        (defun test-it (&key (port (find-port)))
          (run-frame-top-level 
           (make-application-frame 'test-frame
                                   :frame-manager
                                   (find-frame-manager :port port))))
:display-function 

Summary: This specifies a function to be called in order to display the contents of a CLIM stream pane. CLIM's default top-level function, default-frame-top-level , will invoke the pane's display function at the appropriate time (see the :display-time option). The value of this option is either the name of a function to invoke, or a cons whose car is the name of a function and whose cdr is additional arguments to the function. The function will be invoked on the frame, the pane, and the additional function arguments, if any. The default for this option is nil .

:display-time 

Summary: This tells CLIM when the pane's display function should be run. If it is :command-loop , CLIM erases the pane's contents and runs the display function after each time a frame command is executed. If it is t , the pane is displayed once but not again until pane-needs-redisplay is called on the pane. If it is nil , CLIM waits until it is explicitly requested, either via pane-needs-redisplay or redisplay-frame-pane . The default value varies according to the pane type.

:display-string 

Summary: For title-pane s only, you can use this option instead of :display-function to specify a constant string to be displayed in the title-pane .

:incremental-redisplay 

Summary: When t , the redisplay function will initially be executed inside of an invocation to updating-output and the resulting output record will be saved. Subsequent calls to redisplay-frame-pane will simply use redisplay to redisplay the pane. The default for this option is nil .

:text-margin 

Summary: This specifies the default text margin, that is, how much space is left around the inside edge of the pane. The default for :text-margin is the width of the window.

:vertical-spacing 

Summary: This specifies the default vertical spacing for the pane, that is, how much space there is between each text line. The default for :vertical-spacing is 2.

:end-of-line-action 

Summary: This specifies the end-of-line action to be used. The default is :wrap . (The other possible value is :allow .)

:end-of-page-action 

Summary: This specifies the end-of-page action to be used. The default is :scroll . (The other possible value is :allow .)

:output-record 

Summary: This names the output record class to be used for the output history of the pane. The default is standard-tree-output-history .

:draw 
:record 

Summary: These options specify whether the pane should initially allow drawing and output recording, respectively. The default for both options is t .


CommonLisp Interface Manager 2.0 User's Guide - 30 Jul 2004

NextPrevUpTopContentsIndex