Next / Previous / Contents / TCC Help System / NM Tech homepage

20.1. Class constants

These class variables contain constants used to configure the widget.

SWATCH_TEXT is the sample text that appears in the swatch initially.

huey
    SWATCH_TEXT  =  (
        "The quick brown fox jumps over\n"
        "the lazy dog.\n"
        "ABCDEFGHIJKLMNOPQRSTUVWXYZ\n"
        "abcdefghijklmnopqrstuvwxyz\n"
        "0123456789 !\"#$%&'()*+,-./\n"
        ":;<=>?@[\\]^_/{|}~" )

These two constants specify the width in characters of the Text widget, and its height in lines.

huey
    SWATCH_WIDE  =  40        # Width of the color swatch in characters
    SWATCH_HIGH  =  8         # Height of the color swatch in lines

The next constant specifies the number of font family names that will be visible at once in the font selector widget.

huey
    FONT_FAMILIES  =  15