µC/GUI Font Support

Simulation

Font Comverter

Bitmap Comverter

Licensing

Pricing Information

Windows Manager

Widgets

Dialogs

Antialiasing

Memory Devices

Multiple Layers/Displays

Touch Screen Support

Virtual Screen Support

VNC Support

Overview

Benefits

Drivers

PC Windows Evaluation

PC Windows Samples

The most common fonts are shipped with uC/GUI as standard fonts. In fact, you will probably find that these fonts are fully sufficient for your application. Proportional fonts are supported. µC/GUI offers complete Unicode support. Fonts for foreign languages can be created using the µC/GUI-FontConverter.

uC/GUI supports ASCII, ISO 8859-1 and Unicode. Usually, uC/GUI is compiled for 8-bit characters, allowing for a maximum of 256 different character codes out of which the first 32 are reserved as control characters. The characters that are available depends on the selected font.

Character sets

ASCII

uC/GUI supports the full set of ASCII characters. These are the following 96 characters from 32 to 127.

Hex 0 1 2 3 4 5 6 7 8 9 A B C D E F
2x  
!
 
"#
$
%
&
'
(
)
*
+
,
-
.
/
3x
0
1
2
3
4
5
6
7
8
9
:
;
<
=
>
?
4x
@
A
B
C
D
E
F
G
H
I
J
K
L
M
N
O
5x
P
Q
R
S
T
U
V
W
X
Y
Z
[
\
]
^
_
6x
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
7x
p
q
r
s
t
u
v
w
x
y
z
{
|
}
~

Unfortunately, as ASCII stands for American Standard Code for Information Interchange, it is designed for American needs. It does not include any of the special characters used in European languages, such as Ä, Ö, Ü, á, à, and others. There is no single standard for these "European extensions" of the ASCII set of characters; several different ones exist. The one used on the Internet and by most Microsoft Windows programs is ISO 8859-1, a superset of the ASCII set of characters.

ISO 8859-1 Western Latin character set

uC/GUI supports the ISO 8859-1, which defines characters as listed below.

Code
Description
Character
160
non-breaking space
161
inverted exclamation
¡
162
cent sign
¢
163
pound sterling
£
164
general currency sign
¤
165
yen sign
¥
166
broken vertical bar
¦
167
section sign
§
168
umlaut (dieresis)
¨
169
copyright
©
170
feminine ordinal
ª
171
left angle quote, guillemotleft
«
172
not sign
¬
173
soft hyphen
¯  
174
registered trademark
®
175
macron accent
¯
176
degree sign
°
177
plus or minus
±
178
superscript two
²
179
superscript three
³
180
acute accent
´
181
micro sign
µ
182
paragraph sign
183
middle dot
·
184
cedilla
¸
185
superscript one
¹
186
masculine ordinal
º
187
right angle quote, guillemot right
»
188
fraction one-fourth
¼
189
fraction one-half
½
190
fraction three-fourth
¾
191
inverted question mark
¿
192
capital A, grave accent
À
193
capital A, acute accent
Á
194
capital A, circumflex accent
Â
195
capital A, tilde
Ã
196
capital A, dieresis or umlaut mark
Ä
197
capital A, ring
Å
198
capital A, diphthong (ligature)
Æ
199
capital C, cedilla
Ç
200
capital E, grave accent
È
201
capital E, acute accent
É
202
capital E, circumflex accent
Ê
203
capital E, dieresis or umlaut mark
Ë
204
capital I, grave accent
Ì
205
capital I, acute accent
Í
206
capital I, circumflex accent
Î
207
capital I, dieresis or umlaut mark
Ï
Code
Description
Character
208
Eth, Icelandic
Ð
209
N, tilde
Ñ
210
capital O, grave accent
Ò
211
capital O, acute accent
Ó
212
capital O, circumflex accent
Ô
213
capital O, tilde
Õ
214
capital O, dieresis or umlaut mark
Ö
215
multiply sign
×
216
capital O, slash
Ø
217
capital U, grave accent
Ù
218
capital U, acute accent
Ú
219
capital U, circumflex accent
Û
220
capital U, dieresis or umlaut mark
Ü
221
capital Y, acute accent
Ý
222
THORN, Icelandic
Þ
223
sharp s, German (s-z ligature)
ß
224
small a, grave accent
à
225
small a, acute accent
á
226
small a, circumflex accent
â
227
small a, tilde
ã
228
small a, dieresis or umlaut mark
ä
229
small a, ring
å
230
small ae diphthong (ligature)
æ
231
smal c, cedilla
ç
232
small e, grave accent
è
233
small e, acute accent
é
234
small e, circumflex accent
ê
235
small e, dieresis or umlaut mark
ë
236
small i, grave accent
ì
237
small i, acute accent
í
238
small i, circumflex accent
î
239
small i, dieresis or umlaut mark
ï
240
small eth, Icelandic
ð
241
small n, tilde
ñ
242
small o, grave accent
ò
243
small o, acute accent
ó
244
small o, circumflex accent
õ
245
small o, tilde
õ
246
small o, dieresis or umlaut mark
ö
247
division sign
÷
248
small o, slash
ø
249
small u, grave accent
ù
250
small u, acute accent
ú
251
small u, circumflex accent
û
252
small u, dieresis or umlaut mark
ü
253
small y, acute accent
ý
254
small thorn, Icelandic
þ
255
small y, dieresis or umlaut mark
ÿ

