projects
/
pspp
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Added crosstabs dialog
[pspp]
/
lib
/
gtksheet
/
gsheet-column-iface.c
diff --git
a/lib/gtksheet/gsheet-column-iface.c
b/lib/gtksheet/gsheet-column-iface.c
index df3c90658f03c92471dcd628845a4a36a64085eb..36fb5e214bc5e47ca58552575cd55f973c21828f 100644
(file)
--- a/
lib/gtksheet/gsheet-column-iface.c
+++ b/
lib/gtksheet/gsheet-column-iface.c
@@
-1,4
+1,4
@@
-/* GSheetColumn --- an abstract model of the column geometry of a
+/* GSheetColumn --- an abstract model of the column geometry of a
GSheet widget.
* Copyright (C) 2006 Free Software Foundation
GSheet widget.
* Copyright (C) 2006 Free Software Foundation
@@
-18,6
+18,8
@@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#include <config.h>
+
#include <stdlib.h>
#include <string.h>
#include <glib.h>
#include <stdlib.h>
#include <string.h>
#include <glib.h>
@@
-98,59
+100,58
@@
g_sheet_column_base_init (gpointer g_class)
}
}
-inline void
-g_sheet_column_set_width (GSheetColumn *column, gint col, gint size,
- gpointer data)
+inline void
+g_sheet_column_set_width (GSheetColumn *column, glong col, gint size)
{
g_return_if_fail (G_IS_SHEET_COLUMN (column));
{
g_return_if_fail (G_IS_SHEET_COLUMN (column));
- if ((G_SHEET_COLUMN_GET_IFACE (column)->set_width) )
- (G_SHEET_COLUMN_GET_IFACE (column)->set_width) (column, col, size
, data
);
+ if ((G_SHEET_COLUMN_GET_IFACE (column)->set_width) )
+ (G_SHEET_COLUMN_GET_IFACE (column)->set_width) (column, col, size);
}
}
-inline gint
-g_sheet_column_get_width (const GSheetColumn *column, g
int col, gpointer data
)
+inline gint
+g_sheet_column_get_width (const GSheetColumn *column, g
long col
)
{
g_return_val_if_fail (G_IS_SHEET_COLUMN (column), -1);
g_assert (G_SHEET_COLUMN_GET_IFACE (column)->get_width);
{
g_return_val_if_fail (G_IS_SHEET_COLUMN (column), -1);
g_assert (G_SHEET_COLUMN_GET_IFACE (column)->get_width);
-
- return (G_SHEET_COLUMN_GET_IFACE (column)->get_width) (column, col
, data
);
+
+ return (G_SHEET_COLUMN_GET_IFACE (column)->get_width) (column, col);
}
}
-inline gboolean
+inline gboolean
g_sheet_column_get_visibility(const GSheetColumn *column,
g_sheet_column_get_visibility(const GSheetColumn *column,
- g
int col, gpointer data
)
+ g
long col
)
{
g_return_val_if_fail (G_IS_SHEET_COLUMN (column), FALSE);
g_assert (G_SHEET_COLUMN_GET_IFACE (column)->get_visibility);
{
g_return_val_if_fail (G_IS_SHEET_COLUMN (column), FALSE);
g_assert (G_SHEET_COLUMN_GET_IFACE (column)->get_visibility);
-
- return (G_SHEET_COLUMN_GET_IFACE (column)->get_visibility) (column,
- col
, data
);
+
+ return (G_SHEET_COLUMN_GET_IFACE (column)->get_visibility) (column,
+ col);
}
}
-inline gboolean
+inline gboolean
g_sheet_column_get_sensitivity(const GSheetColumn *column,
g_sheet_column_get_sensitivity(const GSheetColumn *column,
- g
int col, gpointer data
)
+ g
long col
)
{
g_return_val_if_fail (G_IS_SHEET_COLUMN (column), FALSE);
g_assert (G_SHEET_COLUMN_GET_IFACE (column)->get_sensitivity);
{
g_return_val_if_fail (G_IS_SHEET_COLUMN (column), FALSE);
g_assert (G_SHEET_COLUMN_GET_IFACE (column)->get_sensitivity);
-
- return (G_SHEET_COLUMN_GET_IFACE (column)->get_sensitivity) (column,
- col
, data
);
+
+ return (G_SHEET_COLUMN_GET_IFACE (column)->get_sensitivity) (column,
+ col);
}
inline GtkSheetButton *
g_sheet_column_get_button(const GSheetColumn *column,
}
inline GtkSheetButton *
g_sheet_column_get_button(const GSheetColumn *column,
- g
int col, gpointer data
)
+ g
long col
)
{
GtkSheetButton *button = gtk_sheet_button_new();
{
GtkSheetButton *button = gtk_sheet_button_new();
@@
-159,99
+160,109
@@
g_sheet_column_get_button(const GSheetColumn *column,
g_return_val_if_fail (G_IS_SHEET_COLUMN (column), FALSE);
if ( iface->get_button_label)
g_return_val_if_fail (G_IS_SHEET_COLUMN (column), FALSE);
if ( iface->get_button_label)
- button->label = iface->get_button_label(column, col
, data
);
+ button->label = iface->get_button_label(column, col);
return button;
}
return button;
}
-inline GtkJustification
-g_sheet_column_get_justification(const GSheetColumn *column,
- g
int col, gpointer data
)
+inline GtkJustification
+g_sheet_column_get_justification(const GSheetColumn *column,
+ g
long col
)
{
g_return_val_if_fail (G_IS_SHEET_COLUMN (column), FALSE);
g_assert (G_SHEET_COLUMN_GET_IFACE (column)->get_justification);
{
g_return_val_if_fail (G_IS_SHEET_COLUMN (column), FALSE);
g_assert (G_SHEET_COLUMN_GET_IFACE (column)->get_justification);
-
- return (G_SHEET_COLUMN_GET_IFACE (column)->get_justification) (column, col
, data
);
+
+ return (G_SHEET_COLUMN_GET_IFACE (column)->get_justification) (column, col);
}
}
+inline gchar *
+g_sheet_column_get_subtitle (const GSheetColumn *column, glong col)
+{
+ g_return_val_if_fail (G_IS_SHEET_COLUMN (column), NULL);
+ if ( ! G_SHEET_COLUMN_GET_IFACE (column)->get_subtitle)
+ return NULL;
+ return (G_SHEET_COLUMN_GET_IFACE (column)->get_subtitle) (column, col);
+}
-inline gint
+
+
+inline gint
g_sheet_column_get_left_text_column (const GSheetColumn *column,
g_sheet_column_get_left_text_column (const GSheetColumn *column,
- g
int col, gpointer data
)
+ g
long col
)
{
g_return_val_if_fail (G_IS_SHEET_COLUMN (column), -1);
if ( ! G_SHEET_COLUMN_GET_IFACE (column)->get_left_text_column)
return col;
{
g_return_val_if_fail (G_IS_SHEET_COLUMN (column), -1);
if ( ! G_SHEET_COLUMN_GET_IFACE (column)->get_left_text_column)
return col;
-
- return (G_SHEET_COLUMN_GET_IFACE (column)->get_left_text_column) (column, col
, data
);
+
+ return (G_SHEET_COLUMN_GET_IFACE (column)->get_left_text_column) (column, col);
}
}
-inline gint
+inline gint
g_sheet_column_get_right_text_column (const GSheetColumn *column,
g_sheet_column_get_right_text_column (const GSheetColumn *column,
- g
int col, gpointer data
)
+ g
long col
)
{
g_return_val_if_fail (G_IS_SHEET_COLUMN (column), -1);
if ( ! G_SHEET_COLUMN_GET_IFACE (column)->get_right_text_column)
return col;
{
g_return_val_if_fail (G_IS_SHEET_COLUMN (column), -1);
if ( ! G_SHEET_COLUMN_GET_IFACE (column)->get_right_text_column)
return col;
-
- return (G_SHEET_COLUMN_GET_IFACE (column)->get_right_text_column) (column, col
, data
);
+
+ return (G_SHEET_COLUMN_GET_IFACE (column)->get_right_text_column) (column, col);
}
}
-inline void
+inline void
g_sheet_column_set_left_text_column (const GSheetColumn *column,
g_sheet_column_set_left_text_column (const GSheetColumn *column,
- g
int col, gint i, gpointer data
)
+ g
long col, gint i
)
{
g_return_if_fail (G_IS_SHEET_COLUMN (column));
if ( G_SHEET_COLUMN_GET_IFACE (column)->set_left_text_column)
{
g_return_if_fail (G_IS_SHEET_COLUMN (column));
if ( G_SHEET_COLUMN_GET_IFACE (column)->set_left_text_column)
- (G_SHEET_COLUMN_GET_IFACE (column)->set_left_text_column) (column, col, i
, data
);
+ (G_SHEET_COLUMN_GET_IFACE (column)->set_left_text_column) (column, col, i);
}
}
-inline void
+inline void
g_sheet_column_set_right_text_column (const GSheetColumn *column,
g_sheet_column_set_right_text_column (const GSheetColumn *column,
- g
int col, gint i, gpointer data
)
+ g
long col, gint i
)
{
g_return_if_fail (G_IS_SHEET_COLUMN (column));
if ( G_SHEET_COLUMN_GET_IFACE (column)->set_right_text_column)
{
g_return_if_fail (G_IS_SHEET_COLUMN (column));
if ( G_SHEET_COLUMN_GET_IFACE (column)->set_right_text_column)
- (G_SHEET_COLUMN_GET_IFACE (column)->set_right_text_column) (column, col, i
, data
);
+ (G_SHEET_COLUMN_GET_IFACE (column)->set_right_text_column) (column, col, i);
}
}
-inline g
int
-g_sheet_column_get_column_count(const GSheetColumn *geo
, gpointer data
)
+inline g
long
+g_sheet_column_get_column_count(const GSheetColumn *geo)
{
g_return_val_if_fail (G_IS_SHEET_COLUMN (geo), -1);
g_assert ( G_SHEET_COLUMN_GET_IFACE (geo)->get_column_count);
{
g_return_val_if_fail (G_IS_SHEET_COLUMN (geo), -1);
g_assert ( G_SHEET_COLUMN_GET_IFACE (geo)->get_column_count);
- return (G_SHEET_COLUMN_GET_IFACE (geo)->get_column_count) (geo
, data
);
+ return (G_SHEET_COLUMN_GET_IFACE (geo)->get_column_count) (geo);
}
}
-inline gint
-g_sheet_column_start_pixel(const GSheetColumn *geo, g
int col, gpointer data
)
+inline gint
+g_sheet_column_start_pixel(const GSheetColumn *geo, g
long col
)
{
gint i;
gint start_pixel = 0;
g_return_val_if_fail (G_IS_SHEET_COLUMN (geo), -1);
{
gint i;
gint start_pixel = 0;
g_return_val_if_fail (G_IS_SHEET_COLUMN (geo), -1);
- g_return_val_if_fail (col <
- g_sheet_column_get_column_count(geo
, data
),-1);
+ g_return_val_if_fail (col <
+ g_sheet_column_get_column_count(geo),-1);
- for ( i = 0 ; i < col ; ++i )
+ for ( i = 0 ; i < col ; ++i )
{
{
- if ( g_sheet_column_get_visibility(geo, i
, data
))
- start_pixel += g_sheet_column_get_width(geo, i
, data
);
+ if ( g_sheet_column_get_visibility(geo, i))
+ start_pixel += g_sheet_column_get_width(geo, i);
}
}
-
+
return start_pixel;
}
return start_pixel;
}
@@
-259,12
+270,12
@@
g_sheet_column_start_pixel(const GSheetColumn *geo, gint col, gpointer data)
inline void
inline void
-g_sheet_column_columns_changed(GSheetColumn *geo,
- g
int first, gint
n_columns)
+g_sheet_column_columns_changed(GSheetColumn *geo,
+ g
long first, glong
n_columns)
{
g_return_if_fail (G_IS_SHEET_COLUMN (geo));
{
g_return_if_fail (G_IS_SHEET_COLUMN (geo));
- g_signal_emit (geo, sheet_column_signals[COLUMNS_CHANGED], 0,
+ g_signal_emit (geo, sheet_column_signals[COLUMNS_CHANGED], 0,
first, n_columns);
}
first, n_columns);
}