Module interface:fontengine - Font-engine interface

Font-engine interface. This interface is used for font handling by application programs.

Index

Declarations

fontengine_chan.inc:28Group FONTFLAG

Font flags.

fontengine_chan.inc:29Constant FONTFLAG.PROPORTIONAL

VAL INT32 FONTFLAG.PROPORTIONAL

Font is proportional.

fontengine_chan.inc:30Constant FONTFLAG.LKTABLE

VAL INT32 FONTFLAG.LKTABLE

Font has leading/kerning table for each character.

fontengine_chan.inc:31Constant FONTFLAG.UNICODE

VAL INT32 FONTFLAG.UNICODE

Unicode font (not supported yet).

fontengine_chan.inc:32Constant FONTFLAG.ALPHA

VAL INT32 FONTFLAG.ALPHA

Font has alpha table for each character.

fontengine_chan.inc:33Constant FONTFLAG.OUTLINE

VAL INT32 FONTFLAG.OUTLINE

Font is an outline font (otherwise assume bitmap).

fontengine_chan.inc:34Constant FONTFLAG.STYLE.ITALIC

VAL INT32 FONTFLAG.STYLE.ITALIC

Italic style font.

fontengine_chan.inc:35Constant FONTFLAG.STYLE.THIN

VAL INT32 FONTFLAG.STYLE.THIN

Thin style font.

fontengine_chan.inc:36Constant FONTFLAG.WEIGHT.BOLD

VAL INT32 FONTFLAG.WEIGHT.BOLD

Bold weighted font.

fontengine_chan.inc:41Record FONTATTR

DATA TYPE FONTATTR

Font attributes.

fontengine_chan.inc:43Variable id

INT

Internal font ID.

fontengine_chan.inc:45Variable name

[128]BYTE

Font name (e.g. "fixed").

fontengine_chan.inc:46Variable name.len

INT

Font name length.

fontengine_chan.inc:47Variable foundry

[128]BYTE

Font foundry/copyright (e.g. "public domain").

fontengine_chan.inc:48Variable foundry.len

INT

Font foundry length.

fontengine_chan.inc:49Variable author

[128]BYTE

Font author (e.g. "Jimmy Lithographer").

fontengine_chan.inc:50Variable author.len

INT

Font author length.

fontengine_chan.inc:52Variable pntsz

INT

Font point size.

fontengine_chan.inc:53Variable csx, csy

INT

Character size (pixels).

fontengine_chan.inc:54Variable flags

INT32

Font flags.

fontengine_chan.inc:59Protocol P.FONTENGINE.IN

PROTOCOL P.FONTENGINE.IN

Font-engine input protocol.

fontengine_chan.inc:61Tag catalog

catalog

List font catalogue, responds with @X.((catalog -> X) |~| ok).

fontengine_chan.inc:63Tag query

query; INT

Query a particular font, responds with (catalog |~| error).

fontengine_chan.inc:72Tag render.text

render.text; INT; MOBILE []BYTE; MOBILE [][]INT32; [2]INT; [4]INT; [2]INT32

Render text onto an ARGB frame-buffer, responds with render.out.

Parameters:

INT font.id Font identifier.
MOBILE []BYTE string Text to render.
MOBILE [][]INT32 argb.fb Framebuffer on which to render text.
[2]INT position X, Y coordinates where text is rendered.
[4]INT clip.rect Clipping rectangle.
[2]INT32 colours Foreground and background colour.

fontengine_chan.inc:77Tag text.width

text.width; INT; MOBILE []BYTE

Query how much space a particular string takes to render, responds with sizing error.

Parameters:

INT font.id Font identifier.
MOBILE []BYTE string Text to render/test.

fontengine_chan.inc:79Tag load.font

load.font; MOBILE []BYTE

Load a font from an rmox font-file (.rfn), responds with (catalog |~| error).

fontengine_chan.inc:83Protocol P.FONTENGINE.OUT

PROTOCOL P.FONTENGINE.OUT

Font-engine output protocol.

fontengine_chan.inc:85Tag catalog

catalog; FONTATTR

Font catalogue entry attributes.

fontengine_chan.inc:86Tag ok

ok

Generic ok.

fontengine_chan.inc:87Tag error

error; INT

Generic error.

fontengine_chan.inc:88Tag render.out

render.out; MOBILE [][]INT32

Rendered text framebuffer out.

fontengine_chan.inc:89Tag sizing

sizing; [2]INT

Size info [x,y] if this was rendered.

fontengine_chan.inc:93Channel type CT.FONTENGINE

CHAN TYPE CT.FONTENGINE

Font-engine channel-type.

fontengine_chan.inc:95Variable in?

CHAN P.FONTENGINE.IN

Requests to font-engine.

fontengine_chan.inc:96Variable out!

CHAN P.FONTENGINE.OUT

Responses from font-engine.