25. Selection and the Clipboard
The selection is a mechanism for passing information between widgets and applications. The user first selects one or more objects in a widget, for example, by dragging the mouse across a range of text or clicking on a graphical object. Once a selection has been made, the user can invoke commands in other widgets to retrieve information about the selection, such as the characters in the selected range or the name of the file containing the selection. In today’s windowing environments there are two different selection models, the selection owner model and the clipboard model.
The selection owner model is used in the X Window System. There is a single owner of the selection at any given time. The widget containing ...
Get Tcl and the Tk Toolkit, Second Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.