| TIP: Click on subject to list as thread! | ANSI |
| echo: | |
|---|---|
| to: | |
| from: | |
| date: | |
| subject: | screen color in OS/2 |
David Etheredge wrote in a message to All: DE> I am writing a program designed for the OS/2 full screen mode Why are you targeting full screen? It is very rarely needed these days. DE> and need to use different colored characters on the DE> screen. In dos,there are textcolor() and textbackground() DE> procedures prototyped in conio.h. These functions are unique to Borland compilers, not to the operating system. DE> These are missing in OS/2 C-set. Yes. DE> I know that in many cases, I can use ANSI escape DE> sequences yo acomplish this. Is this always acceptable in DE> OS/2? Does OS/2 accept ANSI escape sequences by default or DE> do I need to check to see if an ANSI driver is loaded? There is always ANSI support available, although it may not be enabled. You can use the API calls VioGetANSI() to find out what the state is by default and VioSetANSI() if you need to change it. DE> Is there another alternative? ANSI is actually a good approach. You could use other VioXxxxx() API calls to manage the video attributes explicitly if you like. Much of the Vio API is also accessible in Family Mode programs which are specially linked to run under both OS/2 and DOS. DE> Can I use the BIOS video calls to set color? No. The operating system cannot be bypassed under OS/2. DE> What about direct screen writes, from what I DE> understand, OS/2 does not like that at all. The facility does exist, and API calls such as VioGetBuf() and VioGetPhysBuf() do exist for this purpose. However, the regular Vio subsystem is quite fast. DE> Thanks, Any help is appreciated. What you want is the documentation for the Vio API calls: PRCP.ZIP, 412 KB, available here for FReq or download. -- Mike ---* Origin: N1BEE BBS +1 401 944 8498 V.34/V.FC/V.32bis/HST16.8 (1:323/107) SEEN-BY: 105/42 620/243 711/401 409 410 413 430 807 808 809 934 955 712/407 SEEN-BY: 712/515 628 704 713/888 800/1 7877/2809 @PATH: 323/107 150 3615/50 396/1 270/101 105/103 42 712/515 711/808 809 934 |
|
| SOURCE: echomail via fidonet.ozzmosis.com | |
Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.