Functions | |
void | Show_Text (HC_KEY key, float *x, float *y, float *z, char *text) |
void | DShow_Text (HC_KEY key, double *x, double *y, double *z, void *text) |
void | Show_Text_Count (HC_KEY key, int *count) |
void | Show_Text_Length (HC_KEY key, int *length) |
void | Show_Text_Encoding (HC_KEY key, char *encoding) |
void | Show_Text_With_Encoding (HC_KEY key, float *x, float *y, float *z, char *encoding, void *text) |
void | DShow_Text_With_Encoding (HC_KEY key, double *x, double *y, double *z, char *encoding, void *text) |
void Show_Text | ( | HC_KEY | key, | |
float * | x, | |||
float * | y, | |||
float * | z, | |||
char * | text | |||
) |
Returns the position, size, and contents of a previously defined text string, as referenced by a key.
key | - Unique numeric identifier pointing to a text primitive in the database. | |
x | - Position, in user coordinates, of the "reference point" of the text. Returned to user. Passed by reference always. | |
y | - | |
z | - | |
text | - The text string referenced by key. Returned to user. Passed by reference always. |
The key for the text might come from Show_Selection_Element() or Find_Contents() , or it might have been saved by your program when the text was created (via Insert_Text() ).
To aid in the allocation of a buffer large enough to receive any arbitrary text, you can call Show_Text_Length() first to find out how much room you're going to need. In C remember to allow room for the terminating null. If you are using the "C return string length" System Option, Show_Text_Length() will return the full size, but the string returned by Show_Text() will be truncated to the return-string length (or one less, if truncating would interrupt a 16-bit character.)
NOTE
Keyword values are normally treated as all lowercase within HOOPS: this will cause an original encoding of "JIS", for example, to come back as "jis", not "JIS".
void DShow_Text | ( | HC_KEY | key, | |
double * | x, | |||
double * | y, | |||
double * | z, | |||
void * | text | |||
) |
Similar to Show_Text(), but returns double-precision values.
key | - Unique numeric identifier pointing to a text primitive in the database. | |
x | - Position, in user coordinates, of the "reference point" of the text. Returned to user. Passed by reference always. | |
y | - | |
z | - | |
text | - The text string referenced by key. Returned to user. Passed by reference always. |
void Show_Text_Count | ( | HC_KEY | key, | |
int * | count | |||
) |
Finds the number of characters in a given text string, as reference by a key.
key | - Unique numeric identifier pointing to a text primitive in the database. | |
count | - Number of characters represented by text. 16-bit character values countas 1 character. In C this value does not include the terminating null character. Returned to user. Passed by reference always. |
void Show_Text_Length | ( | HC_KEY | key, | |
int * | length | |||
) |
Finds the number of bytes in a given text string, as referenced by a key.
key | - Unique numeric identifier pointing to a text primitive in the database. | |
length | - Number of bytes occupied by text. 16-bit character values count as 2 bytes. In C this value does not include the termi nating null character. Returned to user. Passed by reference always. |
void Show_Text_Encoding | ( | HC_KEY | key, | |
char * | encoding | |||
) |
Finds the type of encoding with which a particular string was inserted, as referenced by a key.
key | - Unique numeric identifier pointing to a text primitive in the database. | |
encoding | - The encoding originally passed to Insert_Text_With_Encoding() , or the constant "iso latin one" if Insert_Text() was used. Returned to user. Passed by reference always. |
void Show_Text_With_Encoding | ( | HC_KEY | key, | |
float * | x, | |||
float * | y, | |||
float * | z, | |||
char * | encoding, | |||
void * | text | |||
) |
Similar to Show_Text, but operates on encoded text rather than Latin1 text.
key | - Unique numeric identifier pointing to a text primitive in the database. | |
x | - Position, in user coordinates, of the "reference point" of the text. Returned to user. Passed by reference always. | |
y | - | |
z | - | |
encoding | - The encoding originally passed to Insert_Text_With_Encoding() , or the constant "iso latin one" if Insert_Text() was used. Returned to user. Passed by reference always. | |
text | - The text string referenced by key. Returned to user. Passed by reference always. |
void DShow_Text_With_Encoding | ( | HC_KEY | key, | |
double * | x, | |||
double * | y, | |||
double * | z, | |||
char * | encoding, | |||
void * | text | |||
) |
Similar to Show_Text_With_Encoding(), but returns double-precision values.
key | - Unique numeric identifier pointing to a text primitive in the database. | |
x | - Position, in user coordinates, of the "reference point" of the text. Returned to user. Passed by reference always. | |
y | - | |
z | - | |
encoding | - The encoding originally passed to DInsert_Text_With_Encoding() , or the constant "iso latin one" if DInsert_Text() was used. Returned to user. Passed by reference always. | |
text | - The text string referenced by key. Returned to user. Passed by reference always. |