Visual PRO/5 and Color
Visual PRO/5 Color Map
There are two ways that a character-based Visual PRO/5 application may
display portable colors. One is to use the named color mnemonics ('RED',
'BLUE', 'BLACK', and others), and the other is to use the 'RGB' mnemonic
to synthesize up to 64 distinct colors. Many business applications use
colors to make displays more readable and the users more productive. However,
a combination of colors that looks pleasing on one type of monitor may
not look good on another.
The Visual PRO/5 Color Map dialog removes this problem by allowing users
to assign sixteen commonly used color mnemonics to any of the more than
16 million possible colors displayable through Windows. The bright (foreground)
and dim (background) variations of all eight named color mnemonics may
be reassigned in this manner. These color mappings are completely transparent
to your application.
To use this feature, choose Color
map... from the Settings
menu. The Visual PRO/5 Color Map dialog appears. The Dim and Bright squares
show the appearance of the color currently assigned to that Visual PRO/5
color mnemonic.
Clicking the mouse on any of the squares causes the 'RGB' value of that
color to be reflected by the red, green, and blue scrollbar settings.
The scrollbars may then be adjusted.
The following buttons work with the Color Map.
To |
Select |
Apply and save your changes. |
OK |
Dismiss the Visual PRO/5 Color Map dialog without reassigning any colors. |
Cancel |
Set all of the color squares to their original system default values. However, the Visual PRO/5 Color Map dialog is not dismissed, and the default assignments are not applied until you click Try or OK. |
Default All |
Temporarily apply the new color assignments to the image in the terminal window. The Visual PRO/5 Color Map dialog remains onscreen so you can continue editing. |
Try |
When Visual PRO/5 first starts up, the foreground or bright mode, 'SF',
is enabled, and the text color is 'WHITE'. The background color is 'BLACK'.
Thus, remapping the "Dim BLACK" and "Bright WHITE"
colors will change the appearance of the initial display. Remapping other
colors affects what will happen if and when those colors are displayed.
For example, unless there is something 'BLUE' on the screen, remapping
'BLUE' will have no effect. You will only see the change when something
'BLUE' is on the screen.
The Visual PRO/5 Color Map (like Microsoft Windows) is capable of defining
and displaying over 16 million colors (224 to be exact). If your display
driver is configured to display a small number of colors (16 or 256),
many of the possible colors cannot be displayed. Most display drivers
use a technique called dithering or pixellating to approximate those missing
colors. This technique combines dots of different colors placed close
together, offering an illusion of a color that is not really there.
Characters displayed in the Visual PRO/5 terminal window are never displayed
in dithered colors. The closest available color (according to Microsoft
Windows) is used. Background colors may be dithered. However, dithered
colors do not work the same on all display drivers.
Scrolling the window can have unpredictable results with some dithered patterns.
The 'RGB' Mnemonic and the Color Map
The 'RGB' mnemonic gives PRO/5 the ability to synthesize 64 colors on
hardware that is capable of displaying them. Some PRO/5 platforms permit
the use of all 64 colors, others are limited to eight colors and a bright
attribute, while still others offer no support for colors at all.
Many PRO/5 programs access colors with the named color mnemonics, such
as 'RED' or 'BLUE'. If these mnemonics are used, the appearance of the
colors will be consistent among the various platforms supporting color
displays.
However, some PRO/5 programs using the 'RGB' mnemonic were developed on
hardware capable of displaying only eight colors. When these programs
run in environments supporting more colors, the colors often appear differently
than the programmer intended.
We have provided an option, "map_RGB_colors", in the pro5.ini file, which is used in VPRO/5 1.x.
The registry (HKCU/Software/BASIS and subkeys) is used for VPRO/5 2.x
and above. Ordinarily this is set to "n", meaning that colors
synthesized with 'RGB' may use the full range of 64 colors, as originally
designed.
If the pro5.ini
file is edited and "map_RGB_colors" is changed to "y",
the ability to synthesize 64 colors is lost. Instead, all 64 combinations
are mapped to the named colors, permitting programs that cannot make effective
use of 64 colors to display properly. These colors may then be further
adjusted through the use of the Visual PRO/5 Color Map dialog.
Ordinarily, 'RGB' colors are absolute and may not be mapped. It is assumed
that the 'RGB' mnemonic is used because the programmer wants to choose
specific colors.