summaryrefslogtreecommitdiff
path: root/graphics/jpicedt/doc/preferences.html
blob: 569384b0692076e9f5cbfc54d8008e2ded5ddc27 (plain)
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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
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
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
  <HEAD>
    <META HTTP-EQUIV="CONTENT-TYPE" CONTENT="text/html; charset=iso-8859-1">
	<META key="author" CONTENT="Sylvain Reynal">
    <TITLE>jPicEdt 1.3.2 Help Content </TITLE>
  </HEAD>

  <BODY BGCOLOR="#ffffff">

  <H2>Setting preferences</H2>

  <hr>
  <H3>General</H3>
	<UL>
	<LI>Look'n feel : let you choose your
	favorite Look'n Feel ; defaults to <I>metal</I> (a SUN look'n feel)
	on startup. 
	<LI>Language : English, French,... </LI> 
	<LI><P>Undoable steps : let you specify the number of undoable steps
	; 0 means that undo is deactivated. </P></LI>
	<li>Default content-type : this is the default formatter used when creating
	a new drawing. The preferred way is to use PsTricks, because then you get a
	real high quality rendering (colours, textures, shadows,...), but if you
	don't want to rely on add-ons packages, simply choose the Emulated LaTeX
	content-type (then you'll get only a minimal subset of those graphical attributes,
	i.e. no-filling, no colours,...). The epic/eepic choice is a reasonable
	choice for those who don't need colours and textures, but are
	willing to draw ellipses, arcs, polygons,... with a satisfying rendering quality.
	Note also that PsTricks uses PostScript in the background so if your DVI
	Viewer dooesn't handle PostScript special, use <code>dvips</code> first to
	convert your DVI file to a PS file, then run <code>ghostscript</code> to
	display it.
</UL>
<P>You must restart jPicEdt if you want a new language choice to take
effect.</P>

  <hr>


<H3>LaTeX, epic and PsTricks tab panes</H3>
<p>Let you set format specific parameters.
One thing common to all formats is the prolog/epilog string, and
is used when running LaTeX on your picture from within
jPicEdt.
<br>
These strings get prepended/appended to
the text generated by the formatter (i.e. the text starting with <code>\begin{picture}</code>) so that the
resulting text is a &quot;stand-alone&quot; LaTeX file, and can be directly compiled by
LaTeX. The default prolog/epilog simply include necessary packages, but you can add your own
macro definition here, so that, for example, arguments of text-boxes which use macros of your own are
compiled properly. 

 
<P>Unitlength is always set to 1 mm at the beginning of
the saved file. OK, this is rather stringent, but (useless to say) you
sure CAN load a file containing a different value ! jPicEdt will
simply scale the drawing accordingly. (There's actually another
efficient way to scale the entire drawing by using the SCALE tool in the
tool-bar).

<H4>LaTeX picture environment specific parameters</H4>

<UL>
	<LI><B>Linethickness</B> : set the default
	linethickness (in <B>mm</B>). This value is used when loading a TeX file only, when
	no <code>\linethickness</code> has been found.
	
	<LI><B>Max LaTeX circle/disk diameter</B> : this depends on your own LaTeX installation. 
	You'll have to set it to
	the biggest circle/disk diameter contained in your LaTeX font
	(actually, 14mm for circles, and 5.4mm for disks, which incidentally
	are the default values, match almost every TeX distribution). 
	
	
