General Terminal

GtGetFontWidth

Get the width of one text cell

Syntax

Signature
int GtGetFontWidth( void );

Arguments

No arguments.

Return value

The cell width in pixels.

Description

Use it with GtGetFontSize() when converting a grid of cells into pixel dimensions.

Example

gtgetfontwidth.c
#include "xdev-wtui.h"

#include <stdio.h>

int main( void )
{
   printf( "Text cell dimensions, width (pixels): %d\n", GtGetFontWidth() );

   return 0;
}

See also