<< Click to Display Table of Contents >> Navigation: 3. Script Language > Image/Pixel-Color Operations > Undercover and Graphics > Undercover Operations |
MiniRobotLanguage (MRL)
UCV.foreground
UCV.fgr
Change color of foreground Print/Pixel/Paint commands
Intention
This command will change the foreground color of any soon to be used graphic command that will draw onto the cover (print/write/pixel etc.).
General usage is simple:
' Make a completely green cover
UCV.bgr|&H00FF00
' Set red foreground color
UCV.fgr|&HFF0000
UCV.cov
' Print in red onto the green background
UCV.print|Hello world!
' Here comes your script, we use a PAUSE command instead
PAU.5
' Switch cover color to yellow
UCV.bgr|&HFFFF00
UCV.print|Hello world!
' This will remove the Cover
UCV.
ENR.
You can print a text on the cover, like this:
' Make a completely red cover
UCV.bgr|&HFF0000
UCV.cov
' Here comes your script, we use a PAUSE command instead
PAU.5
' Switch cover color to yellow
UCV.bgr|&HFFFF00
' Print on the cover screen
UCV.print|Hello world
' This will remove the Cover
UCV.
ENR.
As you can see, the "background" command will also influence the background of the color of the "print" command.
Any cover is been removed immediately, when the script-process ends or when the script runs into an error.
The desktop-cover behavior can be changed/customized using the additional features:
UCV.transparency
UCV.no transparency
UCV.no blend
UCV.no blend-in
UCV.no blend-out
UCV.write
' this line will remove the cover
UCV.close
WHile "Matte" is a "dark glas", you can make the desktop-cover half transparent, by prefixing the script with:
UCV.tra
UCV.dc
PAU.10
' This line will remove the cover
UCV.
* PopUp-Menus and other TopMost Forms may be able to get temporarily in front of the Cover-form. This is due to windows-technical reasons and not a bug.
Syntax
UCV.foreground|P1
UCV.fgr|P1
Parameter Explanation
P1 - Color- value, for example 16711945 or in hexadezimal: &HFF00FF which are both
the same values.
Important notice: You can set the color values also to these three negative values:
-1 -> the DEFAULT foreground/background color is used
-2 -> the background is just not painted, allowing the content behind to become visible
-3 -> the existing color is not changed
Example
'***********************************
' UCV.-Sample
'
'***********************************
'
UCV.tra
UCV.nb
UCV.dc
UCV.fgr|&HFF00FF
UCV.write|Hallo world!|10,200
PAU.3
' This line will remove the cover
PAU.5
UCV.
ENR.
'***********************************
' UCV.-Sample 2
'
'***********************************
'
' Make a completely red cover
UCV.bgr|&H0000FF
UCV.cov
' Here comes your script, we use a PAUSE command instead
PAU.5
' Switch cover color to yellow
UCV.bgr|&H00FFFF
' Print on the cover screen
UCV.print|Hello world
' This will remove the Cover
UCV.
ENR.
'***********************************
' UCV.-Sample 3
'
'***********************************
'
UCV.cover
PAU.5
UCV.mat
PAU.5
UCV.
ENR.
'***********************************
' UCV.-Sample 4
' Write a text into the cover'
'***********************************
'
UCV.nb
UCV.cover
UCV.set font|futura t|100|||0
UCV.write|Hallo world!|10,200
PAU.3
' This line will remove the cover
PAU.5
UCV.
ENR.
Remarks
-
Limitations:
PopUp-Menus and other TopMost Forms may be able to get temporarily in front of the Cover-form. This is due to windows-technical reasons and not a bug.
See also:
• ! Smart Package Robot 's Undercover Operations
• ! UCV. - Undercover Graphics