Tk Library Source Code

Check-in [7b2ef697b7]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment: * *.tcl: Bumped the version number to 5.17. * COPYRIGHT.txt: * README.txt: * ../../examples/*.tcl:
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 7b2ef697b75581ac8ae49672fcd32eb315a3528d
User & Date: csaba 2017-03-22 13:02:59
Context
2017-03-22
13:03
* CHANGES.txt: Updated to reflect the changes. * doc/*.html: check-in: 1e5f771358 user: csaba tags: trunk
13:02
* *.tcl: Bumped the version number to 5.17. * COPYRIGHT.txt: * README.txt: * ../../examples/*.tcl: check-in: 7b2ef697b7 user: csaba tags: trunk
13:01
* *.tcl: Bumped the version number to 5.17. * COPYRIGHT.txt: * README.txt: * ../../examples/*.tcl: * CHANGES.txt: Updated to reflect the changes. * doc/*.html: * scripts/*.tcl: Added the tree styles "arc", "blueMenta", "menta", "ubuntuMate", and "ubuntu3"; added the "dicttoitem" and "itemtodict" subcommands; added support for the virtual event <<TablelistViewUpdated>>; added bindings for toggling the selection state of individual items and elements; added support for the keyboard shortcuts <Control-a> and <Shift-Control-A> as alternatives to <Control-slash> and <Control-backslash>; improvements related to vertical scrolling. * scripts/tclIndex: Newly generated. * doc/arc.png: Added screenshots. * doc/blueMenta.png: * doc/menta.png: * doc/ubuntuMate.png: * doc/ubuntu3.png: * doc/*.png: Updated screenshots. check-in: 6c4771ff77 user: csaba tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to modules/tablelist/COPYRIGHT.txt.

1
2
3
4
5
6
7
8
9
Multi-column listbox and tree widget package Tablelist, version 5.16
Copyright (c) 2000-2016  Csaba Nemethi (E-mail: [email protected])

This library is free software; you can use, modify, and redistribute it
for any purpose, provided that existing copyright notices are retained
in all copies and that this notice is included verbatim in any
distributions.

This software is distributed WITHOUT ANY WARRANTY; without even the
|
|







1
2
3
4
5
6
7
8
9
Multi-column listbox and tree widget package Tablelist, version 5.17
Copyright (c) 2000-2017  Csaba Nemethi (E-mail: [email protected])

This library is free software; you can use, modify, and redistribute it
for any purpose, provided that existing copyright notices are retained
in all copies and that this notice is included verbatim in any
distributions.

This software is distributed WITHOUT ANY WARRANTY; without even the

Changes to modules/tablelist/README.txt.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
       The Multi-Column Listbox and Tree Widget Package Tablelist

                                   by

                             Csaba Nemethi

                       [email protected] 


What is Tablelist?
------------------

Tablelist is a library package for Tcl/Tk versions 8.0 or higher,
written in pure Tcl/Tk code.  It contains:

  - the implementation of the "tablelist" mega-widget, including a
    general utility module for mega-widgets;









|







1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
       The Multi-Column Listbox and Tree Widget Package Tablelist

                                   by

                             Csaba Nemethi

                       [email protected] 


What Is Tablelist?
------------------

Tablelist is a library package for Tcl/Tk versions 8.0 or higher,
written in pure Tcl/Tk code.  It contains:

  - the implementation of the "tablelist" mega-widget, including a
    general utility module for mega-widgets;
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
for the "activate", "selection set", and "selection clear" commands,
and Wcb version 3.0 or higher also supports callbacks for the
"activatecell", "cellselection set", and "cellselection clear"
commands.  The download location of Wcb is

    http://www.nemethi.de

How to get it?
--------------

Tablelist is available for free download from the same URL as Wcb.  The
distribution file is "tablelist5.16.tar.gz" for UNIX and
"tablelist5_16.zip" for Windows.  These files contain the same
information, except for the additional carriage return character
preceding the linefeed at the end of each line in the text files for
Windows.

Tablelist is also included in tklib, which has the address

    http://core.tcl.tk/tklib

How to install it?
------------------

Install the package as a subdirectory of one of the directories given
by the "auto_path" variable.  For example, you can install it as a
directory at the same level as the Tcl and Tk script libraries.  The
locations of these library directories are given by the "tcl_library"
and "tk_library" variables, respectively.

To install Tablelist on UNIX, "cd" to the desired directory and unpack
the distribution file "tablelist5.16.tar.gz":

    gunzip -c tablelist5.16.tar.gz | tar -xf -

This command will create a directory named "tablelist5.16", with the
subdirectories "demos", "doc", and "scripts".

On Windows, use WinZip or some other program capable of unpacking the
distribution file "tablelist5_16.zip" into the directory
"tablelist5.16", with the subdirectories "demos", "doc", and "scripts".

The file "tablelistEdit.tcl" in the "scripts" directory is only needed
for applications making use of interactive cell editing.  Similarly, the
file "tablelistMove.tcl" in the same directory is only required for
scripts invoking the "move" or "movecolumn" tablelist command.  Finally,
the file "tablelistThemes.tcl" is only needed for applications using
the package Tablelist_tile (see next section).

Next, you should check the exact version number of your Tcl/Tk
distribution, given by the "tcl_patchLevel" and "tk_patchLevel"
variables.  If you are using Tcl/Tk version 8.2.X, 8.3.0 - 8.3.2, or
8.4a1, then you should proceed as described in the "How to install it?"
section of the file "tablelist.html", located in the "doc" directory.

How to use it?
--------------

The Tablelist distribution provides two packages, called Tablelist and
Tablelist_tile.  The main difference between the two is that
Tablelist_tile enables the tile-based, theme-specific appearance of
tablelist widgets; this package requires Tcl/Tk 8.4 or higher and tile
0.6 or higher.  It is not possible to use both packages in one and the







|



|
|








|









|

|

|



|
|











|


|







80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
for the "activate", "selection set", and "selection clear" commands,
and Wcb version 3.0 or higher also supports callbacks for the
"activatecell", "cellselection set", and "cellselection clear"
commands.  The download location of Wcb is

    http://www.nemethi.de

How to Get It?
--------------

Tablelist is available for free download from the same URL as Wcb.  The
distribution file is "tablelist5.17.tar.gz" for UNIX and
"tablelist5_17.zip" for Windows.  These files contain the same
information, except for the additional carriage return character
preceding the linefeed at the end of each line in the text files for
Windows.

Tablelist is also included in tklib, which has the address

    http://core.tcl.tk/tklib

How to Install It?
------------------

Install the package as a subdirectory of one of the directories given
by the "auto_path" variable.  For example, you can install it as a
directory at the same level as the Tcl and Tk script libraries.  The
locations of these library directories are given by the "tcl_library"
and "tk_library" variables, respectively.

To install Tablelist on UNIX, "cd" to the desired directory and unpack
the distribution file "tablelist5.17.tar.gz":

    gunzip -c tablelist5.17.tar.gz | tar -xf -

This command will create a directory named "tablelist5.17", with the
subdirectories "demos", "doc", and "scripts".

On Windows, use WinZip or some other program capable of unpacking the
distribution file "tablelist5_17.zip" into the directory
"tablelist5.17", with the subdirectories "demos", "doc", and "scripts".

The file "tablelistEdit.tcl" in the "scripts" directory is only needed
for applications making use of interactive cell editing.  Similarly, the
file "tablelistMove.tcl" in the same directory is only required for
scripts invoking the "move" or "movecolumn" tablelist command.  Finally,
the file "tablelistThemes.tcl" is only needed for applications using
the package Tablelist_tile (see next section).

Next, you should check the exact version number of your Tcl/Tk
distribution, given by the "tcl_patchLevel" and "tk_patchLevel"
variables.  If you are using Tcl/Tk version 8.2.X, 8.3.0 - 8.3.2, or
8.4a1, then you should proceed as described in the "How to Install It?"
section of the file "tablelist.html", located in the "doc" directory.

How to Use It?
--------------

The Tablelist distribution provides two packages, called Tablelist and
Tablelist_tile.  The main difference between the two is that
Tablelist_tile enables the tile-based, theme-specific appearance of
tablelist widgets; this package requires Tcl/Tk 8.4 or higher and tile
0.6 or higher.  It is not possible to use both packages in one and the

Changes to modules/tablelist/pkgIndex.tcl.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#==============================================================================
# Tablelist and Tablelist_tile package index file.
#
# Copyright (c) 2000-2016  Csaba Nemethi (E-mail: [email protected])
#==============================================================================

#
# Regular packages:
#
package ifneeded tablelist         5.16 \
	[list source [file join $dir tablelist.tcl]]
package ifneeded tablelist_tile    5.16 \
	[list source [file join $dir tablelist_tile.tcl]]

#
# Aliases:
#
package ifneeded Tablelist         5.16 \
	[list package require -exact tablelist	    5.16]
package ifneeded Tablelist_tile    5.16 \
	[list package require -exact tablelist_tile 5.16]

#
# Code common to all packages:
#
package ifneeded tablelist::common 5.16 \
        "namespace eval ::tablelist { proc DIR {} {return [list $dir]} } ;\
	 source [list [file join $dir tablelistPublic.tcl]]"



|





|

|





|
|
|
|




|


1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#==============================================================================
# Tablelist and Tablelist_tile package index file.
#
# Copyright (c) 2000-2017  Csaba Nemethi (E-mail: [email protected])
#==============================================================================

#
# Regular packages:
#
package ifneeded tablelist         5.17 \
	[list source [file join $dir tablelist.tcl]]
package ifneeded tablelist_tile    5.17 \
	[list source [file join $dir tablelist_tile.tcl]]

#
# Aliases:
#
package ifneeded Tablelist         5.17 \
	[list package require -exact tablelist	    5.17]
package ifneeded Tablelist_tile    5.17 \
	[list package require -exact tablelist_tile 5.17]

#
# Code common to all packages:
#
package ifneeded tablelist::common 5.17 \
        "namespace eval ::tablelist { proc DIR {} {return [list $dir]} } ;\
	 source [list [file join $dir tablelistPublic.tcl]]"

Changes to modules/tablelist/tablelist.tcl.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#==============================================================================
# Main Tablelist package module.
#
# Copyright (c) 2000-2016  Csaba Nemethi (E-mail: [email protected])
#==============================================================================

package require Tcl 8
package require Tk  8
package require -exact tablelist::common 5.16

package provide tablelist $::tablelist::version
package provide Tablelist $::tablelist::version

::tablelist::useTile 0
::tablelist::createBindings



|




|






1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#==============================================================================
# Main Tablelist package module.
#
# Copyright (c) 2000-2017  Csaba Nemethi (E-mail: [email protected])
#==============================================================================

package require Tcl 8
package require Tk  8
package require -exact tablelist::common 5.17

package provide tablelist $::tablelist::version
package provide Tablelist $::tablelist::version

::tablelist::useTile 0
::tablelist::createBindings

Changes to modules/tablelist/tablelistPublic.tcl.

1
2
3
4
5
6
7
8
9
10
11
#==============================================================================
# Main Tablelist and Tablelist_tile package module.
#
# Copyright (c) 2000-2016  Csaba Nemethi (E-mail: [email protected])
#==============================================================================

namespace eval ::tablelist {
    #
    # Gets the scaling percentage (100, 125, 150, or 200).
    #
    proc scalingPercentage {} {



|







1
2
3
4
5
6
7
8
9
10
11
#==============================================================================
# Main Tablelist and Tablelist_tile package module.
#
# Copyright (c) 2000-2017  Csaba Nemethi (E-mail: [email protected])
#==============================================================================

namespace eval ::tablelist {
    #
    # Gets the scaling percentage (100, 125, 150, or 200).
    #
    proc scalingPercentage {} {
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
	    return 200
	}
    }

    #
    # Public variables:
    #
    variable version	5.16
    variable library
    if {$tcl_version >= 8.4} {
	set library	[file normalize [DIR]]
    } else {
	set library	[DIR]			;# no "file normalize" yet
    }
    variable scalingpct	[scalingPercentage]







|







20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
	    return 200
	}
    }

    #
    # Public variables:
    #
    variable version	5.17
    variable library
    if {$tcl_version >= 8.4} {
	set library	[file normalize [DIR]]
    } else {
	set library	[DIR]			;# no "file normalize" yet
    }
    variable scalingpct	[scalingPercentage]

Changes to modules/tablelist/tablelist_tile.tcl.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#==============================================================================
# Main Tablelist_tile package module.
#
# Copyright (c) 2000-2016  Csaba Nemethi (E-mail: [email protected])
#==============================================================================

package require Tcl 8.4
package require Tk  8.4
if {$::tk_version < 8.5 || [regexp {^8\.5a[1-5]$} $::tk_patchLevel]} {
    package require tile 0.6
}
package require -exact tablelist::common 5.16

package provide tablelist_tile $::tablelist::version
package provide Tablelist_tile $::tablelist::version

::tablelist::useTile 1
::tablelist::createBindings




|







|







1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#==============================================================================
# Main Tablelist_tile package module.
#
# Copyright (c) 2000-2017  Csaba Nemethi (E-mail: [email protected])
#==============================================================================

package require Tcl 8.4
package require Tk  8.4
if {$::tk_version < 8.5 || [regexp {^8\.5a[1-5]$} $::tk_patchLevel]} {
    package require tile 0.6
}
package require -exact tablelist::common 5.17

package provide tablelist_tile $::tablelist::version
package provide Tablelist_tile $::tablelist::version

::tablelist::useTile 1
::tablelist::createBindings