summaryrefslogtreecommitdiffstats
path: root/doc/GetDash.3
diff options
context:
space:
mode:
authorhobbs <hobbs>1999-12-14 06:51:43 (GMT)
committerhobbs <hobbs>1999-12-14 06:51:43 (GMT)
commit9b37fa05b11850066aed28ed447109e55708bce0 (patch)
treec4d876b773ea4b9b6675a0e9a9c380a6bfac9542 /doc/GetDash.3
parentea12a22c853959d87130dbc26197c27f47d00e41 (diff)
downloadtk-9b37fa05b11850066aed28ed447109e55708bce0.zip
tk-9b37fa05b11850066aed28ed447109e55708bce0.tar.gz
tk-9b37fa05b11850066aed28ed447109e55708bce0.tar.bz2
* doc/canvas.n: added docs for items added by dash patch (-*dash*,
-state, -active*, -disabled*, -offset, essentially rewrote the man patch for completely updated 8.3 canvas widget. * doc/entry.n: added docs for entry widget validation * doc/event.n: added docs for -warp * doc/text.n: doc'ed new -state value 'hidden' * doc/GetDash.3: (new file) man page explaining Tk_GetDash
Diffstat (limited to 'doc/GetDash.3')
-rw-r--r--doc/GetDash.370
1 files changed, 70 insertions, 0 deletions
diff --git a/doc/GetDash.3 b/doc/GetDash.3
new file mode 100644
index 0000000..2c4765c
--- /dev/null
+++ b/doc/GetDash.3
@@ -0,0 +1,70 @@
+'\"
+'\" Copyright (c) 1989-1993 The Regents of the University of California.
+'\" Copyright (c) 1994-1996 Sun Microsystems, Inc.
+'\"
+'\" See the file "license.terms" for information on usage and redistribution
+'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
+'\"
+'\" RCS: @(#) $Id: GetDash.3,v 1.1 1999/12/14 06:51:43 hobbs Exp $
+'\"
+.so man.macros
+.TH Tk_GetDash 3 8.3 Tk "Tk Library Procedures"
+.BS
+.SH NAME
+Tk_GetDash \- convert from string to valid dash structure.
+.SH SYNOPSIS
+.nf
+\fB#include <tk.h>\fR
+.sp
+int
+\fBTk_GetDash\fR(\fIinterp, string, dashPtr\fR)
+.SH ARGUMENTS
+.AS Tk_Dash *dashPtr
+.AP Tcl_Interp *interp in
+Interpreter to use for error reporting.
+.AP CONST char *string in
+Textual value to be converted.
+.AP Tk_Dash *dashPtr out
+Points to place to store the dash pattern
+value converted from \fIstring\fR.
+.BE
+
+.SH DESCRIPTION
+.PP
+These procedure parses the string and fills in the result in the
+Tk_Dash structure. The string can be a list of integers or a
+character string containing only \fB[.,-_]\fR or spaces. If all
+goes well, TCL_OK is returned. If \fIstring\fR doesn't have the
+proper syntax then TCL_ERROR is returned, an error message is left
+in the interpreter's result, and nothing is stored at *\fIdashPtr\fR.
+.PP
+The first possible syntax is a list of integers. Each element
+represents the number of pixels of a line segment. Only the odd
+segments are drawn using the "outline" color. The other segments
+are drawn transparent.
+.PP
+The second possible syntax is a character list containing only
+5 possible characters \fB[.,-_ ]\fR. The space can be used
+to enlarge the space between other line elements, and can not
+occur as the first posibion in the string. Some examples:
+ -dash . = -dash {2 4}
+ -dash - = -dash {6 4}
+ -dash -. = -dash {6 4 2 4}
+ -dash -.. = -dash {6 4 2 4 2 4}
+ -dash {. } = -dash {2 8}
+ -dash , = -dash {4 4}
+.PP
+The main difference of this syntax with the previous is that it
+it shape-conserving. This means that all values in the dash
+list will be multiplied by the line width before display. This
+assures that "." will always be displayed as a dot and "-"
+always as a dash regardless of the line width.
+.PP
+On systems where only a limited set of dash patterns, the dash
+pattern will be displayed as the most close dash pattern that
+is available. For example, on Windows only the first 4 of the
+above examples are available. The last 2 examples will be
+displayed identically as the first one.
+
+.SH KEYWORDS
+dash, conversion