O'Reilly logo

Practical Programming in Tcl and Tk, Fourth Edition by Brent Welch, Ken Jones

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 36. The Text Widget

Tk text widget is a general-purpose editable text widget with features for line spacing, justification, tags, marks, and embedded windows.

The Tk text widget is versatile, simple to use for basic text display and manipulation, and has many advanced features to support sophisticated applications. The line spacing and justification can be controlled on a line-by-line basis. Fonts, sizes, and colors are controlled with tags that apply to ranges of text. Edit operations use positional marks that keep track of locations in text, even as text is inserted and deleted.

Tags are the most important feature of the text widget. You can define attributes like font and justification for a tag. When that tag is applied to a range of ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required