ClassPackage: cgToCDocOverviewCGDocRelNotesFAQIndexPermutedIndex
Allegro CL version 10.1
Unrevised from 10.0 to 10.1.
10.0 version


This class is used to specify the style in which one of the cell types of a calendar widget is drawn. A calendar widget will create the instances of this class that it needs by default, though an application can completely replace a default style by creating a cell-style instance and passing it when creating the calendar widget. Alternately, an application can modify any of the existing cell-style instances of a calendar widget after the widget has been created.

The various cell-styles used by a calendar instance are accessed with the generic functions cell-style, cell-style-selected, cell-style-under-mouse, cell-style-current-date, and cell-style-other-month.

A cell-style has the properties background-color, foreground-color, border-color, border-width, and bold-text. Here are examples of the two alternate ways to specify a custom cell style.

;; Make a calendar widget, and then modify its built-in cell-style
;; for the date that's under the mouse to have blue text.
(let* ((calendar (make-instance 'calendar)))
  (setf (foreground-color (cell-style-under-mouse calendar)) blue)

;; Create a calendar widget with a custom cell-style object
;; for the date that's currently under the mouse.
(make-instance 'calendar
  (make-instance 'cell-style
    :foreground-color (make-rgb :red 0 :green 128 :blue 192)
    :background-color light-gray   ;; nil means no background
    :border-color dark-blue
    :border-width 2                ;; nil or zero means no border
    :bold-text t))    

Copyright (c) 1998-2017, Franz Inc. Oakland, CA., USA. All rights reserved.
This page was not revised from the 10.0 page.
Created 2017.2.15.

Allegro CL version 10.1
Unrevised from 10.0 to 10.1.
10.0 version