Updated PCI IDs to latest snapshot.
[tangerine.git] / workbench / libs / muimaster / textengine.h
blobeffaf68d22d1bce58eb0b451d8760945660403ac
1 /*
2 Copyright © 1999, David Le Corfec.
3 Copyright © 2002, The AROS Development Team.
4 All rights reserved.
6 $Id$
7 */
9 #ifndef _MUI_TEXTENGINE_H__
10 #define _MUI_TEXTENGINE_H__
12 /* This is the clone of the MUI text engine, used by the Text class
13 * and all class needing to draw text strings.
17 struct MUI_ImageSpec_intern;
19 typedef struct ZTextChunk {
20 struct MinNode node; /* embedded node */
21 char *str;
22 CONST_STRPTR spec;
23 struct MUI_ImageSpec_intern *image;
24 Object *obj; /* Area subclass, see List_CreateImage */
25 LONG dripen;
26 LONG pen;
27 UBYTE style; /* FSF_UNDERLINED, FSF_BOLD, ... */
28 WORD cwidth;
29 WORD cheight;
30 } ZTextChunk;
32 typedef struct ZTextLine {
33 struct MinNode node; /* embedded node */
34 UBYTE align; /* ZTL_CENTER, ZTL_RIGHT, ZTL_LEFT */
35 struct MinList chunklist;
36 WORD lwidth;
37 WORD lheight;
38 } ZTextLine;
40 struct ZText {
41 WORD width; /* store calculated bounds - read only ! */
42 WORD height;
44 /* private */
45 struct MinList lines;
48 typedef struct ZText ZText;
50 /* zune_text_new argtypes */
51 enum {
52 ZTEXT_ARG_NONE,
53 ZTEXT_ARG_HICHAR, /* following arg is the HiChar */
54 ZTEXT_ARG_HICHARIDX, /* following arg is the HiCharIdx */
57 ZText *zune_text_new (CONST_STRPTR preparse, CONST_STRPTR content, int argtype, TEXT arg);
58 void zune_text_destroy (ZText *text);
59 void zune_text_get_bounds (ZText *text, Object *obj);
60 void zune_text_draw (ZText *text, Object *obj, WORD left, WORD right, WORD top);
62 #endif