Tk Library Source Code

Check-in [56b88914a8]
Login

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

Overview
Comment:Tsw: Minor improvements in the documentation.
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 56b88914a8da36d61246a6c860d57e527927724468715e786dc38d90c785db95
User & Date: csaba 2025-03-19 09:46:30.528
Context
2025-03-20
14:08
Tablelist: Updated for version 7.5. See the ChangeLog for details. check-in: 6bd0090cf0 user: csaba tags: trunk
2025-03-19
09:46
Tsw: Minor improvements in the documentation. check-in: 56b88914a8 user: csaba tags: trunk
2025-03-18
16:25
Tsw: Guarded against the deletion of namespace qualifiers for the value of the "-variable" option. check-in: f94f2c324b user: csaba tags: trunk
Changes
Unified Diff Ignore Whitespace Patch
Changes to modules/tsw/README.txt.
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
in the off state at its beginning.  The user can toggle between these
two states with the mouse or the space key.

You can use the "switchstate" subcommand of the Tcl command associated
with a toggleswitch to change or query the widget's switch state.  By
using the "-command" configuration option, you can specify a script to
execute whenever the switch state of the widget gets toggled.  For
compatibility with the ttk::checkbutton, toggleswitch widgets also
support the "-offvalue", "-onvalue", and "-variable" options.

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

Tsw is available for free download from the Web page








|







30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
in the off state at its beginning.  The user can toggle between these
two states with the mouse or the space key.

You can use the "switchstate" subcommand of the Tcl command associated
with a toggleswitch to change or query the widget's switch state.  By
using the "-command" configuration option, you can specify a script to
execute whenever the switch state of the widget gets toggled.  For
compatibility with the (ttk::)checkbutton, toggleswitch widgets also
support the "-offvalue", "-onvalue", and "-variable" options.

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

Tsw is available for free download from the Web page

Changes to modules/tsw/doc/toggleswitch.html.
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
    with the mouse or the <code>space</code> key.</dd>

    <dd class="tm">The Tcl command associated with a toggleswitch widget has a
    very simple API.&nbsp; You can use the <code><b><a href=
    "#switchstate">switchstate</a></b></code> subcommand to change or query
    the widget's switch state.&nbsp; By using the <code><b><a href=
    "#command">-command</a></b></code> configuration option, you can specify a
    script to execute whenever this subcommand or the convenience one named
    <code><b><a href="#toggle">toggle</a></b></code> causes the widget's switch
    state to get toggled.&nbsp; For compatibility with the ttk::checkbutton,
    toggleswitch widgets also support the <code><b><a href=
    "#offvalue">-offvalue</a></b></code>, <code><b><a href=
    "#onvalue">-onvalue</a></b></code>, and <code><b><a href=
    "#variable">-variable</a></b></code> options.</dd>

    <dd class="tm">The colors used when drawing the trough and the slider in
    the various widget states (such as <code><b>active</b></code>,
    <code><b>background</b></code>, <code><b>disabled</b></code>,
    <code><b>pressed</b></code>, and <code><b>selected</b></code>) depend on
    the current theme.&nbsp; The implementation contains procedures that create







|
<
<
|
|
|







177
178
179
180
181
182
183
184


185
186
187
188
189
190
191
192
193
194
    with the mouse or the <code>space</code> key.</dd>

    <dd class="tm">The Tcl command associated with a toggleswitch widget has a
    very simple API.&nbsp; You can use the <code><b><a href=
    "#switchstate">switchstate</a></b></code> subcommand to change or query
    the widget's switch state.&nbsp; By using the <code><b><a href=
    "#command">-command</a></b></code> configuration option, you can specify a
    script to execute whenever the widget's switch state gets toggled.&nbsp;


    For compatibility with the (ttk::)checkbutton, toggleswitch widgets also
    support the <code><b><a href="#offvalue">-offvalue</a></b></code>,
    <code><b><a href="#onvalue">-onvalue</a></b></code>, and <code><b><a href=
    "#variable">-variable</a></b></code> options.</dd>

    <dd class="tm">The colors used when drawing the trough and the slider in
    the various widget states (such as <code><b>active</b></code>,
    <code><b>background</b></code>, <code><b>disabled</b></code>,
    <code><b>pressed</b></code>, and <code><b>selected</b></code>) depend on
    the current theme.&nbsp; The implementation contains procedures that create
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
        <tr>
          <td>Database Class:</td>
          <td><code><b>&nbsp;Command</b></code></td>
        </tr>
      </table>

      <blockquote>
        <p>Specifies a Tcl script to execute whenever the switch state of the
        widget is toggled (programmatically or interactively).&nbsp; The
        default is an empty string.</p>
      </blockquote>
    </dd>

    <dd id="offvalue">
      <table border="0" cellpadding="0" cellspacing="0">
        <tr>
          <td>Command-Line Name:&nbsp;</td>







|
|
|







234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
        <tr>
          <td>Database Class:</td>
          <td><code><b>&nbsp;Command</b></code></td>
        </tr>
      </table>

      <blockquote>
        <p>Specifies a Tcl script to be evaluated at global scope whenever the
        switch state of the widget is toggled (programmatically or
        interactively).&nbsp; The default is an empty string.</p>
      </blockquote>
    </dd>

    <dd id="offvalue">
      <table border="0" cellpadding="0" cellspacing="0">
        <tr>
          <td>Command-Line Name:&nbsp;</td>
Changes to modules/tsw/doc/tsw.html.
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100

  <p>You can use the <code><a href=
  "toggleswitch.html#switchstate">switchstate</a></code> subcommand of the Tcl
  command associated with a toggleswitch to change or query the widget's switch
  state.&nbsp; By using the <code><a href=
  "toggleswitch.html#command">-command</a></code> configuration option, you can
  specify a script to execute whenever the switch state of the widget gets
  toggled.&nbsp; For compatibility with the ttk::checkbutton, toggleswitch
  widgets also support the <code><a href=
  "toggleswitch.html#offvalue">-offvalue</a></code>, <code><a href=
  "toggleswitch.html#onvalue">-onvalue</a></code>, and <code><a href=
  "toggleswitch.html#variable">-variable</a></code> options.</p>

  <h3 id="ov_get">How to Get It?</h3>








|







86
87
88
89
90
91
92
93
94
95
96
97
98
99
100

  <p>You can use the <code><a href=
  "toggleswitch.html#switchstate">switchstate</a></code> subcommand of the Tcl
  command associated with a toggleswitch to change or query the widget's switch
  state.&nbsp; By using the <code><a href=
  "toggleswitch.html#command">-command</a></code> configuration option, you can
  specify a script to execute whenever the switch state of the widget gets
  toggled.&nbsp; For compatibility with the (ttk::)checkbutton, toggleswitch
  widgets also support the <code><a href=
  "toggleswitch.html#offvalue">-offvalue</a></code>, <code><a href=
  "toggleswitch.html#onvalue">-onvalue</a></code>, and <code><a href=
  "toggleswitch.html#variable">-variable</a></code> options.</p>

  <h3 id="ov_get">How to Get It?</h3>