enum
{
/* Horizontal alignment of cell contents. */
- TAB_RIGHT = 0 << (TAB_FIRST_AVAILABLE + 2),
- TAB_LEFT = 1 << (TAB_FIRST_AVAILABLE + 2),
- TAB_CENTER = 2 << (TAB_FIRST_AVAILABLE + 2),
- TAB_HALIGN = 3 << (TAB_FIRST_AVAILABLE + 2), /* Alignment mask. */
+ TAB_RIGHT = 0 << (TAB_FIRST_AVAILABLE + 4),
+ TAB_LEFT = 1 << (TAB_FIRST_AVAILABLE + 4),
+ TAB_CENTER = 2 << (TAB_FIRST_AVAILABLE + 4),
+ TAB_HALIGN = 3 << (TAB_FIRST_AVAILABLE + 4), /* Alignment mask. */
/* Vertical alignment of cell contents. */
- TAB_TOP = 0 << (TAB_FIRST_AVAILABLE + 4),
- TAB_MIDDLE = 1 << (TAB_FIRST_AVAILABLE + 4),
- TAB_BOTTOM = 2 << (TAB_FIRST_AVAILABLE + 4),
- TAB_VALIGN = 3 << (TAB_FIRST_AVAILABLE + 4), /* Alignment mask. */
+ TAB_TOP = 0 << (TAB_FIRST_AVAILABLE + 6),
+ TAB_MIDDLE = 1 << (TAB_FIRST_AVAILABLE + 6),
+ TAB_BOTTOM = 2 << (TAB_FIRST_AVAILABLE + 6),
+ TAB_VALIGN = 3 << (TAB_FIRST_AVAILABLE + 6), /* Alignment mask. */
};
/* Rule masks. */
struct tab_table *tab = tab_create (1, 1);
struct area_style *style = pool_alloc (tab->container, sizeof *style);
- *style = (struct area_style) AREA_STYLE_INITIALIZER;
+ *style = (struct area_style) { AREA_STYLE_INITIALIZER__,
+ .cell_style.halign = TABLE_HALIGN_LEFT };
struct font_style *font_style = &style->font_style;
if (text_item->typeface)
font_style->typeface = pool_strdup (tab->container, text_item->typeface);
font_style->markup = text_item->markup;
tab->styles[0] = style;
- int opts = TAB_LEFT;
+ int opts = 0;
if (text_item->markup)
opts |= TAB_MARKUP;
if (text_item->type == TEXT_ITEM_SYNTAX || text_item->type == TEXT_ITEM_LOG)