1d.text(1)                     Grass User's Manual                    d.text(1)
2
3
4

NAME

6       d.text   - Draws text in the active display frame on the graphics moni‐
7       tor using the current font.
8

KEYWORDS

10       display
11

SYNOPSIS

13       d.text
14       d.text help
15       d.text  [-mpgbrsc]    [text=string]     [size=float]     [color=string]
16       [line=integer]    [at=x,y]   [align=string]   [rotation=float]   [line‐
17       spacing=float]     [font=string]     [path=string]     [charset=string]
18       [--verbose]  [--quiet]
19
20   Flags:
21       -m
22           Use mouse to interactively place text
23
24       -p
25           Screen position in pixels ([0,0] is top left)
26
27       -g
28           Screen position in geographic coordinates
29
30       -b
31           Use bold text
32
33       -r
34           Use radians instead of degrees for rotation
35
36       -s
37           Font size is height in pixels
38
39       -c
40           Ignored (compatibility with d.text.freetype)
41
42       --verbose
43           Verbose module output
44
45       --quiet
46           Quiet module output
47
48   Parameters:
49       text=string
50           Text to display
51
52       size=float
53           Height of letters in percentage of available frame height
54           Options: 0-100
55           Default: 5
56
57       color=string
58           Text color, either a standard GRASS color or R:G:B triplet
59           Default: gray
60
61       line=integer
62           The screen line number on which text will begin to be drawn
63           Options: 1-1000
64
65       at=x,y
66           Screen  position  at which text will begin to be drawn (percentage,
67           [0,0] is lower left)
68
69       align=string
70           Text alignment
71           Options: ll,lc,lr,cl,cc,cr,ul,uc,ur
72           Default: ll
73
74       rotation=float
75           Rotation angle in degrees (counter-clockwise)
76           Default: 0
77
78       linespacing=float
79           Line spacing
80           Default: 1.25
81
82       font=string
83           Font name
84
85       path=string
86           Path to font file
87
88       charset=string
89           Text encoding (only applicable to TrueType fonts)
90

DESCRIPTION

92       d.text draws text in the active display frame on the graphics  monitor.
93       Text  can  be provided through standard input or redirected from a file
94       (using the UNIX redirection mechanism).  In  addition  to  the  options
95       provided  on  the  command line, colors, text size, font type, rotation
96       angle, and boldness can be adjusted with commands in the standard input
97       (i.e.,  if the user invokes d.text without options on the command line,
98       and then assigns values to these options on lines within  the  standard
99       input).
100
101   Commands:
102       .C color
103              (where color is one of the available colors) causes text appear‐
104              ing on subsequent lines to be drawn in that color.
105
106       .S  size
107              (where size is a percentage within the range 0 to  100)  adjusts
108              text  size.   Note  that a size of 10 would allow 10 lines to be
109              drawn in the active display frame, 5 would allow the drawing  of
110              20 lines, and 50 would allow the drawing of 2 lines.
111
112       .F font
113              (where  font  is  one  of  the  fonts known by the GRASS program
114              d.font) manipulates the font type. Available fonts are listed in
115              the  GRASS  manual entry for d.font.  The default font type used
116              (if unspecified by the user) is romans.
117
118       .R  rotation
119              (where rotation is an angle in  degrees,  counter-clockwise)  to
120              rotate the text.
121
122       .B 1
123              stipulates that following text be printed in bold.  This command
124              means bold on.
125
126       .B 0
127               turns bold off of all text appearing on lines beneath it. (Bold
128              off is used by default, if unspecified by the user.)
129

EXAMPLE

131       The  following  command  will print the short phrase "This is a test of
132       d.text" in the active display frame using the color  yellow,  in  bold,
133       and using 4/100'ths (4%) of the active frame's vertical space per line:
134
135
136           d.text << EOF
137           .C yellow
138           .S 4
139           .B 1
140           This is a test of d.text
141           EOF
142         The  user presses control-d (the "Ctrl" and "d" keys) to end input to
143       d.text (equal to EOF).
144

NOTES

146       Note that the GRASS command d.title creates  map  TITLEs  in  a  format
147       suitable for input to d.text.
148
149       d.text  needs  escape sequences that can be used within lines to change
150       colors, boldness, and perhaps size.
151

SEE ALSO

153       d.font
154       d.font.freetype
155       d.title
156       d.text.freetype
157       d.labels
158

AUTHOR

160       James Westervelt, U.S. Army Construction Engineering  Research  Labora‐
161       tory
162
163       Updates by Huidae Cho
164
165       Last changed: $Date: 2006-09-01 12:05:31 +0200 (Fri, 01 Sep 2006) $
166
167       Full index
168
169       © 2003-2008 GRASS Development Team
170
171
172
173GRASS 6.3.0                                                          d.text(1)
Impressum