|
- Forum - iziBasic
Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 257
Sujet n° 1453 |
way to print white text on black background? |
le 23/09/2006 @ 22:56 par Dave O\'Brien
|
For certain error conditions, I'd like to highlight text.
I currently use GPRINT with a foreground and background color, and that works well for color devices.
However, for older B&W devices (likely with OS < 3.5), the FG and BG colors are not supported (for example, my old Visor with OS 3.1).
Is there a way to print white text on a black background for these older devices? |
|
|
Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Réponse n° 1 -------- le 24/09/2006 @ 17:56 par aldweb
visiteur |
Hello Dave,
First of all one needs to detect the screen capabilities: the SCREENMODES function will return the best screen mode available on the device. If a null value is returned, then this is a b&w device.
Second, the Palm OS native functions to set and retrieve front and back-colors only work with Palm OS >= 3.5, this is why I have GPRINT check not to work with Palm OS < 3.5. But it would be easy to extend GPRINT in a next version of iziBasic, for backward compatibility, to draw in normal or inverted mode for old devices.
In the meantime, you may develop a quick PP applet, a little bit like the one I proposed before implementing GPRINT (but much easier and with less code in it), using the WinDrawInvertedChars Palm OS API.
Cheers,
@+ aldweb |
|
|
sujet actif
sujet clos
Important!
Nouveau message -
Rectifier message
Clôturer sujet
Remonter
|
|