This library contains functions to inquire about a multitude of set attributes. The following routines are available for this purpose:
• vq_cellarray | Inquires the definition of a colour selection cell array |
• vq_color | Gets colour intensity information |
• vq_devinfo | Inquires status of an output device |
• vq_ext_devinfo | Gets information about a GDOS driver |
• vq_extnd | Gets additional information about the configuration of a workstation |
• vq_ptsinsz | Internal function from GDOS |
• vq_scrninfo | Gets information about screen format |
• vqf_attributes | Gets fill attributes |
• vqf_bg_color | Gets object background colour |
• vqf_fg_color | Gets object foreground colour |
• vqin_mode | Inquires input mode of an input device |
• vql_attributes | Gets line attributes |
• vql_bg_color | Gets line background colour |
• vql_fg_color | Gets line foreground colour |
• vqm_attributes | Gets marker atttributes |
• vqm_bg_color | Gets marker background colour |
• vqm_fg_color | Gets marker foreground colour |
• vqr_bg_color | Gets bitmap background colour |
• vqr_fg_color | Gets bitmap foreground colour |
• vqt_advance | Gets position for next vector character |
• vqt_advance32 | Gets more exact position for next vector character (fix31). |
• vqt_attributes | Gets text attributes |
• vqt_cacheinfo | No information available at present |
• vqt_cachesize | Gets size of the vector character cache |
• vqt_char_index | Converts index from/ to given mappings |
• vqt_devinfo | Inquires status of an output device |
• vqt_drv_avail | No information available at present |
• vqt_ext_name | Extended function for obtaining font information |
• vqt_extent | Calculates dimensions of a text bounding rectangle |
• vqt_f_extent | Calculates dimensions of a text for vector fonts |
• vqt_f_extent16 | Calculates dimensions of a text for 16-bit Speedo character indexed text |
• vqt_bg_color | Gets text background colour |
• vqt_fg_color | Gets text foreground colour |
• vqt_fontheader | Gets information about a font header |
• vqt_fontinfo | Gets information about a font |
• vqt_get_table | Inquires address of the character transformation tables |
• vqt_justified | Inquires offsets from an alignment point |
• vqt_name | Gets name and index of a font |
• vqt_name_and_id | Finds font ID and name |
• vqt_pairkern | Gets adjustment vector information for kerning of a character pair |
• vqt_real_extent | Gets bounding rectangle around a text |
• vqt_trackkern | Gets adjustment vectors for fonts with track-kerning |
• vqt_width | Calculates width of a character cell |
• vqt_xfntinfo | Gets information about a font |
• v_create_driver_info | Gets information about a driver |
• v_delete_driver_info | Deletes information about a driver |
• v_get_driver_info | Gets extended information about a driver |
• v_getbitmap_info | Gets placement information about the bitmap of a vector character |
• v_read_default_settings | Gets default printer settings |
• v_write_default_settings | Sets the default printer settings |
Note: Besides general attributes, the functions listed here can obtain extensive information about text handling.
See also: VDI workstations Style guidelines
Name: | »Inquire current fill area attributes« - Obtain the
attributes for filling area
| ||||||||||||||||||||
Opcode: | 37
| ||||||||||||||||||||
Syntax: | void vqf_attributes ( int16_t handle, int16_t *attrib );
| ||||||||||||||||||||
Description: | The call vqf_attributes reports back the current attributes for
filled graphic objects.
| ||||||||||||||||||||
Return value: | The function does not return a result.
| ||||||||||||||||||||
Availability: | Supported by all devices.
| ||||||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||||||
See also: | Binding vswr_mode vs_color vsf_interior vsf_style
vsf_color vsf_perimeter
|
C: | void vqf_attributes ( int16_t handle, int16_t *attrib );
|
Binding: |
void vqf_attributes (int16_t handle, int16_t *attrib) { contrl[0] = 37; contrl[1] = 0; contrl[3] = 0; contrl[6] = handle; vdi (); attrib[0..4] = intout[0..4]; } |
GEM-Arrays: |
|
Name: | »Inquire background colour« - Obtain object background
colour.
| ||||||||
Opcode: | 203 (Sub-Opcode 1)
| ||||||||
Syntax: | int32_t vqf_bg_color( int16_t handle, COLOR_ENTRY *bg_color );
| ||||||||
Description: | The call vqf_bg_color obtains the background colour for graphic
objects.
| ||||||||
Return value: | Set colour space (at present only CSPACE_RGB), or -1 (invalid
subfunction number).
| ||||||||
Availability: | As of NVDI 5.00.
| ||||||||
Group: | Inquire functions
| ||||||||
See also: | Binding
|
C: | int32_t vqf_bg_color( int16_t handle, COLOR_ENTRY *bg_color );
| ||||||||||||||||||||||||||||||
Binding: |
int32_t vqf_bg_color( int16_t handle, COLOR_ENTRY *bg_color ) { contrl[0] = 203; contrl[1] = 0; contrl[3] = 0; contrl[5] = 1; contrl[6] = handle; vdi (); bg_color = intout [2..5]; return ( int32_t intout [0] ); } | ||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire Foreground Color« - Obtain object foreground colour.
| ||||||||
Opcode: | 202 (Sub-Opcode 1)
| ||||||||
Syntax: | int32_t vqf_fg_color( int16_t handle, COLOR_ENTRY *fg_color );
| ||||||||
Description: | The call vqf_fg_color obtains the foreground colour for graphic
objects.
| ||||||||
Return value: | Set colour space (at present only CSPACE_RGB), or -1 (invalid
subfunction number).
| ||||||||
Availability: | As of NVDI 5.00.
| ||||||||
Group: | Inquire functions
| ||||||||
See also: | Binding
|
C: | int32_t vqf_fg_color( int16_t handle, COLOR_ENTRY *fg_color );
| ||||||||||||||||||||||||||||||
Binding: |
int32_t vqf_fg_color( int16_t handle, COLOR_ENTRY *fg_color ) { contrl[0] = 202; contrl[1] = 0; contrl[3] = 0; contrl[5] = 1; contrl[6] = handle; vdi (); fg_color = intout [2..5]; return ( int32_t intout [0] ); } | ||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire Input Mode« - Obtain the input mode for an input
device.
| ||||||||||||||||||||||
Opcode: | 115
| ||||||||||||||||||||||
Syntax: | void vqin_mode ( int16_t handle, int16_t dev_type, int16_t
*input_mode );
| ||||||||||||||||||||||
Description: | The call vqin_mode obtains the input status for a specified
VDI input device. The following apply:
| ||||||||||||||||||||||
Return value: | The function does not return a result.
| ||||||||||||||||||||||
Availability: | Supported by all Atari computers.
| ||||||||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||||||||
See also: | Binding vsin_mode vrq_locator vsm_locator vrq_valuator
vsm_valuator vrq_choice vsm_choice vrq_string vsm_string
|
C: | void vqin_mode ( int16_t handle, int16_t dev_type, int16_t
*input_mode );
|
Binding: |
void vqin_mode (int16_t handle, int16_t dev_type, int16_t *input_mode) { intin[0] = dev_type; contrl[0] = 115; contrl[1] = 0; contrl[3] = 1; contrl[6] = handle; vdi (); *input_mode = intout[0]; } |
GEM-Arrays: |
|
Name: | »Inquire Current Polyline Attributes« - Obtain the attributes
for drawing lines.
| ||||||||||||||||||
Opcode: | 35
| ||||||||||||||||||
Syntax: | void vql_attributes ( int16_t handle, int16_t *attrib );
| ||||||||||||||||||
Description: | The call vql_attributes returns the settings that affect the
attributes of the current line drawing functions.
Note: The statements made here (specially for attrib[4,5]) apply for the NVDI implementation. | ||||||||||||||||||
Return value: | The function does not return a result.
| ||||||||||||||||||
Availability: | Supported by all drivers.
| ||||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||||
See also: | Binding vswr_mode vs_color vsl_type vsl_width
vsl_color vsl_ends
|
C: | void vql_attributes ( int16_t handle, int16_t *attrib );
| ||||||||||||||||||||||||||||||
Binding: |
void vql_attributes (int16_t handle, int16_t *attrib) { contrl[0] = 35; contrl[1] = 0; contrl[3] = 0; contrl[6] = handle; vdi (); attrib[0..2] = intout[0..2]; attrib[3] = ptsout[0]; attrib[4..5] = intout[3..4]; } | ||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire Background Color« - Obtain lines background colour.
| ||||||||
Opcode: | 203 (Sub-Opcode 2)
| ||||||||
Syntax: | int32_t vql_bg_color( int16_t handle, COLOR_ENTRY *bg_color );
| ||||||||
Description: | The call vql_bg_color obtains the background colour for lines.
| ||||||||
Return value: | Set colour space (at present only CSPACE_RGB), or -1 (invalid
subfunction number).
| ||||||||
Availability: | As of NVDI 5.00.
| ||||||||
Group: | Inquire functions
| ||||||||
See also: | Binding
|
C: | int32_t vql_bg_color( int16_t handle, COLOR_ENTRY *bg_color );
| ||||||||||||||||||||||||||||||
Binding: |
int32_t vql_bg_color( int16_t handle, COLOR_ENTRY *bg_color ) { contrl[0] = 203; contrl[1] = 0; contrl[3] = 0; contrl[5] = 2; contrl[6] = handle; vdi (); bg_color = intout [2..5]; return ( int32_t intout [0] ); } | ||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire Foreground Color« - Obtain lines foreground colour.
| ||||||||
Opcode: | 202 (Sub-Opcode 2)
| ||||||||
Syntax: | int32_t vql_fg_color( int16_t handle, COLOR_ENTRY *fg_color );
| ||||||||
Description: | The call vql_fg_color obtains the foreground colour for lines.
| ||||||||
Return value: | Set colour space (at present only CSPACE_RGB), or -1 (invalid
subfunction number).
| ||||||||
Availability: | As of NVDI 5.00.
| ||||||||
Group: | Inquire functions
| ||||||||
See also: | Binding
|
C: | int32_t vql_fg_color( int16_t handle, COLOR_ENTRY *fg_color );
| ||||||||||||||||||||||||||||||
Binding: |
int32_t vql_fg_color( int16_t handle, COLOR_ENTRY *fg_color ) { contrl[0] = 202; contrl[1] = 0; contrl[3] = 0; contrl[5] = 2; contrl[6] = handle; vdi (); fg_color = intout [2..5]; return ( int32_t intout [0] ); } | ||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire current polymarker attributes« - Obtain the
attributes for drawing the markers.
| ||||||||||||||||
Opcode: | 36
| ||||||||||||||||
Syntax: | void vqm_attributes ( int16_t handle, int16_t *attrib );
| ||||||||||||||||
Description: | The call vqm_attributes obtains the current marker attributes
for output. The following apply:
Note: The specifications made here are valid for the implementation in NVDI and PC-GEM. | ||||||||||||||||
Return value: | The function does not return a result.
| ||||||||||||||||
Availability: | Supported by all drivers.
| ||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||
See also: | Binding vswr_mode vs_color vsm_type vsm_height
vsm_color
|
C: | void vqm_attributes ( int16_t handle, int16_t *attrib );
| ||||||||||||||||||||||||||||||
Binding: |
void vqm_attributes (int16_t handle, int16_t *attrib) { contrl[0] = 36; contrl[1] = 0; contrl[3] = 0; contrl[6] = handle; vdi (); attrib[0..2] = intout[0..2]; attrib[3] = ptsout[1]; attrib[4] = ptsout[0]; } | ||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire background colour« - Obtain marker background
colour.
| ||||||||
Opcode: | 203 (Sub-Opcode 3)
| ||||||||
Syntax: | int32_t vqm_bg_color( int16_t handle, COLOR_ENTRY *bg_color );
| ||||||||
Description: | The call vqm_bg_color obtains the background colour for
markers.
| ||||||||
Return value: | Set colour space (at present only CSPACE_RGB), or -1 (invalid
subfunction number).
| ||||||||
Availability: | As of NVDI 5.00.
| ||||||||
Group: | Inquire functions
| ||||||||
See also: | Binding
|
C: | int32_t vqm_bg_color( int16_t handle, COLOR_ENTRY *bg_color );
| ||||||||||||||||||||||||||||||
Binding: |
int32_t vqm_bg_color( int16_t handle, COLOR_ENTRY *bg_color ) { contrl[0] = 203; contrl[1] = 0; contrl[3] = 0; contrl[5] = 3; contrl[6] = handle; vdi (); bg_color = intout [2..5]; return ( int32_t intout [0] ); } | ||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire Foreground Color« - Obtain marker foreground colour.
| ||||||||
Opcode: | 202 (Sub-Opcode 3)
| ||||||||
Syntax: | int32_t vqm_fg_color( int16_t handle, COLOR_ENTRY *fg_color );
| ||||||||
Description: | The call vqm_fg_color obtains the foreground colour for
markers.
| ||||||||
Return value: | Set colour space (at present only CSPACE_RGB), or -1 (invalid
subfunction number).
| ||||||||
Availability: | As of NVDI 5.00.
| ||||||||
Group: | Inquire functions
| ||||||||
See also: | Binding
|
C: | int32_t vqm_fg_color( int16_t handle, COLOR_ENTRY *fg_color );
| ||||||||||||||||||||||||||||||
Binding: |
int32_t vqm_fg_color( int16_t handle, COLOR_ENTRY *fg_color ) { contrl[0] = 202; contrl[1] = 0; contrl[3] = 0; contrl[5] = 3; contrl[6] = handle; vdi (); fg_color = intout [2..5]; return ( int32_t intout [0] ); } | ||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire background colour« - Obtain bitmap background
colour.
| ||||||||
Opcode: | 203 (Sub-Opcode 4)
| ||||||||
Syntax: | int32_t vqr_bg_color( int16_t handle, COLOR_ENTRY *bg_color );
| ||||||||
Description: | The call vqr_bg_color obtains the background colour for
bitmaps.
| ||||||||
Return value: | Set colour space (at present only CSPACE_RGB), or -1 (invalid
subfunction number).
| ||||||||
Availability: | As of NVDI 5.00.
| ||||||||
Group: | Inquire functions
| ||||||||
See also: | Binding
|
C: | int32_t vqr_bg_color( int16_t handle, COLOR_ENTRY *bg_color );
| ||||||||||||||||||||||||||||||
Binding: |
int32_t vqr_bg_color( int16_t handle, COLOR_ENTRY *bg_color ) { contrl[0] = 203; contrl[1] = 0; contrl[3] = 0; contrl[5] = 4; contrl[6] = handle; vdi (); bg_color = intout [2..5]; return ( int32_t intout [0] ); } | ||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire foreground colour« - Obtain bitmap foreground
colour.
| ||||||||
Opcode: | 202 (Sub-Opcode 4)
| ||||||||
Syntax: | int32_t vqr_fg_color( int16_t handle, COLOR_ENTRY *fg_color );
| ||||||||
Description: | The call vqr_fg_color obtains the foreground colour for
bitmaps.
| ||||||||
Return value: | Set colour space (at present only CSPACE_RGB), or -1 (invalid
subfunction number).
| ||||||||
Availability: | As of NVDI 5.00.
| ||||||||
Group: | Inquire functions
| ||||||||
See also: | Binding
|
C: | int32_t vqr_fg_color( int16_t handle, COLOR_ENTRY *fg_color );
| ||||||||||||||||||||||||||||||
Binding: |
int32_t vqr_fg_color( int16_t handle, COLOR_ENTRY *fg_color ) { contrl[0] = 202; contrl[1] = 0; contrl[3] = 0; contrl[5] = 4; contrl[6] = handle; vdi (); fg_color = intout [2..5]; return ( int32_t intout [0] ); } | ||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire outline text advance placement vector« - Obtain
position for the next vector character.
| ||||||||||||||||
Opcode: | 247
| ||||||||||||||||
Syntax: | void vqt_advance ( int16_t handle, int16_t ch, int16_t
*x_advance, int16_t *y_advance, int16_t *remx, int16_t *remy );
| ||||||||||||||||
Description: | The call vqt_advance calculates offsets (advance vector and
remainder) to be able to write the next character of a string at the
correct position. The following apply:
Notes: x_advance and y_advance added to the position where the last character was rendered gives the place where to draw the next character. The vector works in all directions and with all text rotations. The function is required particularly when the angle for text rotation is anything but 0, 90, 180 or 270 degrees. The returned values refer only to the spacing that is used for the positioning of the next character, i.e. x_advance does not include any parts of a character that overhangs the em-square. The remx and remy remainders should be summed by the application outputting the text and used to nudge the advance vector by a pixel when required. | ||||||||||||||||
Return value: | The function does not return a result.
| ||||||||||||||||
Availability: | FSMGDOS, as of SpeedoGDOS 4.00 and from NVDI 3.00 on.
| ||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||
See also: | Binding vqt_advance32 vst_rotation SpeedoGDOS NVDI
|
C: | void vqt_advance ( int16_t handle, int16_t ch, int16_t
*x_advance, int16_t *y_advance, int16_t *remx, int16_t *remy );
| ||||||||||||||||||||||||||||||||||||
Binding: |
void vqt_advance ( int16_t handle, int16_t ch, int16_t *x_advance, int16_t *y_advance, int16_t *remx, int16_t *remy ); { intin[0] = ch; contrl[0] = 247; contrl[1] = 0; contrl[3] = 1; contrl[6] = handle; vdi (); x_advance = ptsout[0]; y_advance = ptsout[1]; remx = ptsout[2]; remy = ptsout[3]; } | ||||||||||||||||||||||||||||||||||||
GEM-Arrays: |
The returned values refer only to the spacing that is used for the positioning of the next character, i.e. x_advance does not include any parts of a character that overhangs the em-square. |
Name: | »Inquire outline text advance placement vector« - Obtain more
precise position for the next vector character as two fix31 values.
| ||||||||||||
Opcode: | 247
| ||||||||||||
Syntax: | void vqt_advance32 ( int16_t handle, int16_t ch, fix31
*x_advance, fix31 *y_advance );
| ||||||||||||
Description: | The call vqt_advance32 is a variant of vqt_advance calculating
offsets (advance vector and remainder) to be able to write the next
character of a string at the correct position, returned with greater
precision as two fix31 values. The following apply:
Notes: x_advance and y_advance added to the position where the last character was rendered gives the place where to draw the next character. The vector works in all directions and with all text rotations. The function is required particularly when the angle for text rotation is anything but 0, 90, 180 or 270 degrees. Remember that x_advance and y_advance are only offsets used to place the next character - they do not include parts of the character which extend beyond the em-square. | ||||||||||||
Return value: | The function does not return a result.
| ||||||||||||
Availability: | As of SpeedoGDOS 4.00 and as of NVDI 3.00. In the docs for
NVDI 3.00 this function is wrongly named as vqt_advance (it was
corrected in the NVDI 4.00 docs).
| ||||||||||||
Group: | Inquire functions
| ||||||||||||
See also: | Binding vst_rotation SpeedoGDOS NVDI
|
C: | void vqt_advance32 ( int16_t handle, int16_t ch, fix31
*x_advance, fix31 *y_advance );
| ||||||||||||||||||||||||||||||
Binding: |
void vqt_advance32 (int16_t handle, int16_t ch, fix31 *x_advance, fix31 *y_advance) { intin[0] = ch; contrl[0] = 247; contrl[1] = 0; contrl[3] = 1; contrl[6] = handle; vdi (); *x_advance = ptsout[4..5]; *y_advance = ptsout[6..7]; } | ||||||||||||||||||||||||||||||
GEM-Arrays: |
Remember that x_advance and y_advance are only offsets used to place the next character - they do not include parts of the character which extend beyond the em-square. |
Name: | »Inquire current graphic text attributes« - Obtain the
attributes for the writing of texts.
| ||||||||||||||||||||||||||||||||||||||||||||
Opcode: | 38
| ||||||||||||||||||||||||||||||||||||||||||||
Syntax: | void vqt_attributes ( int16_t handle, int16_t *attrib );
| ||||||||||||||||||||||||||||||||||||||||||||
Description: | The call vqt_attributes obtains the current text attributes.
The following apply:
| ||||||||||||||||||||||||||||||||||||||||||||
Return value: | The function does not return a result.
| ||||||||||||||||||||||||||||||||||||||||||||
Availability: | Supported by all drivers.
| ||||||||||||||||||||||||||||||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||||||||||||||||||||||||||||||
See also: | Binding vswr_mode vs_color vst_height vst_point
vst_rotation vst_font vst_color vst_effects vst_alignment
|
C: | void vqt_attributes ( int16_t handle, int16_t *attrib );
| |||||||||||||||||||||||||||
Binding: |
void vqt_attributes (int16_t handle, int16_t *attrib) { contrl[0] = 38; contrl[1] = 0; contrl[3] = 0; contrl[6] = handle; vdi (); attrib[0..5] = intout[0..5]; attrib[6..9] = ptsout[0..3]; } | |||||||||||||||||||||||||||
GEM-Arrays: |
Note: The Atari-VDI wrongly returns the writing mode -1 in intout[5]; with NVDI, this occurs only when error compatibility is switched on. |
Name: | »Inquire background colour« - Obtain text background colour.
| ||||||||
Opcode: | 203 (Sub-Opcode 0)
| ||||||||
Syntax: | int32_t vqt_bg_color( int16_t handle, COLOR_ENTRY *bg_color );
| ||||||||
Description: | The call vqt_bg_color obtains the background colour for text.
| ||||||||
Return value: | Set colour space (at present only CSPACE_RGB), or -1 (invalid
subfunction number).
| ||||||||
Availability: | As of NVDI 5.00.
| ||||||||
Group: | Inquire functions
| ||||||||
See also: | Binding
|
C: | int32_t vqt_bg_color( int16_t handle, COLOR_ENTRY *bg_color );
| ||||||||||||||||||||||||||||||
Binding: |
int32_t vqt_bg_color( int16_t handle, COLOR_ENTRY *bg_color ) { contrl[0] = 203; contrl[1] = 0; contrl[3] = 0; contrl[5] = 0; contrl[6] = handle; vdi (); bg_color = intout [2..5]; return ( int32_t intout [0] ); } | ||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Get outline cache size« - Obtain the size of the vector
character cache.
| ||||||||||||||
Opcode: | 255
| ||||||||||||||
Syntax: | void vqt_cachesize ( int16_t handle, int16_t which_cache,
int32_t *size );
| ||||||||||||||
Description: | The call vqt_cachesize obtains the size of the largest
allocatable block of memory in one of two vector character caches. The
following apply:
Notes: An application can estimate how much memory is needed to generate a character, and issue a warning message if one tries to exceed this. FSMGDOS will just put a message on the screen asking the user to reboot. To estimate the memory required for a given character in the character bitmap cache use the formula: (Width in pixels + 7)/8 * height in pixels The amount of memory for the data structure cache can be estimated from: 84 * (width + height) | ||||||||||||||
Return value: | The function does not return a result.
| ||||||||||||||
Availability: | FSMGDOS, as of SpeedoGDOS 4.00.
| ||||||||||||||
Group: | Inquire functions
| ||||||||||||||
See also: | Binding v_loadcache v_savecache v_flushcache
|
C: | void vqt_cachesize ( int16_t handle, int16_t which_cache,
int32_t *size );
|
Binding: |
void vqt_cachesize ( int16_t handle, int16_t which_cache, int32_t *size ); { intin[0] = which_cache; contrl[0] = 255; contrl[1] = 0; contrl[3] = 1; contrl[6] = handle; vdi (); *size = intout[0..1]; } |
GEM-Arrays: |
|
Name: | »Inquire character index« - Convert an index with reference
to given mappings.
| ||||||||||||||||||||||||
Opcode: | 190 (Opcode 0)
| ||||||||||||||||||||||||
Syntax: | uint16_t vqt_char_index ( int16_t handle, uint16_t scr_index,
int16_t src_mode, int16_t dst_mode );
| ||||||||||||||||||||||||
Description: | The call vqt_char_index converts a passed character index from
and to the desired mapping encoding.
Note: If you want to convert an index from ASCII to ASCII, only the range from 32 to 255 is used. The control codes are not translated, e.g. a call like vqt_char_index( handle, 10, 1, 0 ) returns 0xffff. For example, to determine if the font contains a character with Unicode 0x201e ("quotedblbase", DOUBLE LOW-9 QUOTATION MARK), you should use the following function: int16_t is_char_available (int16_t handle, uint16_t unicode) { uint16_t dindex; /* Translate unicode into a direct index */ dindex = vqt_char_index (handle, unicode, 2, 0); if (dindex == 0xffff) return (FALSE); /* Character is available */ else return (TRUE); /* Not available */ } | ||||||||||||||||||||||||
Return value: | This function returns the converted index, or the value 0xffff
if conversion was not possible.
| ||||||||||||||||||||||||
Availability: | since NVDI Version 4.00
| ||||||||||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||||||||||
See also: | Binding vst_charmap
|
C: | uint16_t vqt_char_index ( int16_t handle, uint16_t scr_index,
int16_t src_mode, int16_t dst_mode );
| ||||||||||||||||||||||||||||||||||||
Binding: |
uint16_t vqt_char_index ( int16_t handle, uint16_t scr_index, int16_t scr_mode, int16_t dst_mode ) { intin[0] = scr_index; intin[1] = src_mode; intin[2] = dst_mode; contrl[0] = 190; contrl[1] = 0; contrl[3] = 3; contrl[5] = 0; contrl[6] = handle; vdi (); return ( intout[0] ); } | ||||||||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire device status info« - Inquire status of the output
device.
| ||||||||||||||||||
Opcode: | 248
| ||||||||||||||||||
Syntax: | void vqt_devinfo ( int16_t handle, int16_t device, int16_t
*devexits, int8_t *devname );
| ||||||||||||||||||
Description: | The call vqt_devinfo checks whether a driver for a given output
device has been installed. The following apply:
| ||||||||||||||||||
Return value: | The function does not return a result.
| ||||||||||||||||||
Availability: | Only with FONTGDOS, FSM or SpeedoGDOS.
| ||||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||||
See also: | Binding vq_devinfo vq_ext_devinfo GDOS SpeedoGDOS
NVDI
|
C: | void vqt_devinfo ( int16_t handle, int16_t device, int16_t
*devexits, int8_t *devname );
| ||||||||||||||||||||||||||||||
Binding: |
void vqt_devinfo ( int16_t handle, int16_t device, int16_t *devexits, int8_t *devname ) { intin[0] = device; contrl[0] = 248; contrl[1] = 0; contrl[3] = 1; contrl[6] = handle; vdi (); *devexits = ptsout[0]; p = contrl[4]; dev_name[0..p-1] = intout[0..p-1]; } | ||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire text extent« - Obtain the length of a text string.
| ||||||||||||||||||||||||
Opcode: | 116
| ||||||||||||||||||||||||
Syntax: | void vqt_extent ( int16_t handle, int8_t *string, int16_t
*extent );
| ||||||||||||||||||||||||
Description: | The call vqt_extent returns the minimal bounding box of a
string of text in pixels. Correct bounding information is also output
for rotated text.
Example: The function is passed the following parameters:
Notes: If the selected font is an outline (vector) font, the character widths (vqt_width) will be added and the string (especially the leftmost and the right-most character) might exceed the returned rectangle. For this reason it may be better to fall back on the vqt_f_extent function which provides more accurate information by taking special factors into account, or the vqt_real_extent function if working under NVDI. In old GEM versions, incidentally, the function does not work correctly if the text string contains umlauts, as old GEM versions could not yet handle these properly. | ||||||||||||||||||||||||
Return value: | The function does not return a result.
| ||||||||||||||||||||||||
Availability: | Supported by all drivers.
| ||||||||||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||||||||||
See also: | Binding vst_height vst_point vst_rotation vst_font
vst_effects vqt_f_extent vqt_real_extent
|
C: | void vqt_extent ( int16_t handle, int8_t *string, int16_t
*extent );
| |||||||||||||||||||||||||||
Binding: |
void vqt_extent (int16_t handle, int8_t *string, int16_t *extent) { int16_t *tmp; tmp = intin; while (*tmp++ = *string++) ; contrl[0] = 116; contrl[1] = 0; contrl[3] = (int16_t) ((tmp-intin)-1); contrl[6] = handle; vdi (); extent[0..7] = ptsout[0..7]; } | |||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire face name and index« - Obtain information about a
font.
| ||||||||||||||||||||||||||||||||||||||||
Opcode: | 130 (Sub-Opcode 1)
| ||||||||||||||||||||||||||||||||||||||||
Syntax: | int16_t vqt_ext_name ( int16_t handle, int16_t index, int8_t
*name, uint16_t *font_format, uint16_t *flags );
| ||||||||||||||||||||||||||||||||||||||||
Description: | The call vqt_ext_name obtains information about a font (or
face). The following apply:
Note: A font is classified as a symbol font when it is not complete in the region 'A'-'Z' and 'a'-'z', or if it is pictorial according to the PANOSE classification. The relevant flag is therefore to be treated only as a clue (it would also be set for a cyrillic TrueType font, for instance), and signals that the character assignments correspond to ASCII mapping (vst_charmap) and not the normal Atari assignments. | ||||||||||||||||||||||||||||||||||||||||
Return value: | The function returns the ID of the font.
| ||||||||||||||||||||||||||||||||||||||||
Availability: | As of NVDI 3.00.
| ||||||||||||||||||||||||||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||||||||||||||||||||||||||
See also: | Binding vst_load_fonts vst_font vqt_xfntinfo
|
C: | int16_t vqt_ext_name ( int16_t handle, int16_t index, int8_t
*name, uint16_t *font_format, uint16_t *flags );
| ||||||||||||||||||||||||||||||||||||||||||
Binding: |
int16_t vqt_ext_name (int16_t handle, int16_t index, int8_t *name, uint16_t *font_format, uint16_t *flags) { intin[0] = index; intin[1] = 0; /* Reserved */ contrl[0] = 130; contrl[1] = 0; contrl[3] = 2; contrl[5] = 1; contrl[6] = handle; vdi (); name[0..31] = intout[1..32]; name[32] = intout[33]; *flags = (intout[34] >> 8) & 0xff; *font_format = intout[34] & 0xff; return ( intout[0] ); } | ||||||||||||||||||||||||||||||||||||||||||
GEM-Arrays: |
Notes: The high byte of intout[34] returns flags; the low byte of intout[34] returns font_format. To ascertain what type of font one is dealing with, one has to note the number of entries in intout (contrl[4]). If contrl[4] is 33, then no additional information is present, and hence we are dealing with a bitmap font. If contrl[4] == 34, then additionally intout[33] (name[32]) just communicates whether we are dealing with a vector font. Only if contrl[4] == 35, one can ascertain from intout[34] (flags) the font type more exactly, and recognize immediately whether the font is monospaced. intout[34] is only returned when contrl[3] > 1 and contrl[5] = 1! |
Name: | »Inquire foreground colour« - Obtain text foreground colour.
| ||||||||
Opcode: | 202 (Sub-Opcode 0)
| ||||||||
Syntax: | int32_t vqt_fg_color( int16_t handle, COLOR_ENTRY *fg_color );
| ||||||||
Description: | The call vqt_fg_color obtains the foreground colour for text.
| ||||||||
Return value: | Set colour space (at present only CSPACE_RGB), or -1 (invalid
subfunction number).
| ||||||||
Availability: | As of NVDI 5.00.
| ||||||||
Group: | Inquire functions
| ||||||||
See also: | Binding
|
C: | int32_t vqt_fg_color( int16_t handle, COLOR_ENTRY *fg_color );
| ||||||||||||||||||||||||||||||
Binding: |
int32_t vqt_fg_color( int16_t handle, COLOR_ENTRY *fg_color ) { contrl[0] = 202; contrl[1] = 0; contrl[3] = 0; contrl[5] = 0; contrl[6] = handle; vdi (); fg_color = intout [2..5]; return ( int32_t intout [0] ); } | ||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire Speedo header information« - Obtain information
about a Speedo font.
| ||||||||||
Opcode: | 232
| ||||||||||
Syntax: | void vqt_fontheader ( int16_t handle, int8_t *buffer, int8_t
*tdf_name );
| ||||||||||
Description: | The call vqt_fontheader copies the header of the current Speedo
font file into buffer and returns a pointer to the TDF file.
Notes: The buffer should have a size of 1 kbyte, as the header size depends on the font and extensions of the font format. tdf_name should point to a buffer of at least 128 bytes into which the full pathname of the font's TDF file will be copied. If the selected (vector) font is not a Speedo font (TrueType, ...) the VDI tries to create a virtual header with the important information. You should consider that each vqt_fontheader call can lead to several disk accesses (depending on the font format) - if a user has installed 300 or more fonts (which can happen very easily if you use high quality fonts with a lot of font styles), this will take a few seconds. If necessary, save font information and load (and update) it when your program is started. | ||||||||||
Return value: | The function does not return a result.
| ||||||||||
Availability: | As of SpeedoGDOS 4.00, and from NVDI 3.00 onwards.
| ||||||||||
Group: | Inquire functions
| ||||||||||
See also: | Binding vqt_fontinfo Make-up of the font-header
|
C: | void vqt_fontheader ( int16_t handle, int8_t *buffer, int8_t
*tdf_name );
| |||||||||||||||||||||||||||
Binding: |
void vqt_fontheader (int16_t handle, int8_t *buffer, int8_t *tdf_name) { intin[0..1] = buffer; contrl[0] = 232; contrl[1] = 0; contrl[3] = 2; contrl[6] = handle; vdi (); tdf_name[0..n-1] = intout[0..n-1]; } | |||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire current face information« - Obtain information about
the current font.
| ||||||||||||||||||||||||||||
Opcode: | 131
| ||||||||||||||||||||||||||||
Syntax: | void vqt_fontinfo ( int16_t handle, int16_t *minADE, int16_t
*maxADE, int16_t *distances, int16_t *maxwidth, int16_t *effects );
| ||||||||||||||||||||||||||||
Description: | The call vqt_fontinfo returns information about the current
font.
The function is passed the following parameters:
Note: Special effects and enlargement are taken into account. With skewed text (pseudo-italic) the slope is best considered as a right and a left offset value. The right offset value is the horizontal distance between the character position (left end of baseline) to the plumb-line (drop-down) point on the baseline from the top right corner of the bounding box; similarly, the left offset value is the distance from the character position to the plumb-line point from the baseline to where it would meet the bottom left corner of the character's bounding box. The components minADE and maxADE represent the first and last character of the font respectively. | ||||||||||||||||||||||||||||
Return value: | The function does not return a result.
| ||||||||||||||||||||||||||||
Availability: | Supported by all drivers.
| ||||||||||||||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||||||||||||||
See also: | Binding vst_effects ASCII table
|
C: | void vqt_fontinfo ( int16_t handle, int16_t *minADE, int16_t
*maxADE, int16_t *distances, int16_t *maxwidth, int16_t *effects );
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Binding: |
void vqt_fontinfo (int16_t handle, int16_t *minADE, int16_t *maxADE, int16_t *distances, int16_t *maxwidth, int16_t *effects) { contrl[0] = 131; contrl[1] = 0; contrl[3] = 0; contrl[6] = handle; vdi (); *minADE = intout[0]; *maxADE = intout[1]; *max_width = ptsout[0]; distances[0] = ptsout[1]; distances[1] = ptsout[3]; distances[2] = ptsout[5]; distances[3] = ptsout[7]; distances[4] = ptsout[9]; effects[0] = ptsout[2]; effects[1] = ptsout[4]; effects[2] = ptsout[6]; } | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire outline font text extent« - Obtain the length of a
string in a vector font.
| ||||||||||||||||||||||||
Opcode: | 240
| ||||||||||||||||||||||||
Syntax: | void vqt_f_extent ( int16_t handle, int8_t *string, int16_t
*extent );
| ||||||||||||||||||||||||
Description: | The call vqt_f_extent adds the character widths of a string of
text in a vector font, working to a precision of 1/65536 pixels, and
returns the bounding box needed to enclose a text string (in pixels).
The following apply:
Note: Unlike vqt_extent, this function also respects possible kerning values, and takes the remainders generated by outline fonts into account, so providing far more accurate results. Attention: This function does not return the bounding box of the string. It adds only the advance widths of the characters. You should use this function to determine the position of the text cursor. If you would like to use it to determine the maximum size of the redraw area you should add the maximum character width the leftmost and rightmost coordinates of the box (if the text is skewed you should also add the skewing offset). To determine a more exact bounding box you should call vqt_real_extent. Important: If the text is rotated by 90, 180 or 270 degrees, this function works as senselessly as vqt_extent: It changes the reference point of the coordinate system. In all other cases it works as you would expect it to. As of NVDI 3 it is recommended to use the function vqt_real_extent instead. | ||||||||||||||||||||||||
Return value: | The function does not return a result.
| ||||||||||||||||||||||||
Availability: | As of SpeedoGDOS 4.00 and from NVDI 3.00 onwards.
| ||||||||||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||||||||||
See also: | Binding vqt_extent SpeedoGDOS NVDI
|
C: | void vqt_f_extent ( int16_t handle, int8_t *string, int16_t
*extent );
| |||||||||||||||||||||||||||
Binding: |
void vqt_f_extent (int16_t handle, int8_t *string, int16_t *extent) { intin[0..n-1] = string[0..n-1]; contrl[0] = 240; contrl[1] = 0; contrl[3] = n; contrl[6] = handle; vdi (); extent[0..7] = ptsout[0..7]; } | |||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Get character mapping table« - Obtain address of the
character transformation table.
| ||||||||||||||||||||||||
Opcode: | 254
| ||||||||||||||||||||||||
Syntax: | void vqt_get_table( int16_t handle, int32_t *map );
| ||||||||||||||||||||||||
Description: | The call vqt_get_table obtains the addresses of the
transformation table that maps the Atari character set to the
Bitstream and PostScript character indices. The following apply:
Note: This information can be useful as some vector fonts may contain characters that are not present in the normal Atari character set. | ||||||||||||||||||||||||
Return value: | The function does not return a result.
| ||||||||||||||||||||||||
Availability: | As of SpeedoGDOS 4.00.
| ||||||||||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||||||||||
See also: | Binding GDOS SpeedoGDOS v_gtext
|
C: | void vqt_get_table ( int16_t handle, int32_t *map );
|
Binding: |
void vqt_get_table ( int16_t handle, int32_t *map ) { contrl[0] = 254; contrl[1] = 0; contrl[3] = 0; contrl[6] = handle; vdi (); map = intout[0..1]; } |
GEM-Arrays: |
|
Name: | »Inquire justified graphics text« - Obtain offsets for text
characters from a reference point.
| ||||||||||||||||||||||||||||
Opcode: | 132
| ||||||||||||||||||||||||||||
Syntax: | void vqt_justified ( int16_t handle, int16_t x, int16_t y,
int8_t *string, int16_t length, int16_t word_space, int16_t
char_space, int16_t *offsets );
| ||||||||||||||||||||||||||||
Description: | The call vqt_justified obtains for each character of a graphics
text string the X- and Y-offsets from a given reference point. The
following apply:
| ||||||||||||||||||||||||||||
Return value: | The function does not return a result.
| ||||||||||||||||||||||||||||
Availability: | PC-GEM as of Version 2.0.
| ||||||||||||||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||||||||||||||
See also: | Binding
|
C: | void vqt_justified ( int16_t handle, int16_t x, int16_t y,
int8_t *string, int16_t length, int16_t word_space, int16_t
char_space, int16_t *offsets );
| |||||||||||||||||||||||||||||||||||||||||||||
Binding: |
void vqt_justified (int16_t handle, int16_t x, int16_t y, int8_t *string, int16_t length, int16_t word_space, int16_t char_space, int16_t *offsets) { int16_t i; intin[0] = word_space; intin[1] = char_space; ptsin[0] = x; ptsin[1] = y; ptsin[2] = length; ptsin[3] = 0; i = 0; while (string[i++]) ; contrl[0] = 132; contrl[1] = 2; contrl[3] = i; contrl[6] = handle; pooff = offsets; vdi (); pooff = ptsout; } | |||||||||||||||||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire face name and index« - Obtain the name and short
description of a font.
| ||||||||||
Opcode: | 130
| ||||||||||
Syntax: | int16_t vqt_name ( int16_t handle, int16_t element_num, int8_t
*name );
| ||||||||||
Description: | The call vqt_name obtains the name and ID of a specified font
face. The folowing apply:
Note: The element name[32] contains the value 0 if the font in question is a pixel font, and the value 1 if it is an outline (vector) font (from SpeedoGDOS 4.0) In GEM/5, this function returns nothing for font index 0 or 1; for other indices, the font scaler is used to return data. A good test for a GEM/5 VDI would be to do a vqt_name on font 1, and see if it returned any values - if it did not, GEM/5 is running. From NVDI 3 onwards there is an extended version of this function. | ||||||||||
Return value: | The function returns the ID of the font.
| ||||||||||
Availability: | In all TOS versions, as of SpeedoGDOS 4.0 in extended
version.
| ||||||||||
Group: | Inquire functions
| ||||||||||
See also: | Binding vst_load_fonts vst_name vst_font vqt_xfntinfo
|
C: | int16_t vqt_name ( int16_t handle, int16_t element_num, int8_t
*name );
| ||||||||||||||||||||||||||||||
Binding: |
int16_t vqt_name (int16_t handle, int16_t element_num, int8_t *name) { int16_t tmp; intin[0] = element_num; contrl[0] = 130; contrl[1] = 0; contrl[3] = 1; contrl[6] = handle; vdi (); for (tmp = 0; tmp < 32; tmp++) name[tmp] = intout[tmp+1]; return ( intout[0] ); } | ||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire face name and ID by name« - Search for font ID and
name.
| ||||||||||||||||||||
Opcode: | 230 (Sub-Opcode 100)
| ||||||||||||||||||||
Syntax: | int16_t vqt_name_and_id ( int16_t handle, int16_t font_format,
int8_t *font_name, int8_t *ret_name );
| ||||||||||||||||||||
Description: | The call vqt_name_and_id searches for a font with a given name
and format. The following apply:
Note: Missing or extra spaces in the font name are ignored. | ||||||||||||||||||||
Return value: | The function returns the ID of the font, or the value 0 if no
corresponding font could be found.
| ||||||||||||||||||||
Availability: | As of NVDI Version 3.02 onwards.
| ||||||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||||||
See also: | Binding vst_name
|
C: | int16_t vqt_name_and_id ( int16_t handle, int16_t font_format,
int8_t *font_name, int8_t *ret_name );
| ||||||||||||||||||||||||||||||||||||
Binding: |
int16_t vqt_name_and_id (int16_t handle, int16_t font_format, int8_t *font_name, int8_t *ret_name) { intin[0] = font_format; intin[1..n] = font_name[0..n-1]; contrl[0] = 230; contrl[1] = 0; contrl[3] = n; contrl[5] = 100; contrl[6] = handle; vdi (); ret_name[0..m-1] = intout[1..m]; return ( intout[0] ); } | ||||||||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire pair kerning information« - Obtain adjustment vector
for character pairs when using pair kerning.
| ||||||||||||||
Opcode: | 235
| ||||||||||||||
Syntax: | void vqt_pairkern ( int16_t handle, int16_t ch1, int16_t ch2,
fix31 *x, fix31 *y );
| ||||||||||||||
Description: | The call vqt_pairkern obtains the adjustment vector for two
adjacent characters if pair kerning is in use. The following apply:
Note: If you want call vqt_pairkern from Pure C, you might have to write your own binding, because some releases of the PCGEMLIB return ptsout[0-3] instead of intout[0-3]. | ||||||||||||||
Return value: | The function does not return a result.
| ||||||||||||||
Availability: | As of SpeedoGDOS 4.0 and from NVDI 3.00 onwards.
| ||||||||||||||
Group: | Inquire functions
| ||||||||||||||
See also: | Binding vqt_trackkern SpeedoGDOS NVDI Kerning Track
kerning Pair kerning
|
C: | void vqt_pairkern ( int16_t handle, int16_t ch1, int16_t ch2,
fix31 *x, fix31 *y );
| |||||||||||||||||||||||||||||||||
Binding: |
void vqt_pairkern (int16_t handle, int16_t ch1, int16_t ch2, fix31 *x, fix31 *y) { intin[0] = ch1; intin[1] = ch2; contrl[0] = 235; contrl[1] = 0; contrl[3] = 2; contrl[6] = handle; vdi (); *x = intout[0..1]; *y = intout[2..3]; } | |||||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire real outline font text extent« - Obtain the bounding
box for an outline text.
| ||||||||||||||||||||||||||
Opcode: | 240 (Sub-Opcode 4200)
| ||||||||||||||||||||||||||
Syntax: | void vqt_real_extent ( int16_t handle, int16_t x, int16_t y,
int8_t *string, int16_t *extent );
| ||||||||||||||||||||||||||
Description: | The call vqt_real_extent obtains the minimum bounding box
(possibly a quadrilateral rather than a rectangle) for an outline
(vector) text, taking all text attributes into account.
Example: The function is passed the following parameters:
Note: This function respects all text effects, rotation, skewing, pair kerning, track kerning, characters which extend beyond the em square, and horizontal as well as vertical alignment. | ||||||||||||||||||||||||||
Return value: | The function does not return a result.
| ||||||||||||||||||||||||||
Availability: | As of NVDI Version 3.00.
| ||||||||||||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||||||||||||
See also: | Binding vqt_extent vqt_f_extent
|
C: | void vqt_real_extent ( int16_t handle, int16_t x, int16_t y,
int8_t *string, int16_t *extent );
| ||||||||||||||||||||||||||||||||||||
Binding: |
void vqt_real_extent (int16_t handle, int16_t x, int16_t y, int8_t *string, int16_t *extent) { intin[0..n-1] = string[0..n-1]; ptsin[0] = x; ptsin[1] = y; contrl[0] = 240; contrl[1] = 1; contrl[3] = n; contrl[5] = 4200; contrl[6] = handle; vdi (); extent[0..7] = ptsout[0..7]; } | ||||||||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire track kerning information« - Obtain adjustment
vector for fonts with track kerning.
| ||||||||||
Opcode: | 234
| ||||||||||
Syntax: | void vqt_trackkern ( int16_t handle, fix31 *x, fix31 *y );
| ||||||||||
Description: | The call vqt_trackkern obtains the adjustment vector per
character for fonts with track kerning. The following apply:
| ||||||||||
Return value: | The function does not return a result.
| ||||||||||
Availability: | As of SpeedoGDOS 4.0 and as of NVDI 3.00
| ||||||||||
Group: | Inquire functions
| ||||||||||
See also: | Binding GDOS SpeedoGDOS vqt_pairkern
|
C: | void vqt_trackkern ( int16_t handle, fix31 *x, fix31 *y );
|
Binding: |
void vqt_trackkern (int16_t handle, fix31 *x, fix31 *y) { contrl[0] = 234; contrl[1] = 0; contrl[3] = 0; contrl[6] = handle; vdi (); *x = intout[0..1]; *y = intout[2..3]; } |
GEM-Arrays: |
|
Name: | »Inquire character cell width« - Obtain the width of a
character cell.
| ||||||||||||||
Opcode: | 117
| ||||||||||||||
Syntax: | int16_t vqt_width ( int16_t handle, int8_t character, int16_t
*cell_width, int16_t *left_delta, int16_t *right_delta );
| ||||||||||||||
Description: | The call vqt_width obtains the horizontal extent of a specified
character in the current font as well as of the character cell, in
pixels. The following apply:
Note: Special effects and rotation do not apply. If one applies this function to a vector font, one only obtains the rounded-off step-size for the specified character as remainders are not taken into account. This step-size can be used only in connection with v_gtext. If one tries to apply these step-sizes to v_ftext, then wrong character positions will be calculated. It is recommended you use vqt_advance instead when inquiring about outline fonts. To check whether a font is monospaced or proportional, you should use vqt_ext_name which returns extended font information (under NVDI only). The values in left_delta and right_delta correspond exactly to the positions in the Horizontal offset table. If this specification is missing in the font header (which is the case for most bitmap fonts), then the return will be 0. | ||||||||||||||
Return value: | The function returns the index of character, or -1 if
an error has occurred.
| ||||||||||||||
Availability: | Supported by all drivers.
| ||||||||||||||
Group: | Inquire functions
| ||||||||||||||
See also: | Binding vst_effects
|
C: | int16_t vqt_width ( int16_t handle, int8_t character, int16_t
*cell_width, int16_t *left_delta, int16_t *right_delta );
| |||||||||||||||||||||||||||||||||||||||||||||
Binding: |
int16_t vqt_width (int16_t handle, int8_t character, int16_t *cell_width, int16_t *left_delta, int16_t *right_delta) { intin[0] = character; contrl[0] = 117; contrl[1] = 0; contrl[3] = 1; contrl[6] = handle; vdi (); *cell_width = ptsout[0]; *left_delta = ptsout[2]; *right_delta = ptsout[4]; return ( intout[0] ); } | |||||||||||||||||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire extended font information« - Obtain extended
information about a font.
| ||||||||||||||||||||||||||||||
Opcode: | 229 (Opcode 0)
| ||||||||||||||||||||||||||||||
Syntax: | int16_t vqt_xfntinfo ( int16_t handle, int16_t flags, int16_t
id, int16_t index, XFNT_INFO *info );
| ||||||||||||||||||||||||||||||
Description: | The call vqt_xfntinfo obtains information about a font as
specified in flags. The following apply:
Note: If index is a non-zero value, vqt_xfntinfo searches for the correspoding font and returns the requested information. If index is zero, vqt_xfntinfo searches for the font specified by id. If index and id are zero, this function returns information about the current font. Bit 8 and 9 of flags differ in their function only with bitmap fonts. If bit 8 is set, the returned point sizes are those that are present without enlargement. If bit 9 is set, then the returned point sizes are those that are enlarged. Before you call this function, you have to set the length of the structure in the element size. | ||||||||||||||||||||||||||||||
Return value: | The function returns the requested information in a XFNT_INFO
structure.
| ||||||||||||||||||||||||||||||
Availability: | As of NVDI 3.02
| ||||||||||||||||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||||||||||||||||
See also: | Binding vqt_name
|
C: | int16_t vqt_xfntinfo ( int16_t handle, int16_t flags, int16_t
id, int16_t index, XFNT_INFO *info );
| |||||||||||||||||||||||||||||||||||||||||||||
Binding: |
int16_t vqt_xfntinfo (int16_t handle, int16_t flags, int16_t id, int16_t index, XFNT_INFO *info) { intin[0] = flags; intin[1] = id; intin[2] = index; intin[3..4] = info; contrl[0] = 229; contrl[1] = 0; contrl[3] = 5; contrl[5] = 0; contrl[6] = handle; vdi (); return ( intout[1] ); } | |||||||||||||||||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire cell array« - Obtain information about a colour
table displayed on-screen.
| ||||||||||||||||||||||||||||||
Opcode: | 27
| ||||||||||||||||||||||||||||||
Syntax: | void vq_cellarray ( int16_t handle, int16_t *pxyarray, int16_t
row_length, int16_t num_rows, int16_t *el_used, int16_t *rows_used,
int16_t *status, int16_t *colarray );
| ||||||||||||||||||||||||||||||
Description: | The call vq_cellarray provides information about the definition
of a colour selection cell array. The following apply:
Note: The function is not available on all devices. | ||||||||||||||||||||||||||||||
Return value: | The function does not return a result.
| ||||||||||||||||||||||||||||||
Availability: | Not supported by any known drivers.
| ||||||||||||||||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||||||||||||||||
See also: | Binding v_cellarray
|
C: | void vq_cellarray ( int16_t handle, int16_t *pxyarray, int16_t
row_length, int16_t num_rows, int16_t *el_used, int16_t *rows_used,
int16_t *status, int16_t *colarray );
| ||||||||||||||||||||||||||||||||||||||||||
Binding: |
void vq_cellarray (int16_t handle, int16_t *pxyarray, int16_t row_length, int16_t num_rows, int16_t *el_used, int16_t *rows_used, int16_t *status, int16_t *colarray) { ptsin[0..3] = pxarray[0..3]; contrl[0] = 27; contrl[1] = 2; contrl[3] = 0; contrl[6] = handle; contrl[7] = row_length; contrl[8] = num_rows; vdi (); *el_used = contrl[9]; *rows_used = contrl[10]; *status = contrl[11]; colarray[0..n-1] = intout[0..n-1]; } | ||||||||||||||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire colour representation« - Obtain the RGB intensities
for a particular colour index.
| ||||||||||||||||||||
Opcode: | 26
| ||||||||||||||||||||
Syntax: | int16_t vq_color ( int16_t handle, int16_t color_index, int16_t
set_flag, int16_t *rgb );
| ||||||||||||||||||||
Description: | The call vq_color obtains the set RGB colour intensities of the
colour palette. The following apply:
Notes: Set and actually realized colour intensities can be different on systems using a CLUT if the number of available colour steps is too small. Example: If a monitor only offers two intensities, then its range divides into part-ranges 0..500 and 501..1000. The actual intensity can however only be 0 or 1000; no matter which number is selected from the range from 501 to 1000, the intensity of 1000 will be set every time; hence a set intensity can have the value of 623, say, and the actual one the value 1000. With direct RGB (no CLUT), usually the actually set intensity as well as the intensity passed by the user will be returned, as the number of gradations is large enough. Some colour printer drivers do not allow modifying the colour of each register. There is a simple test for checking if the driver permits you to change index colours:
| ||||||||||||||||||||
Return value: | The function returns -1 if the specified index is out of range
for the device; otherwise it does not return a result.
| ||||||||||||||||||||
Availability: | Supported by all drivers.
| ||||||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||||||
See also: | Binding vs_color vs_color2
|
C: | int16_t vq_color ( int16_t handle, int16_t color_index, int16_t
set_flag, int16_t *rgb );
| |||||||||||||||||||||||||||||||||
Binding: |
int16_t vq_color (int16_t handle, int16_t color_index, int16_t set_flag, int16_t *rgb) { intin[0] = color_index; intin[1] = set_flag; contrl[0] = 26; contrl[1] = 0; contrl[3] = 2; contrl[6] = handle; vdi (); rgb[0] = intout[1]; rgb[1] = intout[2]; rgb[2] = intout[3]; return ( intout[0] ); } | |||||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire device status info« - Inquire status of the output
device.
| ||||||||||||||||||
Opcode: | 248
| ||||||||||||||||||
Syntax: | void vq_devinfo ( int16_t handle, int16_t device, int16_t
*dev_open, int8_t *file_name, int8_t *device_name );
| ||||||||||||||||||
Description: | The call vq_devinfo checks whether a driver for a given output
device has been installed. The following apply:
Note: If the filename is empty, there is no driver with the given ID device. The function reports both the name of the driver (say "XVGA256.SYS") as well as the 'readable' name ("VGA 256 colours"). | ||||||||||||||||||
Return value: | The function does not return a result.
| ||||||||||||||||||
Availability: | As of NVDI 3.00.
| ||||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||||
See also: | Binding vq_ext_devinfo vqt_devinfo GDOS SpeedoGDOS
NVDI
|
C: | void vq_devinfo ( int16_t handle, int16_t device, int16_t
*dev_open, int8_t *file_name, int8_t *device_name );
| |||||||||||||||||||||||||||||||||
Binding: |
void vq_devinfo (int16_t handle, int16_t device, int16_t *dev_open, int8_t *file_name, int8_t *device_name) { intin[0] = device; contrl[0] = 248; contrl[1] = 0; contrl[3] = 1; contrl[6] = handle; vdi (); *dev_open = ptsout[0]; dev_name[0..p] = ptsout[1..p-1]; file_name[0..i-1] = intout[0..i-1] } | |||||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Extended inquire function« - Obtain additional information
about a workstation.
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Opcode: | 102
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Syntax: | void vq_extnd ( int16_t handle, int16_t owflag, int16_t
*work_out );
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Description: | The call vq_extnd obtains additional information about the
capabilities of a workstation. The following apply:
Notes: The stated assignments of the work_out arrays apply for the case that the extended information (owflag = 1) is to be obtained. If work_out[20] holds a non-zero value, work_out[21..24] and work_out[40..43] will contain extended information about pixel size and non-printable margins. The non-printable margins are normally returned only by printer drivers. They permit an application to centre documents, or to provide the user with a true likeness of the printed page in which the marginal borders in the document are depicted. (The region returned by v_opnwk in work_out[0/1] is the printable area.) If a driver returns more precise pixel sizes, this information should be used to calculate the position of graphic objects for printing. In worst case using the values from v_opnwk in work_out[3/4] can result in a positioning inaccuracy of 2 or 3 mm (for output on a DIN A4 page). Atari originaly misdocumented the workout[5] (CLUT) element, reversing the values. The Falcon 030 and some third-party TrueColor boards return the correct values, but some older boards may not. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Return value: | The function returns no direct function result.
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Availability: | Supported by all drivers.
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
See also: | Binding v_contourfill vswr_mode v_pline v_pmarker
v_fillarea v_opnwk
|
C: | void vq_extnd ( int16_t handle, int16_t owflag, int16_t
*work_out );
| ||||||||||||||||||||||||||||||
Binding: |
void vq_extnd (int16_t handle, int16_t owflag, int16_t *work_out) { intin[0] = owflag; contrl[0] = 102; contrl[1] = 0; contrl[3] = 1; contrl[6] = handle; vdi (); work_out[0..44] = intout[0..44]; work_out[45..56] = ptsout[0..11]; } | ||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire extended device status info« - Obtain information
about a GDOS driver.
| ||||||||||||||||||||
Opcode: | 248 (Sub-Opcode 4242)
| ||||||||||||||||||||
Syntax: | int16_t vq_ext_devinfo ( int16_t handle, int16_t device,
int16_t *dev_exists, int8_t *file_path, int8_t *file_name, int8_t
*name );
| ||||||||||||||||||||
Description: | The call vq_ext_devinfo obtains extended information about a
GDOS driver. The following apply:
| ||||||||||||||||||||
Return value: | The function returns the value 0 if the driver has not been
opened yet, and <>0 if it is already open.
| ||||||||||||||||||||
Availability: | As of NVDI version 3.00
| ||||||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||||||
See also: | Binding vq_devinfo vq_devinfo GDOS SpeedoGDOS NVDI
|
C: | int16_t vq_ext_devinfo ( int16_t handle, int16_t device,
int16_t *dev_exists, int8_t *file_path, int8_t *file_name, int8_t
*name );
| ||||||||||||||||||||||||||||||||||||||||||
Binding: |
int16_t vq_ext_devinfo (int16_t handle, int16_t device, int16_t *dev_exists, int8_t *file_path, int8_t *file_name, int8_t *name) { intin[0] = device; intin[1..2] = file_path; intin[3..4] = file_name; intin[5..6] = name; contrl[0] = 248; contrl[1] = 0; contrl[3] = 7; contrl[5] = 4242; contrl[6] = handle; vdi (); *dev_exists = intout[0]; return ( intout[1] ); } | ||||||||||||||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: |
|
Opcode: | 238
|
Syntax: | void vq_ptsinsz ( void );
|
Description: | Some GDOS ask the driver how the size from his PTSIN array is.
|
Return value: | Size of the PTSIN array.
|
Availability: | Some GDOS
|
Group: | Inquire functions
|
See also: | Binding
|
Name: | »Inquire screen information« - Return more exact
specification about the screen format.
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Opcode: | 102 (Sub-Opcode 1, Opcode 2)
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Syntax: | void vq_scrninfo ( int16_t handle, int16_t *work_out );
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Description: | The call vq_scrninfo returns additional information about the
device-specific screen format. This function is useful for programs
which:
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Return value: | All information is passed to the outside with the
work_out array:
If a hardware CLUT (work_out[1] == 1) exists:
HiColor or TrueColor:
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Availability: | As of EdDI-Version 1.00.
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Note: | Enhancer.prg as distributed with NVDI 2.5x, which simulates
this call in case no NVDI is present, sometimes copies 273 values. It
is therefore advisable to ensure that work_out has enough space for
273 values.
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
See also: | Binding Example XIMG format Raster formats NVDI Bitmap format for printer drivers
|
C: | void vq_scrninfo ( int16_t handle, int16_t *work_out );
| ||||||||||||||||||||||||||||||
Binding: |
void vq_scrninfo (int16_t handle, int16_t *work_out) { intin[0] = 2; contrl[0] = 102; contrl[1] = 0; contrl[3] = 1; contrl[5] = 1; contrl[6] = handle; vdi (); work_out[0..272] = intout[0..272]; } | ||||||||||||||||||||||||||||||
GEM-Arrays: |
|
256 colors on the Falcon:
work_out | Value | Description |
0 | 0 | Interleaved planes, (words) |
1 | 1 | Hardware CLUT |
2 | 8 | 8 bits per pixel |
3/4 | 256 | 256 simultaneously displayable colors |
5 | xxxx | Width of the bitmap in bytes (since EdDI 1.1) |
6/7 | xxxxL | Address of the bitmap (since EdDI 1.1) |
8 | 6 | CLUT has 6 bits for red intensity |
9 | 6 | CLUT has 6 bits for green intensity |
10 | 6 | CLUT has 6 bits for blue intensity |
11 | 0 | No alpha channel |
12 | 0 | No genlock |
13 | 0 | No unused bits |
14 | 1 | Usual bit order (since EdDI 1.1) |
16 | 0 | Pixel value for VDI color index 0 |
17 | 255 | Pixel value for VDI color index 1 |
18 | 2 | Pixel value for VDI color index 2 |
... | ... | |
271 | 15 | Pixel value for VDI color index 255 |
HiColor on the Falcon:
work_out | Value | Description |
0 | 2 | Packed pixels |
1 | 2 | HiColor (TrueColor:-) => pseudo CLUT |
2 | 16 | 16 bits per pixel |
3/4 | 32768 | 32768 colors |
5 | xxxx | Width of the bitmap in bytes (since EdDI 1.1) |
6/7 | xxxxL | Address of the bitmap (since EdDI 1.1) |
8 | 5 | 5 bits for red intensity |
9 | 5 | 5 bits for green intensity |
10 | 5 | 5 bits for blue intensity |
11 | 0 | No alpha channel |
12 | 1 | 1 bit for genlock (overlay) |
13 | 0 | No unused bits |
14 | 2 | Falcon bit order (rrrrrggg-ggxbbbbb ;since EdDI 1.1) |
16 | 11 | Bit 0 of the red intensity (least significant bit) |
Is bit 11 of the pixel | ||
17 | 12 | Bit 1 of the red intensity ist bit 12 of the pixel |
18 | 13 | ... |
19 | 14 | ... |
20 | 15 | Bit 4 of the red intensity (most significant bit) |
Is bit 15 of the pixel | ||
21..31 | -1 | Bits are not used |
32 | 6 | Bit 0 of the green intensity (least significant bit) |
Is bit 6 of the pixel | ||
33 | 7 | Bit 1 of the green intensity ist bit 7 of the pixel |
34 | 8 | ... |
35 | 9 | ... |
36 | 10 | Bit 4 of the green intensity (most significant bit) |
Is bit 10 of the pixel | ||
37..37 | -1 | Bits are not used |
48 | 0 | Bit 0 of the blue intensity (least significant bit) |
Is bit 0 of the pixel | ||
49 | 1 | Bit 1 of the blue intensity is bit 1 of the pixel |
50 | 2 | ... |
51 | 3 | ... |
52 | 4 | Bit 4 of the blue intensity (most significant bit) |
Is bit 4 of the pixel | ||
53..63 | -1 | Bits are not used |
64..79 | -1 | No alpha channel |
80 | 5 | Bit for genlock/overlay |
81..95 | -1 | Not used |
96..127 | -1 | No unused bits |
HiColor on a VGA graphic card (e.g. Crazy Dots):
work_out | Value | Description |
0 | 2 | Packed pixels |
1 | 2 | HiColor => pseudo CLUT |
2 | 16 | 16 bits per pixel |
3/4 | 32768 | 32768 colors |
5 | xxxx | Width of the bitmap in bytes (since EdDI 1.1) |
6/7 | xxxxL | Address of the bitmap (since EdDI 1.1) |
8 | 5 | 5 bits for red intensity |
9 | 5 | 5 bits for green intensity |
10 | 5 | 5 bits for blue intensity |
11 | 0 | No alpha channel |
12 | 1 | No genlock/overlay |
13 | 0 | 1 unused bits |
14 | 129 | Swapped bit order (gggbbbbb-xrrrrrgg; since EdDI 1.1) |
16 | 2 | Bit 0 of the red intensity (least significant bit) |
Is bit 2 of the pixel | ||
17 | 3 | Bit 1 of the red intensity is bit 3 of the pixel |
18 | 4 | ... |
19 | 5 | ... |
20 | 6 | Bit 4 of the red intensity (most significant bit) |
Is bit 6 of the pixel | ||
21..31 | -1 | Bits are not used |
32 | 13 | Bit 0 of the green intensity (least significant bit) |
Is bit 13 of the pixel | ||
33 | 14 | Bit 1 of the green intensity is bit 14 of the pixel |
34 | 15 | ... |
35 | 0 | ... |
36 | 1 | Bit 4 of the green intensity (most significant bit) |
Is bit 1 of the pixel | ||
37..37 | -1 | Bits are not used |
48 | 8 | Bit 0 of the blue intensity (least significant bit) |
Is bit 8 of the pixel | ||
49 | 9 | Bit 1 of the blue intensity is bit 9 of the pixel |
50 | 10 | ... |
51 | 11 | ... |
52 | 12 | Bit 4 of the green intensity (most significant bit) |
Is bit 12 of the pixel | ||
53..63 | -1 | Bits are not used |
64..79 | -1 | No alpha channel |
80..95 | -1 | No genlock/overlay |
96 | 7 | Bit 7 is an unused bit |
97..127 | -1 | No further unused bits |
Note: The output in work_out[5..7/14] only exist as of EdDI 1.1. Check the cookie version before you use them.
See also: vq_scrninfo Raster formats NVDI
Name: | Inquire info about a driver.
| ||||||||
Opcode: | 180
| ||||||||
Syntax: | DRV_INFO *v_create_driver_info( int16_t handle, int16_t
driver_id );
| ||||||||
Description: | The call v_create_driver_info returns information about device
drivers.
| ||||||||
Return value: | The function returns a pointer to a DRV_INFO structure, or 0L.
| ||||||||
Availability: | NVDI 5
| ||||||||
Group: | Inquire functions
| ||||||||
See also: | Binding
|
C: | DRV_INFO *v_create_driver_info( int16_t handle, int16_t
driver_id );
| ||||||||||||||||||||||||||||||
Binding: |
DRV_INFO *v_create_driver_info( int16_t handle, int16_t driver_id ) { int16_t save_conf; intin[0] = driver_id; contrl[0] = 180; contrl[1] = 0; contrl[3] = 1; contrl[5] = 0; contrl[6] = handle; contrl[2] = 0; contrl[4] = 0; save_conf = disable_nvdi_errors(); vdi (); enable_nvdi_errors( save_conf ); if ( contrl[4] >= 2 ) return(*(DRV_INFO **) &intout[0] ); return( 0L ); } | ||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | Discard information about a driver.
| ||||||||
Opcode: | 181
| ||||||||
Syntax: | int16_t v_delete_driver_info( int16_t handle, DRV_INFO
*drv_info );
| ||||||||
Description: | The call v_delete_driver_info discards the information obtained
with v_create_driver_info.
| ||||||||
Return value: | Unknown.
| ||||||||
Availability: | NVDI 5
| ||||||||
Group: | Inquire functions
| ||||||||
See also: | Binding v_create_driver_info
|
C: | int16_t v_delete_driver_info( int16_t handle, DRV_INFO
*drv_info );
|
Binding: |
int16_t v_delete_driver_info( int16_t handle, DRV_INFO *drv_info ) { *(DRV_INFO **) &intin[0] = drv_info; contrl[0] = 181; contrl[1] = 0; contrl[3] = 2; contrl[5] = 0; contrl[6] = handle; vdi (); return( intout[0] ); } |
GEM-Arrays: |
|
Name: | »Get character bitmap information« - Obtain placement
information about the bitmap of a vector character.
| ||||||||||||||||||||||
Opcode: | 239
| ||||||||||||||||||||||
Syntax: | void v_getbitmap_info ( int16_t handle, int16_t ch, fix31
*advx, fix31 *advy, fix31 *xoff, fix31 *yoff, int16_t *width, int16_t
*height, int16_t **bitmap );
| ||||||||||||||||||||||
Description: | The call v_getbitmap_info returns a pointer to the character's
bitmap and provides information about the character placement, size
and alignment.
Notes: advx/y represent the offset vectors for the correct placement of the next character. x/yoff are offset vectors of the top left corner of the bitmap relative to the position of the character cell, and are necessary because most bitmaps are smaller than the character cell containing them. To get reproducible output even without NVDI, any text effects should be switched off. As the pointer to the bitmap points to the character cache as a rule, one should copy the bitmap directly after the call (tip: inhibit AES context switching with wind_update!) - otherwise the pointer could be invalid already. Additionally one should not call v_getbitmap_info for very large characters (e.g. 300 pts or more), as these, depending on the cache size, may not be capable of being built up completely; in this case the bitmap contains only a part of the character. You should not use this function to write your own text output function - this function would not be faster than v_ftext and you would not be able to do pair kerning. Use v_ftext! | ||||||||||||||||||||||
Return value: | The function does not return a result.
| ||||||||||||||||||||||
Availability: | As of SpeedoGDOS 4.00 and as of NVDI 3.00. (The call also
existed in FSMGDOS but with a completely different calling format;
Atari changed it, as no FSMGDOS program utilized it at the time.)
| ||||||||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||||||||
See also: | Binding vst_effects SpeedoGDOS NVDI
|
C: | void v_getbitmap_info ( int16_t handle, int16_t ch, fix31
*advx, fix31 *advy, fix31 *xoff, fix31 *yoff, int16_t *width, int16_t
*height, int16_t **bitmap );
| |||||||||||||||||||||||||||||||||||||||||||||
Binding: |
void v_getbitmap_info (int16_t handle, int16_t ch, fix31 *advx, fix31 *advy, fix31 *xoff, fix31 *yoff, int16_t *width, int16_t *height, int16_t **bitmap) { intin[0] = ch; contrl[0] = 239; contrl[1] = 0; contrl[3] = 1; contrl[6] = handle; vdi (); *width = intout[0]; *height = intout[1]; *advx = intout[2..3]; *advy = intout[4..5]; *xoff = intout[6..7]; *yoff = intout[8..9]; *bitmap = intout[10..11]; } | |||||||||||||||||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Inquire extended device status info« - Obtain further
information about a device driver.
| ||||||||||||||||||||||
Opcode: | -1 (Sub-Opcode 4)
| ||||||||||||||||||||||
Syntax: | void v_get_driver_info ( int16_t device_id, int16_t
info_select, int8_t *info_string );
| ||||||||||||||||||||||
Description: | The call v_get_driver_info returns extended information about a
device driver and its fonts.
| ||||||||||||||||||||||
Return value: | The function does not return a result.
| ||||||||||||||||||||||
Availability: | GEM/3
| ||||||||||||||||||||||
Group: | Inquire functions
| ||||||||||||||||||||||
See also: | Binding
|
C: | void v_get_driver_info ( int16_t device_id, int16_t
info_select, int8_t *info_string );
| |||||||||||||||||||||||||||||||||
Binding: |
void v_get_driver_info ( int16_t device_id, int16_t info_select, int8_t *info_string ) { intin[0] = device_id; intin[1] = info_select; contrl[0] = -1; contrl[1] = 0; contrl[3] = 2; contrl[5] = 4; contrl[6] = 0; vdi (); if ( info_select != 5 ) { bptr = (int8_t *) intout ; for ( ii = 0; ii < contrl[ 4 ]; ii ++ ) *info_string++ = *bptr++ ; *info_string = 0 ; } else *(int16_t *)info_string = intout[ 0 ] ; } | |||||||||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Read default settings« - Obtain the default printer
settings.
| ||||||||
Opcode: | 182 (Subfunction 0)
| ||||||||
Syntax: | int16_t v_read_default_settings( int16_t handle, PRN_SETTINGS
*settings );
| ||||||||
Description: | The call v_read_default_settings obtains the default settings
of the installed printer.
| ||||||||
Return value: | Returns 0 if there an error.
| ||||||||
Availability: | NVDI 5
| ||||||||
Group: | Inquire functions
| ||||||||
See also: | Binding v_write_default_settings
|
C: | int16_t v_read_default_settings( int16_t handle, PRN_SETTINGS
*settings );
| |||||||||||||||||||||||||||
Binding: |
int16_t v_read_default_settings( int16_t handle, PRN_SETTINGS *settings ) { int16_t save_conf; *(PRN_SETTINGS **) &intin[0] = settings; contrl[0] = 182; contrl[1] = 0; contrl[3] = 2; contrl[5] = 0; /* Subfunction 0 */ contrl[6] = handle; contrl[2] = 0; contrl[4] = 0; save_conf = disable_nvdi_errors(); vdi (); enable_nvdi_errors( save_conf ); if ( contrl[4] >= 1 ) return( intout[0] ); return( 0 ); } | |||||||||||||||||||||||||||
GEM-Arrays: |
|
Name: | »Write default settings« - Set the default printer settings.
| ||||||||
Opcode: | 182 (Subfunction 1)
| ||||||||
Syntax: | int16_t v_write_default_settings( int16_t handle, PRN_SETTINGS
*settings );
| ||||||||
Description: | The function v_write_default_settings sets the default printer
settings for the installed printer.
| ||||||||
Return value: | Returns 0 if there an error.
| ||||||||
Availability: | NVDI 5
| ||||||||
Group: | Inquire functions
| ||||||||
See also: | Binding v_read_default_settings
|
C: | int16_t v_write_default_settings( int16_t handle, PRN_SETTINGS
*settings );
| |||||||||||||||||||||||||||
Binding: |
int16_t v_write_default_settings( int16_t handle, PRN_SETTINGS *settings ) { int16_t save_conf; *(PRN_SETTINGS **) &intin[0] = settings; contrl[0] = 182; contrl[1] = 0; contrl[3] = 2; contrl[5] = 1; /* Subfucntion 1 */ contrl[6] = handle; contrl[2] = 0; contrl[4] = 0; save_conf = disable_nvdi_errors(); vdi (); enable_nvdi_errors( save_conf ); if ( contrl[4] >= 1 ) return( intout[0] ); return( 0 ); } | |||||||||||||||||||||||||||
GEM-Arrays: |
|
The font header returned by vqt_fontheader is built up as follows:
FH_FMVER 0 /* U "D4.0" CR LF NULL NULL 8 bytes */ FH_FNTSZ 8 /* U Font size (bytes) 4 bytes */ FH_FBFSZ 12 /* U Min. font buffer size (bytes) 4 bytes */ FH_CBFSZ 16 /* U Min. char. buffer size (bytes) 2 bytes */ FH_HEDSZ 18 /* U Header size (bytes) 2 bytes */ FH_FNTID 20 /* U Source font ID 2 bytes */ FH_SFVNR 22 /* U Source font version number 2 bytes */ FH_FNTNM 24 /* U Source font full name 70 bytes */ FH_MDATE 94 /* U Manufacturing date 10 bytes */ FH_LAYNM 104 /* U Layout (character set) name 70 bytes */ FH_CPYRT 174 /* U Copyright notice 78 bytes */ FH_NCHRL 252 /* U No. of char. indices in layout 2 bytes */ FH_NCHRF 254 /* U Total character indices in font 2 bytes */ FH_FCHRF 256 /* U Index of first char. in font 2 bytes */ FH_NKTKS 258 /* U Number of kerning tracks in font 2 bytes */ FH_NKPRS 260 /* U Number of kerning pairs in font 2 bytes */ FH_FLAGS 262 /* U Font flags 1 byte: */ /* Bit 0: Extended mode if set, */ Compact mode (default) if clear */ /* Bit 1: Not used */ /* Bit 2: Not used */ /* Bit 3: Not used */ /* Bit 4: Not used */ /* Bit 5: Not used */ /* Bit 6: Not used */ /* Bit 7: Not used */ FH_CLFGS 263 /* U Classification flags 1 byte: */ /* Bit 0: Italic */ /* Bit 1: Monospace */ /* Bit 2: Serif */ /* Bit 3: Display */ /* Bit 4: Reserved */ /* Bit 5: Reserved */ /* Bit 6: Reserved */ /* Bit 7: Reserved */ FH_FAMCL 264 /* U Family classification 1 byte: */ /* 0: Don't care */ /* 1: Serif */ /* 2: Sans serif */ /* 3: Monospace */ /* 4: Script or calligraphic */ /* 5: Decorative */ /* 6-255: Not used */ FH_FRMCL 265 /* U Font form classification 1 byte: */ /* Bits 0-3 (Width type): */ /* 0-3: Reserved */ /* 4: Condensed */ /* 5: Reserved for 3/4 condensed */ /* 6: Semi-condensed */ /* 7: Reserved for 1/4 condensed */ /* 8: Normal */ /* 9: Reserved for 3/4 expanded */ /* 10: Semi-expanded */ /* 11: Reserved for 1/4 expanded */ /* 12: Expanded */ /* 13-15: Reserved */ /* Bits 4-7 (Weight): */ /* 0: Reserved */ /* 1: Thin */ /* 2: Ultralight */ /* 3: Extralight */ /* 4: Light */ /* 5: Book */ /* 6: Normal */ /* 7: Medium */ /* 8: Semibold */ /* 9: Demibold */ /* 10: Bold */ /* 11: Extrabold */ /* 12: Ultrabold */ /* 13: Heavy */ /* 14: Black */ /* 15-16: Reserved */ FH_SFNTN 266 /* U Short font name 32 bytes */ FH_SFACN 298 /* U Short face (family) name 16 bytes */ FH_FNTFM 314 /* U Font form (as above) 14 bytes */ FH_ITANG 328 /* U Italic angle (1/256 deg clockw) 2 bytes */ FH_ORUPM 330 /* U Number of ORUs per em 2 bytes */ FH_WDWTH 332 /* U Width of word-space (ASCII 32) 2 bytes */ FH_EMWTH 334 /* U Width of em-space 2 bytes */ FH_ENWTH 336 /* U Width of en-space 2 bytes */ FH_TNWTH 338 /* U Width of thin-space 2 bytes */ FH_FGWTH 340 /* U Width of figure-space 2 bytes */ FH_FXMIN 342 /* U Font-wide min. X coord. 2 bytes */ FH_FYMIN 344 /* U Font-wide min. Y coord. 2 bytes */ FH_FXMAX 346 /* U Font-wide max. X coord. 2 bytes */ FH_FYMAX 348 /* U Font-wide max. Y coord. 2 bytes */ FH_ULPOS 350 /* U Underline position 2 bytes */ FH_ULTHK 352 /* U Underline thickness 2 bytes */ FH_SMCTR 354 /* U Small capitals transformation 6 bytes */ FH_DPSTR 360 /* U Display superiors transformation 6 bytes */ FH_FNSTR 366 /* U Footnote superiors transformation 6 bytes */ FH_ALSTR 372 /* U Alpha superiors transformation 6 bytes */ FH_CMITR 378 /* U Chemical inferiors transformation 6 bytes */ FH_SNMTR 384 /* U Small numerators transformation 6 bytes */ FH_SDNTR 390 /* U Small denominators transformation 6 bytes */ FH_MNMTR 396 /* U Medium numerators transformation 6 bytes */ FH_MDNTR 402 /* U Medium denominators transformation 6 bytes */ FH_LNMTR 408 /* U Large numerators transformation 6 bytes */ FH_LDNTR 414 /* U Large denominators transformation 6 bytes */ /* Transformation data format: */ /* Y position 2 bytes */ /* X scale (1/4096ths) 2 bytes */ /* Y scale (1/4096ths) 2 bytes */ SIZE_FW FH_LDNTR + 6 /* Size of nominal font header */ EXP_FH_METRES SIZE_FW /* Offset to expansion field metric resolution (optional) */
See also: vqt_fontheader Header for bitmap GDOS fonts Vector fonts
int16_t disable_nvdi_errors ( void ) { int16_t save_conf; NVDI_STRUC *p; if ( get_cookie( 'NVDI', p ) ) { save_conf = p->nvdi_config; p->nvdi_config |= 2; p->nvdi_config &= 0xFFBF; return save_conf; } return 0; }
void enable_nvdi_errors ( int16_t save_conf ) { NVDI_STRUC *p; if ( get_cookie( 'NVDI', p ) ) p->nvdi_config = save_conf; return; }