Introduction Appetizer Examples Documentation Applications
Work plan
Colors
The use of this tool is illustrated in the Cartesian
Plane.
The configuration panel of the tool COLORS
has only four lines:
BACKGROUND=white
NET=lightGray
AXES=gray
TEXT=darkGray
where the colour names white, lightGray etc... may be substituted by any of the predefined
colours or by hexadecimal expressions that specify a colour.
The predefined colours are: balck, darkGray, gray, lightGray, white, pink, red, orange, yellow, green, cyan, blue and magenta. The spanish
names of these colours can also be used (see the table at the end of the page).
A hexadecimal expression is a string which contains only hexadecimal
digits: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, a, b, c, d, e, f . In order to define a colour by
means of a hexadecimal expression it is necessary to forme a string with six hexadecimal
digits. They are interpreted in pairs. The first two represent the quantity of red, the
next two represent the quantity of green and the last two represent the quantity of blue
that the colour contains. For example:
aa44ff
represents a colour with aa of red, 44 of green and ff of blue. In
decimal numbers, aa=10*16+10=170, 44=4*16+4=68
and ff=15*16+15=255. In general, to convert a two digit
hexadecimal number to decimal form, one has to multiply the value of the first digit by 16
and add the value of the second. It is not necessary to make this conversion, one can
easily learn to undestand hexadecimal expressions without having to translate them. For
most purposes, it is enough to use the 16 combinations: 00,
11, ..., ff to represent
the quantities of the primary colours that form a certain colour. With these combinations
it is possible to represent all the colours the user may need, unless his or her
perception of colour is extremely refined.
The colours of all Descates graphs are defined adding a statement of
the form colour=yellow to the configuration line,
separated by : from the other statements. Of course yellow
may be substituted by any of the predefined colours or by a hexadecimal expression.
It is recommended that the reader practices with the following
example to define several colours for the BACKGROUND, the NET, the AXES, the TEXT and the graph of the equation y=a*x^2+b*x+c.
The reader should remember that to make these changes on the
configuration, he or she must click the config button, then select the tool
(in this case COLORS or EQUATIONS),
make the changes and click the test button.
This table shows the hexadecimal expressions of the predefined
colours and their names in spanish:
black |
negro |
000000 |
darkGray |
grisObscuro |
404040 |
gray |
gris |
808080 |
lightGray |
grisClaro |
c0c0c0 |
white |
blanco |
ffffff |
magenta |
magenta |
ff00ff |
blue |
azul |
0000ff |
cyan |
turquesa |
00ffff |
green |
verde |
00ff00 |
yellow |
amarillo |
ffff00 |
orange |
naranja |
ffc800 |
red |
rojo |
ff0000 |
pink |
rosa |
ffafaf |
Introduction Appetizer Examples Documentation Applications
Work plan
 |
|
Ministerio de Educación, Cultura y Deporte. Aņo 2000 |
|
|