📄 ai.txt
字号:
Offset: Type: Description:
00h WORD Length of data following(4 + textlen)
02h WORD X-coordinate to plot text at
04h WORD Y-coordinate to plot text at
06h TEXT The text string. The number of characters is determined by
the length in the WORD at 00h (-4).
function 27h HCCHST(X) - Text Character String at Current Position
Writes a text string at the current position in the current font.
Parameter Block:
Offset: Type: Description:
00h WORD Length of data following(0 + textlen)
02h TEXT The text string. The number of characters is determined by
the length in the WORD at 00h.
function 28h ABLOCKMFI(X) - Write Character Block
Writes a block of characters to the display
Parameter Block:
Offset: Type: Description:
00h WORD Length of data following(9)
02h BYTE Start X position (column)
03h BYTE Start Y position (row)
04h BYTE Width of block in characters
05h BYTE Height of block in characters
06h DWORD Pointer to character block
Each character occupies one DWORD:
Bit 8-9 Font number
12 Background transparent if set, opaque if clear
13 Overstrike
14 Reverse Video
15 Underscore
16-19 Foreground color
20-23 Background color
24-31 Character code
0Ah BYTE Number of characters in block
function 29h ABLOCKCGA(X) - Write Character Block (CGA)
Writes a block of characters to the display
Parameter Block:
Offset: Type: Description:
00h WORD Length of data following(10)
02h BYTE Start X position (column)
03h BYTE Start Y position (row)
04h BYTE Width of block in characters
05h BYTE Height of block in characters
06h DWORD Pointer to character block
Each character occupies one WORD:
Bit 0-3 Foreground color
4-7 Background color
8-15 Character code
0Ah BYTE Number of characters in block
0Bh BYTE Attribute of the text
Bit 0-1 Font selection
4 Set for transparent background, clear for opaque
background (use characters background color)
5 Overstrike
6 Reverse Video
7 Underline
function 2Ah AERASE(X) - Erase Rectangle
Clears a rectangle to the specified background color
Parameter Block:
Offset: Type: Description:
00h WORD Length of data following(5)
02h BYTE Starting column
03h BYTE Starting Row
04h BYTE Number of Columns
05h BYTE Number of Rows
06h BYTE Bits 0-3 Reserved, should be 0
4-7 Background color
function 2Bh ASCROLL(X) - Scroll Rectangle
Scrolls a rectangle of character cells
Parameter Block:
Offset: Type: Description:
00h WORD Length of data following(6)
02h BYTE Starting character column of source
03h BYTE Starting character row of source
04h BYTE Number of character columns of area
05h BYTE Number of character rows of area
06h BYTE Starting character column of destination
07h BYTE Starting character row of destination
Note: both source and destination must be entirely on screen
function 2Ch ACURSOR(X) - Set Cursor Position
Moves the text-cursor
Parameter Block:
Offset: Type: Description:
00h WORD Length of data following(2)
02h BYTE New X position in character Columns
03h BYTE New Y position in character Rows
function 2Dh ASCUR(X) - Set Cursor Shape
Sets the shape of the text cursor
Parameter Block:
Offset: Type: Description:
00h WORD Length of data following(3)
02h BYTE Cursor start line. 0=top
03h BYTE Cursor stop line
04h BYTE Cursor Attributes
00h Normal cursor
01h Hidden cursor
02h Left arrow cursor
03h Right arrow cursor
function 2Eh ASFONT(X) - Set Character Set
Defines the character set
Parameter Block:
Offset: Type: Description:
00h WORD Length of data following(6)
02h BYTE Font number
03h BYTE Reserved
04h DWORD Address of the character set definition block:
Offset: Type: Description:
00h BYTE Reserved
01h BYTE Type of character set
00h Bitmapped
03h Short stroke vector
02h BYTE Reserved
03h DWORD Reserved
07h BYTE Cell width in pixels
08h BYTE Cell height in pixels
09h BYTE Reserved
0Ah WORD Cell size (height*width/8 rounded up to
nearest number of bytes).
0Ch WORD Flags
Bit 13 Set for proportionally spaced font
14 Set for color bitmapped fonts,
clear for mono bitmapped fonts
Other bits must be 0.
0Eh DWORD Address of index table. One WORD for each
character code (see Initial and Final
codes in bytes 16h and 17h). Marks the
start of each character definition
(bitmap/stroked line) relative to the
start of the character definition table.
12h DWORD Address of character width table
Two bytes per character code. The first is
the indention in pixels from the left, the
second the indention in pixels from the
right, thus non-zero values makes the
character thinner.
Only used for proportionally spaced fonts
16h BYTE Initial code point. First character code
in the font tables.
17h BYTE Final code point. Last character code in the
font tables.
18h DWORD Address of character definition table. For
bitmapped fonts each character is defined
as a two-dimensional array of bits
occupying the minimum number of bytes per
character, I.e. an 11x9 font occupies 13
bytes. For Short Stroke vector fonts each
character is defined by a series of
draw/move commands each occupying one
byte, terminated by a null (00h) byte.
Each command byte is defined as:
Bit 0-3 Length in pixels projected onto the
X or Y axis
4 Clear for move, set for draw
5-7 Direction
0: 0 degrees (increasing X)
1: 45 degrees
2: 90 degrees (increasing Y)
3: 135 degrees
4: 180 degrees (decreasing X)
5: 225 degrees
6: 270 degrees (decreasing Y)
7: 315 degrees
1Ch WORD Reserved
1Eh DWORD Address of 2nd character table
For Color Bitmapped Fonts where the
foreground color is NOT FFFFFFFFh this table
and the 3rd character table are ORed with the
primary character definition table to
produce one table. The image is drawn with
the current foreground color and mix on the
current background color and mix.
22h WORD Reserved
24h DWORD Address of 3rd character table. See the
description under the 2nd char table.
function 2Fh AXLATE(X) - Assign Alpha Attribute Color Index Table
Defines character attribute to color translations.
Parameter Block:
Offset: Type: Description:
00h WORD Length of data following(128)
02h 16DWORDs Foreground Character Attribute (bits 4-7) translation
table. One DWORD for each of 16 attribute combinations
42h 16DWORDs Background Character Attribute (bits 0-3) translation
table. One DWORD for each of 16 attribute combinations
function 30h HINIT(X) - Initialize State
Sets the Task State buffer to the adapter dependent initial state
Parameter Block:
Offset: Type: Description:
00h WORD Length of data following(2)
02h WORD Segment address of the Task State buffer, offset is 0.
function 31h HSYNC(X) - Synchronize Adapter
Sets the adapter state to the state store in the specified task buffer.
Used to implement task switching in a multi-tasking environment
Parameter Block:
Offset: Type: Description:
00h WORD Length of data following(2)
02h WORD Segment of the Task state buffer
function 32h HMRK(X) - Marker at Given Position
Places a marker symbol at each position given.
Parameter Block:
Offset: Type: Description:
00h WORD Length of data following(4*Number_of_points)
...
4*N+2 WORD X-coordinate of Nth point
4*N+4 WORD Y-coordinate of Nth point
function 33h HCMRK(X) - Marker at Current Position
Draws a marker (defined by HSMARK) at the current position and each point in
the data block. The marker is drawn around the point.
Parameter Block:
Offset: Type: Description:
00h WORD Length of data following(4*Number_of_points)
...
4*N+2 WORD X-coordinate of Nth point
4*N+4 WORD Y-coordinate of Nth point
function 34h HSMARK(X) - Set Marker Shape
Sets the shape of the marker symbol
Parameter Block:
Offset: Type: Description:
00h WORD Length of data following(10 or 14)
02h BYTE Mark width in pixels
03h BYTE Mark height in lines
04h BYTE Flags
Bit 0-5 Reserved, set to 0
6 (XGA and ImageAdapter/A only) For color data:
0: 1pixel/byte, 1: packed pixel format
7 0: Monochrome: Marker is drawn with current
foreground color&mix on the background color&mix,
1: Color: Marker is drawn in the color from the
color data (Byte 0Ch) on the current background
color&mix
05h BYTE Reserved
06h WORD Size of mark definition data
08h DWORD Address of mark definition. A packed monochrome bitmap
This field only present if length = 14
0Ch DWORD Address of mark color data. Either one pixel/byte or packed
pixel data if byte 4 bit 6 set.
function 35h HSLPC(X) - Save Line Pattern Count
Saves the line pattern count.
Parameter Block:
Offset: Type: Description:
00h WORD Length of data following(0, 2 for XGA and ImageAdapter/A)
The following field only present if length=2 (XGA and ImageAdapter/A)
02h WORD Line pattern count stored in this word.
function 36h HRLPC(X) - Restore Line Pattern Count
Restores a previously saved line pattern count.
Parameter Block:
Offset: Type: Description:
00h WORD Length of data following(0, 2 for XGA and ImageAdapter/A)
02h WORD Optional line pattern count to use for restore
Only present for XGA and ImageAdapter/A versions
function 37h HQCP(X) - Query Current Position
Returns the current position
Parameter Block:
Offset: Type: Description:
00h WORD Length of data following(4)
02h WORD Current X coordinate
04h WORD Current Y coordinate
function 38h HQDFPAL(X) - Query Default Palette
Returns the default palette RGB values
Parameter Block:
Offset: Type: Description:
00h WORD Length of data following(64)
02h 16DWORDs One DWORD for each of the 16 primary color indices with the
RGB value currently in use for that index.
Primary colors:
0: Black 1: Blue 2: Green, 3: Cyan
4: Red 5: Magenta 6: Brown 7: White
8: Grey 9: Lt Blue 10: Lt Green 11: Lt Cyan
12: Lt Red 13: Lt Magenta 14: Yellow 15: Bright White
function 39h HSPAL(X) - Save Palette
Saves the palette in a format ready for loading with HRPAL
Parameter Block:
Offset: Type: Description:
00h WORD Length of data following(get from HQDPS)
02h BYTEs Palette buffer, get size from HQDPS
function 3Ah HRPAL(X) - Restore Palette
Restores a previously saved palette
Parameter Block:
Offset: Type: Description:
00h WORD Length of data following(up to 768)
02h 768BYTEs Palette data, up to 256 * 3BYTEs, see HQDPS for exact size
function 3Bh HSAFP(X) -
Sets the area fill plane for areafill, raster text and marker operation.
Only needed if the default bitmap has been changed with HSBMAP.
Parameter Block:
Offset: Type: Description:
00h WORD Length of data following(5)
02h DWORD Address of area fill plane. Linear offset into the video
memory, must be a multiple of 4.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -