X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Foutput%2Ftab.h;h=f0cffc17fdde48e1cdca4b9503fe659061749f35;hb=df2f1ae30c2835a39f4bc6b0c14f10a2090d9401;hp=db38b6b8144d0b94cb638a7abe0c65174d1b7b48;hpb=f550aee00a62fe1d8baf62d83cd7efef6cc2ee92;p=pspp diff --git a/src/output/tab.h b/src/output/tab.h index db38b6b814..f0cffc17fd 100644 --- a/src/output/tab.h +++ b/src/output/tab.h @@ -1,5 +1,5 @@ /* PSPP - a program for statistical analysis. - Copyright (C) 1997, 1998, 1999, 2000, 2009 Free Software Foundation, Inc. + Copyright (C) 1997, 1998, 1999, 2000, 2009, 2011, 2014 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 @@ -38,8 +38,18 @@ the table code here. */ -#include -#include +#include "libpspp/compiler.h" +#include "output/table.h" +#include "data/format.h" + +enum result_class + { + RC_INTEGER, + RC_WEIGHT, + RC_PVALUE, + RC_OTHER, + n_RC + }; /* A table. */ struct tab_table @@ -68,6 +78,8 @@ struct tab_table /* X and Y offsets. */ int col_ofs, row_ofs; + + struct fmt_spec fmtmap [n_RC]; }; struct tab_table *tab_cast (const struct table *); @@ -106,19 +118,19 @@ void tab_box (struct tab_table *, int f_h, int f_v, int i_h, int i_v, /* Obsolete cell options. */ #define TAT_TITLE TAB_EMPH /* Title attributes. */ +void tab_set_format (struct tab_table *, enum result_class, const struct fmt_spec *); + + /* Cells. */ struct fmt_spec; struct dictionary; union value; void tab_value (struct tab_table *, int c, int r, unsigned char opt, - const union value *, const struct dictionary *dict, + const union value *, const struct variable *, const struct fmt_spec *); -void tab_fixed (struct tab_table *, int c, int r, unsigned char opt, - double v, int w, int d); - void tab_double (struct tab_table *, int c, int r, unsigned char opt, - double v, const struct fmt_spec *); + double v, const struct fmt_spec *, enum result_class ); void tab_text (struct tab_table *, int c, int r, unsigned opt, const char *); void tab_text_format (struct tab_table *, int c, int r, unsigned opt, @@ -131,6 +143,11 @@ void tab_joint_text_format (struct tab_table *, int x1, int y1, int x2, int y2, unsigned opt, const char *, ...) PRINTF_FORMAT (7, 8); +void tab_subtable (struct tab_table *, int x1, int y1, int x2, int y2, + unsigned opt, struct table *subtable); +void tab_subtable_bare (struct tab_table *, int x1, int y1, int x2, int y2, + unsigned opt, struct table *subtable); + bool tab_cell_is_empty (const struct tab_table *, int c, int r); /* Editing. */