1
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
2
"http://www.w3.org/TR/html40/loose.dtd">
7
<title>Module: termdefs</title>
10
<body bgcolor="#ffffff">
12
<p><i><a href="../index.html">Table of Contents</a></i></p>
14
<table border="0" cellpadding="5" cellspacing="0" width="100%">
20
bgcolor="#88bbee"><font color="#000000">Module: termdefs</font>
24
align="right"><font color="#000000">Gnuplot/termdefs.py</font>
30
<p>Terminal definition file.</p>
31
<p>This module describes the options available to gnuplot's various
32
terminals. For the moment, it only supports a few terminals, but the
33
infrastructure is here to add others as they are needed.</p>
34
<p>Part of the trick is that the <code>set terminal</code> command takes myriad
35
suboptions with various argument types, and order is sometimes
36
significant. The other part of the trick is that there are over 50
37
terminal types, and each terminal has its own set of options.</p>
38
<p>The strategy here is to define a general mechanism for turning Python
39
keyword parameters into fragments of gnuplot command strings. There
40
are a number of classes derived from Arg that do this. Some take
41
string args, some boolean, etc. Then the list of options that each
42
terminal accepts is stored in the terminal_opts dictionary.
43
Gnuplot.hardcopy(), in turn, uses this dictionary to interpret its
44
keyword arguments and build the <code>set terminal</code> command.</p>
45
<table border="0" cellpadding="5" cellspacing="0" width="100%">
54
<font color="#000000">
55
<a name="Imported modules">Imported modules</a>
63
<font color="#000000"> </font>
69
<b>import</b> <a href="Errors.html">Errors</a><br>
70
<b>import</b> <a href="gp.html">gp</a><br>
71
<b>import</b> <a href="http://www.python.org/doc/current/lib/module-types.html">types</a><br>
82
<font color="#000000">
83
<a name="Classes">Classes</a>
91
<font color="#000000"> </font>
97
<table border="0" cellpadding="3" cellspacing="0">
98
<tr><td valign="top" align="left"><p><a href="termdefs/Arg.html">Arg</a></p></td><td valign="top" align="left">
99
<p>Process terminal subargs and return a command fragment.</p>
101
<tr><td valign="top" align="left"><p><a href="termdefs/ArgOneParam.html">ArgOneParam</a></p></td><td valign="top" align="left">
102
<p>Arg abstract base class specialized for exactly one parameter.</p>
104
<tr><td valign="top" align="left"><p><a href="termdefs/BareStringArg.html">BareStringArg</a></p></td><td valign="top" align="left">
105
<p>An arbitrary argument output without quotes.</p>
107
<tr><td valign="top" align="left"><p><a href="termdefs/BooleanArg.html">BooleanArg</a></p></td><td valign="top" align="left">
108
<p>An argument that takes a true/false value.</p>
110
<tr><td valign="top" align="left"><p><a href="termdefs/KeywordArg.html">KeywordArg</a></p></td><td valign="top" align="left">
111
<p>Represent an argument that must be passed as a keyword to gnuplot.</p>
113
<tr><td valign="top" align="left"><p><a href="termdefs/KeywordOrBooleanArg.html">KeywordOrBooleanArg</a></p></td><td valign="top" align="left">
114
<p>Allow a keyword arg to be specified either as a keyword or a boolean.</p>
116
<tr><td valign="top" align="left"><p><a href="termdefs/MutuallyExclusiveArgs.html">MutuallyExclusiveArgs</a></p></td><td valign="top" align="left">
117
<p>A group of args, of which either zero or one may be set, but not more.</p>
119
<tr><td valign="top" align="left"><p><a href="termdefs/StringArg.html">StringArg</a></p></td><td valign="top" align="left">
120
<p>An option taking a quoted string argument.</p>
133
<p><i><a href="../index.html">Table of Contents</a></i></p>
135
<font size="-2"><i>This document was automatically generated
136
on Sun Oct 19 17:10:22 2003 by
137
<a href="http://happydoc.sourceforge.net">HappyDoc</a> version
b'\\ No newline at end of file'