1d.colors(1) Grass User's Manual d.colors(1)
2
3
4
6 d.colors - Allows the user to interactively change the color table of
7 a raster map layer displayed on the graphics monitor.
8
10 display
11
13 d.colors
14 d.colors help
15 d.colors map=string
16
17 Parameters:
18 map=string
19 Name of raster map
20
22 A color table file associates specific colors with the categories of a
23 raster map layer. The user can change these map category color assign‐
24 ments (i.e., change the map's color table) interactively, by first dis‐
25 playing the raster map to the graphics monitor and then running the
26 program d.colors. If you have first set <A HREF="d.color‐
27 mode.html">d.colormode to "float" before displaying the map to the
28 graphics monitor, any color changes that you subsequently make while in
29 d.colors will immediately (and interactively) appear on the graphics
30 display.
31
32 While running d.colors the cursor must be inside the window where the
33 execution takes place. When in "float" colormode, the correct colors
34 appear on the graphics monitor only if the cursor is inside the moni‐
35 tor. To see the correct colors, move the cursor from the execution
36 window to inside the graphics monitor, then move back to the window to
37 continue making changes.
38
39 If d.colormode is "fixed", any color changes made using d.colors will
40 not immediately be shown on the graphics display; however, any color
41 changes saved will still alter the map's color table and will appear
42 next time the raster map layer is redisplayed (see d.colormode and
43 d.colortable). Note that some graphics display monitors or drivers can‐
44 not support interactive color change.
45
46 The user must first display the relevant raster map layer to the active
47 frame on the graphics monitor (e.g., using <A HREF="d.rast.html">d.rast
48 or <A HREF="d.display.html">d.display) before running d.colors. The
49 user can then either enter the name of the raster map layer whose color
50 table is to be changed on the command line (e.g., by typing: d.colors
51 map=soils), or type d.colors without program arguments. If the user
52 simply types d.colors without program arguments on the command line,
53 d.colors will ask the user to enter the name of an existing raster map
54 layer using the standard GRASS interface.
55
56 In either case, the user is then presented with the d.colors command
57 menu, shown below. This menu is the same as the category and color
58 changing portion of the d.display menu. The d.colors commands are
59 listed beneath the Category Pointer Movement, Color Modification,
60 Replotting Screen, and Quitting sections below. Commands are invoked
61 by typing in the single-key response shown to the left below. (Longer
62 descriptions of these commands appear to the right.) Results from
63 invoking these commands will be reflected in the Category and Category
64 Number sections of the d.colors screen. On the d.colors screen menu,
65 commands appear in the right half of the screen, and the current status
66 of categories appears in the left half of the screen.
67 CATEGORIES
68 0 No Data
69 1 (Category 1 description)
70 2 (Category 2 description)
71 . ....
72 . ....
73 CATEGORY NUMBER:
74 RED 0 0%
75 GREEN 0 0%
76 BLUE 0 0%
77 Shift Incr: 10 3%
78 CATEGORY POINTER MOVEMENT
79 D/d down (cats) Move pointer to next category
80 U/u up (cats) Move pointer to previous category
81 COLOR MODIFICATIONS
82 R/r RED Increase/decrease RED intensity
83 G/g GREEN Increase/decrease GREEN intensity
84 B/b BLUE Increase/decrease BLUE intensity
85 I/i increment Increase/decrease increment
86 (of intensity shift)
87 h highlight Highlight current color
88 +/- shift colors Shift entire color table (up/down)
89 c save color Save color table
90 t toggle table Toggle to different color table
91 REPLOTTING SCREEN
92 * Replot screen Replots the screen
93 QUITTING
94 Q quit Quits program
95 Changing categories - The keys "d, D, u," and "U" are used to move to
96 a different category. The lower case letters move up, u, and down, d,
97 the category list one category at a time. The upper case letters move
98 10 categories at a time for fast movement. The cursor does wrap between
99 the first and last categories. The current category is noted on the
100 text screen with an arrow, and is indicated on the graphics screen by a
101 box around the current color.
102
103 Changing colors - The color associated with the current category can be
104 changed with the "R, r, G, g, B," and b keys. The upper case letters
105 increase the intensities of red R, green G, and blue B for the current
106 category; the lower case letters decrease the intensities of these same
107 colors for the current category. Video devices make all the colors of
108 the spectrum by mixing red, green, and blue. For those accustomed to
109 red, yellow, and blue being the primary colors, this can be confusing.
110 For starters, yellow is made by mixing red and green. The intensities
111 are listed on the text screen in as percentages.
112
113 Keys I and i increase and decrease the percentage change that each key‐
114 stroke of one of the color keys (R, r, G, g, B, b) causes in its
115 respective color. The increase increment is initially set to 10%.
116 Thus, pressing the R key would will increase the red component of the
117 current category by 10%.
118
119 Highlight - The h key toggles between the current category color and
120 the current highlight color. This color is initially black but can be
121 modified as above while in highlight mode. Blinking can be accomplished
122 by repeatedly striking the h key. When changing to different categories
123 using the movement keys as described above, while in highlight mode the
124 category colors will be always left showing their actual colors. Only
125 one category is highlighted at any one time.
126
127 Saving the current color table - Pressing the c key will save the cur‐
128 rent color table as you have modified it. This table will then be used
129 next time you display or paint this raster map layer.
130
131 Color table toggle - Different types of color tables are suitable for
132 different raster map layers. The key t flips between the following
133 color tables: red, green, blue color ramp; gray scale; smooth changing
134 color wave; random colors; and the saved color table.
135
136 Color table shift - The entire table is shifted up and down using the +
137 and - keys.
138
139 Quitting the d.colors program - Pressing the Q key will cause you to
140 quit the d.colors program. If colors have been modified but not saved,
141 d.colors will ask:
142 Colors changed
143 Save the changes? (y/n)
144 The user should type in y to save changes, or n to not save changes,
145 before quitting the program. If the user types n, the program will
146 ask:
147 Quit anyway? (y/n)
148
149
151 To see map color changes reflected on the display monitor as you make
152 them, you must put the monitor in float color mode before running
153 d.colors. It is also wise to erase the display screen after changing
154 the color mode.
155
156 The map whose color table is to be altered with d.colors must already
157 be on display in the active display frame on the graphics monitor
158 before d.colors is run. This can be done using the command d.rast
159 map=name (where name is a raster map layer whose color table the user
160 wishes to alter).
161
162 The user might type the following sequence of commands to interactively
163 change the colors of a raster soils map:
164
165 d.colormode mode=float d.erase d.rast map=soils d.colors
166
167 After the user has saved any color changes made with d.colors and
168 exited the program, the user could then redisplay the soils map with
169 the new colors by typing:
170
171 d.colormode mode=fixed d.erase d.rast map=soils
172
173 Some color monitors may not support the full range of colors required
174 to display all of the map's categories listed in the map's color table.
175 However, regardless of whether the user can see the color changes he is
176 effecting to a map's color table, any changes to a map's color table
177 made with d.colors that are saved will appear in the map's color table.
178
179 Some monitors may not support an interactive color change capability.
180
182 d.colortable
183 d.rast
184 r.colors
185
187 James Westervelt, U.S. Army Construction Engineering Research Labora‐
188 tory
189
190 Last changed: $Date: 2007/03/26 00:15:54 $
191
192 Help Index
193
194
195
196GRASS 6.2.2 d.colors(1)