</UL>
<P>LaTeX picture environment only allows for a small number of line
slopes ; in <B>emulated mode</B>, jPicEdt use the <CODE>\multiput</CODE>
command to emulate lines of any slope, using a set of very closed and
tiny horizontal or vertical segments. As a result, lines of any
thickness can now be drawn (FYI, the <CODE>\thickness</CODE> command
doesn't work with standard slanted lines). 
</P>
<UL>
	<LI><B>Emulated line segment length</B>
	: this is the length of the small segments that compose emulated
	lines. 
	</LI>	
	<LI><B>Emulated line max slope</B> :
	when do we have to switch between an almost (hence emulated)
	vertical emulated line and a TRUE vertical line ? 
	</LI>
	<LI><B>Emulated circle segment length</B> : this is the length of
	the small segments that compose emulated circles (that is, circles
	having a radius greater than Max-LaTeX-Circle-Diameter). Note : big
	disk can't be emulated using LaTeX picture environment commands, but
	they can if you decide to use the <I>eepic</I> package. 
	</LI>
</UL>
</P>

<hr>

<H3>External commands</H3>
<p>
<B>How it works...</B>

<p>
When running LaTeX/DVI/... from within jPicEdt, a LaTeX file is created on
the fly by jPicEdt in the standard temp' directory of the OS you're using (e.g. c:\windows\temp),
or another temp' dir if you changed it (see Directories panel).
The variety of operating systems and LaTeX distributions made it impossible to
design a scheme for running external commands that wouldn't rely on scripts 
(e.g. batches under DOS, AppleScript on MacOS).
</p> 
<P>So the best thing to do is (as for me) to use external scripts 
which call the adequate programs (latex, dviwin32.exe/xdvi,...). You can
pass argument to this script by using the predefinite symbols
&quot;{p}&quot; and &quot;{f}&quot;.
	<ul>
	<li>&quot;{p}&quot; gets replaced by your temp. directory (this is where the LaTeX file gets created),
	e.g. <code>/tmp/</code> under Linux, <code>c:\windows\temp</code> under Win9x, etc...</li>
	<li>
	&quot;{f}&quot; gets replaces by the name of the temp. file (usually &quot;jpicedt&quot; 
	with a random number appended to it, e.g. &quot;jpicedt542163&quot;), w/o any &quot;tex&quot; extension.
	</li>
	<li>{i} gets replaced by the location of the &quot;add-ons&quot; directory where some scripts already
	reside for some LaTeX distributions.</li>
</ul>
Here's an example of an external batch that will work under Linux's bash-shell : 
</P>
<P><b>
<CODE>#!/bin/sh</CODE><BR>
<CODE>cd $1</CODE><BR>
<CODE>$2 $3</CODE></B></P>
<P>Suppose this script was saved in the &quot;add-ons&quot; directory, then
the command line which appears under the &quot;external-commands&quot;'s
tab in the preferences-setting tabsheet will be typesetted as
follows:</P>

<P><b><CODE>{i}/ext_proc {p} latex {f}</CODE> </b></P>

<P>(where &quot;latex&quot; can be replaced by any appropriate name,
e.g. xdvi, kghostview, kdvi,...). <p>
This will lead, once &quot;{p}&quot; and &quot;{f}&quot; have been 
replaced, to :
<p>
	<b><code>ext_proc /tmp latex jpicedt46858</code></b>
<p>which finally yields,
<p>
	<b><code>cd /tmp</code><br>
	<code>latex jpicedt46858</code></b><p>
	(latex accept a file w/o extension on the command line, otherwise add ".tex"
	manually in your script).
</P>

	<B>Loading predefined configurations</B>
	<P>
	There currently exist scripts and predefined configurations for the following LaTeX distribution :
	</P>
	<p>
	<ul>
		<li>Unix : TeTeX</li>
		<li>Windows : MikTeX, WinGUT, and ScientificWorkplace.</li>
	</ul>
	These scripts reside in the <b>add-ons</b> subdirectory of where jPicEdt got installed 
	(you need to have installed the <b>add-ons</b> package during jPicEdt's installation).
	<br>
	To load a predefined configuration file, go to the Preferences->Commands pane, 
	press the <b>LOAD PREDEFINED CONFIGURATION</b> button, and browse the directory tree until
	you find a file matching your LaTeX distribution.
</p>
<HR>
</HR>
</BODY>
</HTML>