# IBM Visualization Data Explorer Programmer's Reference

[ Bottom of Page | Previous Page | Next Page | Table of Contents | Partial Table of Contents | Index ]

### DXGetFont

Function

Returns a Group representing the named font.

Syntax
`
#include <dx/dx.h>
`

Object DXGetFont(char *name, float *ascent, float *descent)

Functional Details

The Group has as many members as there are characters in the named font (`name`). Typically, the returned font is passed to `DXGeometricText` to construct a text Object from a given string. Alternatively, individual characters can be extracted using `DXGetEnumeratedMember`. The member number is the same as the ASCII character code.

The font has an overall height of 1. If `ascent` is not `NULL`, the portion of the overall height above the baseline is returned in `*ascent`. If `descent` is not `NULL`, the portion of the overall height below the baseline is returned in `*descent`. The sum of the ascent and the descent is the overall height 1.

This routine checks the environment variables DXFONTS, DXEXECROOT, and DXROOT for directories to search for fonts. The routine also checks in `/usr/local/dx` and in the subdirectory `fonts` of each of these directories.

Return Value

Returns the font or returns `NULL` and sets an error code.

See Also

`DXGeometricText, DXGetEnumeratedMember`

15.1 , "Text".

[ Top of Page | Previous Page | Next Page | Table of Contents | Partial Table of Contents | Index ]
[Data Explorer Documentation | QuickStart Guide | User's Guide | User's Reference | Programmer's Reference | Installation and Configuration Guide ]

[Data Explorer Home Page]

[IBM Home Page | Order | Search | Contact IBM | Legal ]