X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=tests%2Foutput%2Frender-test.c;h=c382ee12c5ef307e51c03deca6fd3cc4f98f5e71;hb=0625520a58e3cb811d699808e9df95593f7373a9;hp=b9ddd3e7f9491976a85c4dcfbeb9d1c821ed4a02;hpb=e45cdf7b0e1b1b9ef41df8ce91fe65e3f944ea61;p=pspp diff --git a/tests/output/render-test.c b/tests/output/render-test.c index b9ddd3e7f9..c382ee12c5 100644 --- a/tests/output/render-test.c +++ b/tests/output/render-test.c @@ -114,7 +114,7 @@ main (int argc, char **argv) } table = tables[n_tables - 1]; - table_item_submit (table_item_create (table, NULL, NULL)); + table_item_submit (table_item_create (table)); free (tables); } else @@ -413,13 +413,15 @@ read_table (FILE *stream) cs = 1; } -#define S(H) { AREA_STYLE_INITIALIZER__, .cell_style.halign = H } - static const struct area_style left_style = S (TABLE_HALIGN_LEFT); - static const struct area_style right_style = S (TABLE_HALIGN_RIGHT); - static const struct area_style center_style +#define S(H) { TABLE_AREA_STYLE_INITIALIZER__, .cell_style.halign = H } + static const struct table_area_style left_style + = S (TABLE_HALIGN_LEFT); + static const struct table_area_style right_style + = S (TABLE_HALIGN_RIGHT); + static const struct table_area_style center_style = S (TABLE_HALIGN_CENTER); - const struct area_style *style = &right_style; + const struct table_area_style *style = &right_style; while (*text && strchr ("<>^,@()|", *text)) switch (*text++) { @@ -471,14 +473,16 @@ read_table (FILE *stream) { table_joint_text (tab, c, r, c + cs - 1, r + rs - 1, 0, content); - table_add_style (tab, c, r, style); + table_add_style (tab, c, r, + CONST_CAST (struct table_area_style *, + style)); } else { char marker[2] = { 'a' + n_footnotes, '\0' }; struct footnote *f = table_create_footnote ( tab, n_footnotes, content, marker, - area_style_clone (tab->container, &left_style)); + table_area_style_clone (tab->container, &left_style)); table_add_footnote (tab, c, r, f); n_footnotes++; }