Interactive Tablelist Cell Editing Using tile Widgets

by

Csaba Nemethi

csaba.nemethi@t-online.de

Contents

Start page


Overview

The tile theme engine is a compiled library extension for Tcl/Tk version 8.4 or higher.  Beginning with Tk 8.5a6, tile is integrated into the Tk core.  For earlier Tk versions it can be downloaded from the address

http://sourceforge.net/projects/tktable/

Tablelist supports interactive cell editing with the aid of the tile entry, combobox, and checkbutton widgets, accessed as ttk::entry, ttk::combobox, and ttk::checkbutton, respectively.  The version of the tile package must be 0.6 or higher.  Due to the rapidly growing strategic importance of the tile library, these widgets are automatically registered for cell editing, hence the only action needed for using one of them for editing the cells of a given column is as follows:

Use the tablelist widget's columnconfigure subcommand to set the given column's -editable option to true and its -editwindow option to ttk::entry, ttk::combobox, or ttk::checkbutton, respectively.  (These options are supported at cell level, too, with the aid of the cellconfigure subcommand.)

One known limitation of the currently available tile versions is that the  style theme use  command can only be used to set the current theme, but not to retrieve it.  For this reason, Tablelist makes use of the variable ttk::currentTheme or tile::currentTheme (depending on the tile version), which is set by the ttk::setTheme or tile::setTheme procedure.  From this it follows that the tile widgets used for interactive cell editing will only be managed as expected if the platform-specific default theme is either left unchanged or replaced with another theme by invoking the procedure ttk::currentTheme or tile::setTheme, depending on the current tile version.  (See also the tablelist::setTheme command.)

Contents     Start page


Interactive Cell Editing Using the tile entry Widget

DESCRIPTION
The temporary embedded tile entry widget used for interactive cell editing will be created with an explicitly set value for its -style option.  Apart from its theme-specific appearance, it behaves just like its Tk core counterpart.

If an application uses the tile entry widget for interactive cell editing and also the Wcb package (even if not for that widget), then the version of Wcb must be 3.1 or higher (because earlier Wcb releases didn't support any tile widgets).

KEYWORDS
tablelist, editing, tile, entry

Contents     Start page


Interactive Cell Editing Using the tile combobox Widget

DESCRIPTION
The temporary embedded tile combobox widget used for interactive cell editing will be created with an explicitly set value for its -style option and with its -state option set to normal, which makes the widget editable.  You can use the script corresponding to the -editstartcommand tablelist configuration option to set the state of the combobox to readonly or define validations for it, as well as for populating its listbox component (with the aid of the combobox widget's -values option).

If an application uses the tile combobox widget for interactive cell editing and also the Wcb package (even if not for that widget), then the version of Wcb must be 3.1 or higher (because earlier Wcb releases didn't support any tile widgets).

KEYWORDS
tablelist, editing, tile, combobox

Contents     Start page


Interactive Cell Editing Using the tile checkbutton Widget.

DESCRIPTION
The temporary embedded tile checkbutton widget used for interactive cell editing will be created with explicitly set values for its -style and -variable options.  You can use the script corresponding to the -editstartcommand tablelist configuration option to set any other configuration options, like -offvalue and -onvalue, according to the internal values of the cells.  Since the default values of the -offvalue and -onvalue tile checkbutton options are 0 and 1, you don't need to change these options if the cells have the same internal values 0 and 1.

KEYWORDS
tablelist, editing, tile, checkbutton

Contents     Start page