output: Add support for colors for rules.
[pspp] / src / output / table-transpose.c
index 59801942cb9b2dd6af4a324949b7c87ff47b7dc1..aa617b3aaa94ea221f1f21f262992a210fb819fd 100644 (file)
@@ -1,5 +1,5 @@
 /* PSPP - a program for statistical analysis.
-   Copyright (C) 2009 Free Software Foundation, Inc.
+   Copyright (C) 2009, 2011 Free Software Foundation, Inc.
 
    This program is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
@@ -16,9 +16,9 @@
 
 #include <config.h>
 
-#include <libpspp/assertion.h>
-#include <libpspp/cast.h>
-#include <output/table-provider.h>
+#include "libpspp/assertion.h"
+#include "libpspp/cast.h"
+#include "output/table-provider.h"
 
 #include "gl/minmax.h"
 #include "gl/xalloc.h"
@@ -34,7 +34,7 @@ static const struct table_class table_transpose_class;
 static struct table_transpose *
 table_transpose_cast (const struct table *table)
 {
-  assert (table->class == &table_transpose_class);
+  assert (table->klass == &table_transpose_class);
   return UP_CAST (table, struct table_transpose, table);
 }
 
@@ -46,7 +46,7 @@ table_transpose (struct table *subtable)
   if (subtable->n[TABLE_HORZ] == subtable->n[TABLE_VERT]
       && subtable->n[TABLE_HORZ] <= 1)
     return subtable;
-  else if (subtable->class == &table_transpose_class)
+  else if (subtable->klass == &table_transpose_class)
     {
       struct table_transpose *tt = table_transpose_cast (subtable);
       struct table *table = table_ref (tt->subtable);
@@ -103,10 +103,10 @@ table_transpose_get_cell (const struct table *ti, int x, int y,
 static int
 table_transpose_get_rule (const struct table *ti,
                           enum table_axis axis,
-                          int x, int y)
+                          int x, int y, struct cell_color *color)
 {
   struct table_transpose *tt = table_transpose_cast (ti);
-  return table_get_rule (tt->subtable, !axis, y, x);
+  return table_get_rule (tt->subtable, !axis, y, x, color);
 }
 
 static const struct table_class table_transpose_class =