1 /* -*- mode: C; c-basic-offset: 4; indent-tabs-mode: nil; -*- */
2 #ifndef __HIPPO_CANVAS_TEXT_H__
3 #define __HIPPO_CANVAS_TEXT_H__
5 /* A text paragraph canvas item. */
7 #include "hippo-canvas-box.h"
9 #include <pango/pango.h>
14 HIPPO_CANVAS_SIZE_FULL_WIDTH
,
15 HIPPO_CANVAS_SIZE_WRAP_WORD
,
16 HIPPO_CANVAS_SIZE_ELLIPSIZE_END
17 } HippoCanvasSizeMode
;
19 typedef struct _HippoCanvasText HippoCanvasText
;
20 typedef struct _HippoCanvasTextClass HippoCanvasTextClass
;
22 #define HIPPO_TYPE_CANVAS_TEXT (hippo_canvas_text_get_type ())
23 #define HIPPO_CANVAS_TEXT(object) (G_TYPE_CHECK_INSTANCE_CAST ((object), HIPPO_TYPE_CANVAS_TEXT, HippoCanvasText))
24 #define HIPPO_CANVAS_TEXT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), HIPPO_TYPE_CANVAS_TEXT, HippoCanvasTextClass))
25 #define HIPPO_IS_CANVAS_TEXT(object) (G_TYPE_CHECK_INSTANCE_TYPE ((object), HIPPO_TYPE_CANVAS_TEXT))
26 #define HIPPO_IS_CANVAS_TEXT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), HIPPO_TYPE_CANVAS_TEXT))
27 #define HIPPO_CANVAS_TEXT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), HIPPO_TYPE_CANVAS_TEXT, HippoCanvasTextClass))
29 struct _HippoCanvasText
{
32 PangoAttrList
*attributes
;
35 guint is_ellipsized
: 1;
38 struct _HippoCanvasTextClass
{
39 HippoCanvasBoxClass parent_class
;
43 GType
hippo_canvas_text_get_type (void) G_GNUC_CONST
;
45 HippoCanvasItem
* hippo_canvas_text_new (void);
50 #endif /* __HIPPO_CANVAS_TEXT_H__ */