[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Setting the background color for a checkbox?

At  3:44 PM 6/9/94 -0400, Andrew Newell Mickish wrote:
>I'm not sure if this example can be extended to checkboxes, but I have
>been using it very successfully for keeping views different colors from
>their containing views.

I have not tried Andrew's fix.
Check box dialog items use the window's :content color.
Hence, the following code will produce a window with a red background
and a checkbox whose background is also red:

  (let ((w (make-instance 'window
             :color-p t
             :window-show nil))
        (b (make-instance 'check-box-dialog-item
             :dialog-item-text "Check Box")))
    (set-part-color w :content *red-color*)
    (set-part-color b :frame *blue-color*)
    (set-part-color b :text *green-color*)
    (set-view-container b w)
    (window-show w))