home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Zodiac Super OZ
/
MEDIADEPOT.ISO
/
FILES
/
13
/
N_B_V203.ZIP
/
ATTRS.DMO
< prev
next >
Wrap
Text File
|
1996-07-04
|
3KB
|
47 lines
$if 0
┌──────────────────────────╖ PowerBASIC v3.20
┌──┤ DASoft ╟──────────────────────┬──────────────────╖
│ ├──────────────────────────╢ Copyright 1995 │ DATE: 1995-10-01 ╟─╖
│ │ FILE NAME ATTRS .DMO ║ by ╘════════════════─ ║ ║
│ │ ║ Don Schullian, Jr. ║ ║
│ ╘══════════════════════════╝ ║ ║
│ A license is hereby granted to the holder to use this source code in ║ ║
│ any program, commercial or otherwise, without receiving the express ║ ║
│ permission of the copyright holder and without paying any royalties, ║ ║
│ as long as this code is not distributed in any compilable format. ║ ║
│ IE: source code files, PowerBASIC Unit files, and printed listings ║ ║
╘═╤═════════════════════════════════════════════════════════════════════╝ ║
│ .................................... ║
╘═══════════════════════════════════════════════════════════════════════╝
$endif
$INCLUDE "DAS-NBT1.INC"
COLOR 7, 0
CLS
? "┌────────────────────────────────────────────────────────────────────────
? "│ fColor2Attr? ( Fgrnd?, Bgrnd? )
? "│ fInvAttr? ( Attr? )
? "│ Attr2Color ( Attr?, Fgrnd?, Bgrnd? )
? "│ fSwapAttr? ( Attr? )
? "├─────────────────────────────────────────────────────────────────────────────
? "│ The DASoft text printing routines all work with a single color attribute
? "│ byte. fColor2Attr? and Attr2Color are simple interfaces from/to PowerBASIC's
? "│ COLOR statement and the attributes. They really have no place in a program
? "│ as they would take unnecessary space but are provided here for training.
? "│ fInvAttr? swaps the foreground, background and sets blink correctly
? "│ fSwapAttr? swaps the foreground and background colors
? "│ The big difference in these two is that fInvAttr should be used when
? "│ you've got BlinkOff and fSwapAttr? when you've got BlinkOn
? "└─────────────────────────────────────────────────────────────────────────────
PRINT "fColor2Attr?( 0, 7 ) = "; fColor2Attr?( 0, 7 )
Attr2Color 112, Fgrnd?, Bgrnd?
PRINT " Attr2Color 112, Fgrnd?, Bgrnd? ";
PRINT USING "loads: Fgrnd? =## Bgrnd? =##"; Fgrnd?, Bgrnd?
' ──────────────────────────────────────────────────────────────────────────
PRINT "fInvAttr? ( 254 ) ="; fInvAttr? ( 254 )
PRINT "fSwapAttr?( 112 ) ="; fSwapAttr?( 112 )