HList — Hierarchical List
This widget is part of the Tix distribution and is supported by Perl/Tk just like any other Tk widget. Table A.14 shows the properties.
Table A-14. HList Methods and Properties
|
Properties |
Description |
|---|---|
|
command |
Specifies a reference to a Perl subroutine, which is called when an entry is double clicked upon. |
|
drawbranch |
If true, draws lines connecting parent and children and sibling entries. |
|
browsecmd |
Called whenever any mouse click or drag event happens over an entry. |
|
columns |
Each level of indentation is a column. Column sizes can be individually tailored. |
|
separator |
The separator character. Defaults to “.” |
|
selectmode |
|
|
indent |
Indent amount for each successive level, in pixels. |
|
Methods | |
|
add (entrypath, option, values) |
Creates a new entry. The options can be at position, before path, after path, and all the entry properties discussed below. |
|
delete (option, entrypath) |
Option can be |
|
column (col, width) column (col, `char', nchars) |
Set the width in pixels or in terms of character widths. |
|
entryconfigure, entrycget |
Set/get the entry properties discussed below. |
|
info (option, entryPath) |
Option can be |
|
hide, show |
Hide or show an entry |
|
Entry Properties | |
|
`itemtype’ |
|
|
`text’ |
The label of that entry. |
|
`image’ |
A bitmap or a pixmap. Used if itemtype is
|
Note that this ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access