pythonware.com products ::: library ::: search ::: daily Python-URL!
   

Tkinter Text Widget Options

Back    Next   

Text Widget Configuration Options

The Text widget supports the following configuration options to control appearance and behavior.

Table 42-5. Text Options

Option

Type

Description

background (bg)

color

The background color for this widget. Default is system specific (usually "white").

borderwidth (bd)

distance

Border width. Default is platform dependent, usually one or two pixels.

cursor

cursor

The cursor to show when the mouse pointer is over the widget. Default is the "I beam" text insertion cursor.

exportselection

flag

If true, selected text is automatically exported to the clipboard. Default is true.

font

font

Widget font configuration. The default is system specific.

foreground (fg)

color

The color used for the text.

height

distance

Widget height, measured in text units (rows).

highlightcolor

color

Color used for the focus highlight border when the widget has focus.

relief

constant

Border decoration. Options: SUNKEN, FLAT, RAISED, GROOVE, RIDGE.

state

constant

Set to NORMAL or DISABLED. Default is NORMAL.

wrap

constant

Word wrap mode: NONE, CHAR, or WORD. Default is NONE.

Back    Next