Unicode

Unicode is the ultimate in character coding. It is an international standard based on ASCII and ISO 8859-1. Contrary to ASCII, UNICODE requires 16-bit characters because all characters have their own code. Currently, more than 30,000 different characters are defined. However, not all of the character images are defined in uC/GUI.

As µC/GUI does not include any Unicode character set with the basic package, it is the developper's responsibility to supply it. Micrium offers the µC/GUI-FontConverter tool if you have a font set that you want to use but it is not a bitmap font (see the µC/GUI-FontConverter page). Please contact Micrium or your distributor, as we may already have the character set that you need.

Standard fonts

The standard font package contains monospaced and proportional fonts in different sizes and styles. Monospaced fonts are fonts with a fixed character width, in which all characters have the same width in pixels. Proportional fonts are fonts in which each character has its own individual pixel-width.

Font identifier naming convention

All standard fonts are named as follows. The elements of the naming convention are then explained in the table:
GUI_Font[<style>][<width>x]<height>[x<MagX>x<MagY>][H][B][_<characterset>]

Element Description
GUI_Font
Standard prefix for all fonts shipped with uC/GUI.
<style> Specifies a non-standard font style. Example: Comic style in
GUI_FontComic18B_ASCII.
<width> Width of characters, contained only in monspaced fonts.
<height> Height of the font in pixels.
<MagX> Factor of magnification in X, contained only in magnified fonts.
<MagY> Factor of magnification in Y, contained only in magnified fonts.
H Abbreviation for "high". Only used if there is more than one font with the same height. It means that the font appears "higher" than other fonts.
B Abbreviation for "bold". Used in bold fonts.
<characterset> Specifies the contents of characters:
ASCII: Only ASCII characters 0x20-0x7E (0x7F).
1: ASCII characters and European extensions 0xA0 - 0xFF.
HK: Hiragana and Katakana.
1HK: ASCII, European extensions, Hiragana and Katakana.
D: Digit fonts, character set: +-.0123456789.

Example

GUI_Font8x16x1x2

Element Description
GUI_Font
Standard font prefix.
8 Width of characters.
16 Heigth in pixels.
1 Magnification factor in X.
2 Magnification factor in Y.

Measurement
F:32 B:24 C:20 L:14 U:6
ROM Size 3304 bytes.

The table below gives the various fonts delivered as µC/GUI standard fonts:

Proportional
Monospaced
Digits
Comic
GUI_Font8_ASCII GUI_Font4x6 GUI_FontD24x32 GUI_FontComic18B_ASCII
GUI_Font8_1 GUI_Font6x8 GUI_FontD32 GUI_FontComic18B_1
GUI_Font10S_ASCII GUI_Font6x9 GUI_FontD36x48 GUI_FontComic24B_ASCII
GUI_Font10S_1 GUI_Font8x8 GUI_FontD48 GUI_FontComic24B_1
GUI_Font10_ASCII GUI_Font8x9 GUI_FontD48x64
GUI_Font10_1 GUI_Font8x10_ASCII GUI_FontD64
GUI_Font13_ASCII GUI_Font8x12_ASCII GUI_FontD60x80
GUI_Font13_1 GUI_Font8x13_ASCII GUI_FontD80
GUI_Font13B_ASCII GUI_Font8x13_1  
GUI_Font13B_1 GUI_Font8x15B_ASCII
GUI_Font13H_ASCII GUI_Font8x15B_1
GUI_Font13H_1 GUI_Font8x16
GUI_Font13HB_ASCII GUI_Font8x17
GUI_Font13HB_1 GUI_Font8x18
GUI_Font16_ASCII GUI_Font8x16x1x2
GUI_Font16_1 GUI_Font8x16x2x2
GUI_Font16_HK GUI_Font8x16x3x3
GUI_Font16_1HK  
GUI_Font16B_ASCII
GUI_Font16B_1
GUI_Font24_ASCII
GUI_Font24_1
GUI_Font24B_ASCII
GUI_Font24B_1
GUI_Font32_ASCII
GUI_Font32_1
GUI_Font32B_ASCII
GUI_Font32B_1

Font API

The table below lists the available font-related functions in alphabetical order within their respective categories.

Function Description
Font Selection
GUI_GetFont Returns a pointer to the currently selected font.
GUI_SetFont Sets the current font.
GUI_SIF_CreateFont Creates and selects a font by passing a pointer to system independent font data.
GUI_SIF_DeleteFont Deletes a font created by GUI_SIF_CreateFont()
GUI_XBF_CreateFont() Creates and selects a font by passing a pointer to a callback function, which is responsible for getting data from the XBF font file.
GUI_XBF_DeleteFont() Deletes a font created by GUI_XBF_CreateFont()
Font-related functions
GUI_GetCharDistX Returns the width in pixels (X-size) of a specified character in the current font.
GUI_GetFontDistY Returns the Y-spacing of the current font.
GUI_GetFontInfo Returns a structure containing font information.
GUI_GetFontSizeY Returns the height in pixels (Y-size) of the current font.
GUI_GetStringDistX Returns the X-size of a text using the current font.
GUI_GetTextExtend Evaluates the size of a text using the current font
GUI_GetYDistOfFont Returns the Y-spacing of a particular font.
GUI_GetYSizeOfFont Returns the Y-size of a particular font.
GUI_IsInFont Evaluates whether a specified character is in a particular font.