summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordkf <donal.k.fellows@manchester.ac.uk>2008-02-06 14:34:56 (GMT)
committerdkf <donal.k.fellows@manchester.ac.uk>2008-02-06 14:34:56 (GMT)
commit0429a096a9b64aa1554739fa05c76fbcb83f4887 (patch)
tree1ca4d8b3d9ee69800f2d491487288a090b7aed48
parent2a767dc40caf7a7858531d3c96157ca65887a81c (diff)
downloadtk-0429a096a9b64aa1554739fa05c76fbcb83f4887.zip
tk-0429a096a9b64aa1554739fa05c76fbcb83f4887.tar.gz
tk-0429a096a9b64aa1554739fa05c76fbcb83f4887.tar.bz2
Added basic documentation for ttk::scale. [Bug 1881925]
-rw-r--r--ChangeLog4
-rw-r--r--doc/ttk_scale.n102
2 files changed, 106 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index 82b97ff..c988bca 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2008-02-06 Donal K. Fellows <donal.k.fellows@man.ac.uk>
+
+ * doc/ttk_scale.n (new file): Added basic documentation. [Bug 1881925]
+
2008-02-04 Don Porter <dgp@users.sourceforge.net>
*** 8.5.1 TAGGED FOR RELEASE ***
diff --git a/doc/ttk_scale.n b/doc/ttk_scale.n
new file mode 100644
index 0000000..0806c36
--- /dev/null
+++ b/doc/ttk_scale.n
@@ -0,0 +1,102 @@
+.\"
+.\" Copyright (c) 2008 Donal Fellows
+.\"
+.\" See the file "license.terms" for information on usage and redistribution
+.\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
+.\"
+.\" CVS: @(#) $Id: ttk_scale.n,v 1.1 2008/02/06 14:34:57 dkf Exp $
+.\"
+.so man.macros
+.TH ttk::scale n 8.5 Tk "Tk Themed Widget"
+.BS
+.SH NAME
+ttk::scale \- Create and manipulate a scale widget
+.SH SYNOPSIS
+\fBttk::scale \fIpathName \fR?\fIoptions...\fR?
+.BE
+.SH DESCRIPTION
+A \fBttk::scale\fR widget is typically used to control the numeric value of a
+linked variable that varies uniformly over some range. A scale displays a
+\fIslider\fR that can be moved along over a \fItrough\fR, with the relative
+position of the slider over the trough indicating the value of the variable.
+.SO ttk_widget
+\-class \-cursor \-style
+\-takefocus
+.SE
+.SH "WIDGET-SPECIFIC OPTIONS"
+.OP \-command command Command
+Specifies the prefix of a Tcl command to invoke whenever the scale's value is
+changed via a widget command. The actual command consists of this option
+followed by a space and a real number indicating the new value of the scale.
+.OP \-from from From
+A real value corresponding to the left or top end of the scale.
+.OP \-length length Length
+Specifies the desired long dimension of the scale in screen units (i.e. any of
+the forms acceptable to \fBTk_GetPixels\fR). For vertical scales this is the
+scale's height; for horizontal scales it is the scale's width.
+.OP \-orient orient Orient
+Specifies which orientation whether the widget should be laid out horizontally
+or vertically. Must be either \fBhorizontal\fR or \fBvertical\fR or an
+abbreviation of one of these.
+.OP \-to to To
+Specifies a real value corresponding to the right or bottom end of the scale.
+This value may be either less than or greater than the \fBfrom\fR option.
+.OP \-value value Value
+Specifies the current floating-point value of the variable.
+.OP \-variable variable Variable
+Specifies the name of a global variable to link to the scale. Whenever the
+value of the variable changes, the scale will update to reflect this value.
+Whenever the scale is manipulated interactively, the variable will be modified
+to reflect the scale's new value.
+.SH "WIDGET COMMAND"
+.TP
+\fIpathName \fBcget \fIoption\fR
+.
+Returns the current value of the specified \fIoption\fR; see
+\fIttk::widget(n)\fR.
+.TP
+\fIpathName \fBconfigure \fR?\fIoption\fR? ?\fIvalue option value ...\fR?
+.
+Modify or query widget options; see \fIttk::widget(n)\fR.
+.TP
+\fIpathName \fBget \fR?\fIx y\fR?
+.
+Get the current value of the \fB\-value\fR option, or the value corresponding
+to the coordinates \fIx,y\fR if they are specified. \fIX\fR and \fIy\fR are
+pixel coordinates relative to the scale widget origin.
+.TP
+\fIpathName \fBinstate \fIstatespec\fR ?\fIscript\fR?
+.
+Test the widget state; see \fIttk::widget(n)\fR.
+.TP
+\fIpathName \fBset \fIvalue\fR
+.
+Set the value of the widget (i.e. the \fB\-value\fR option) to \fIvalue\fR.
+The value will be clipped to the range given by the \fB\-from\fR and
+\fB\-to\fR options. Note that setting the linked variable (i.e. the variable
+named in the \fB\-variable\fR option) does not cause such clipping.
+.TP
+\fIpathName \fBstate\fR ?\fIstateSpec\fR?
+.
+Modify or query the widget state; see \fIttk::widget(n)\fR.
+.SH "INTERNAL COMMANDS"
+.TP
+\fIpathName \fBcoords \fR?\fIvalue\fR?
+.
+Get the coordinates corresponding to \fIvalue\fR, or the coordinates
+corresponding to the current value of the \fB\-value\fR option if \fIvalue\fR
+is omitted.
+.TP
+\fIpathName \fBidentify \fIx y\fR
+.
+Returns the name of the element under the point given by \fIx\fR and \fIy\fR,
+or an empty string if the point does not lie in any element of the scale.
+\fIX\fR and \fIy\fR are pixel coordinates relative to the scale widget origin.
+.SH "SEE ALSO"
+ttk::widget(n), scale(n)
+.SH KEYWORDS
+scale, slider, trough, widget
+.\" Local Variables:
+.\" mode: nroff
+.\" fill-column: 78
+.\" End: