work
[pspp] / tests / output / render-test.c
index b9ddd3e7f9491976a85c4dcfbeb9d1c821ed4a02..c382ee12c5ef307e51c03deca6fd3cc4f98f5e71 100644 (file)
@@ -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++;
               }