-static void g_sheet_column_base_init (gpointer g_class);
+static void g_sheet_column_base_init (gpointer g_class);
GType
g_type_register_static (G_TYPE_INTERFACE, "GSheetColumn",
&sheet_column_info, 0);
- g_assert(sheet_column_type);
+ g_assert (sheet_column_type);
g_type_interface_add_prerequisite (sheet_column_type, G_TYPE_OBJECT);
}
gboolean
-g_sheet_column_get_visibility(const GSheetColumn *column,
+g_sheet_column_get_visibility (const GSheetColumn *column,
glong col)
{
g_return_val_if_fail (G_IS_SHEET_COLUMN (column), FALSE);
}
gboolean
-g_sheet_column_get_sensitivity(const GSheetColumn *column,
+g_sheet_column_get_sensitivity (const GSheetColumn *column,
glong col)
{
g_return_val_if_fail (G_IS_SHEET_COLUMN (column), FALSE);
GtkSheetButton *
-g_sheet_column_get_button(const GSheetColumn *column,
+g_sheet_column_get_button (const GSheetColumn *column,
glong col)
{
- GtkSheetButton *button = gtk_sheet_button_new();
+ GtkSheetButton *button = gtk_sheet_button_new ();
GSheetColumnIface *iface = G_SHEET_COLUMN_GET_IFACE (column);
g_return_val_if_fail (G_IS_SHEET_COLUMN (column), FALSE);
if ( iface->get_button_label)
- button->label = iface->get_button_label(column, col);
+ button->label = iface->get_button_label (column, col);
return button;
}
GtkJustification
-g_sheet_column_get_justification(const GSheetColumn *column,
+g_sheet_column_get_justification (const GSheetColumn *column,
glong col)
{
g_return_val_if_fail (G_IS_SHEET_COLUMN (column), FALSE);
}
glong
-g_sheet_column_get_column_count(const GSheetColumn *geo)
+g_sheet_column_get_column_count (const GSheetColumn *geo)
{
g_return_val_if_fail (G_IS_SHEET_COLUMN (geo), -1);
}
gint
-g_sheet_column_start_pixel(const GSheetColumn *geo, glong col)
+g_sheet_column_start_pixel (const GSheetColumn *geo, glong col)
{
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),-1);
+ g_return_val_if_fail (col < g_sheet_column_get_column_count (geo), -1);
for ( i = 0 ; i < col ; ++i )
{
- if ( g_sheet_column_get_visibility(geo, i))
- start_pixel += g_sheet_column_get_width(geo, i);
+ if ( g_sheet_column_get_visibility (geo, i))
+ start_pixel += g_sheet_column_get_width (geo, i);
}
return start_pixel;
void
-g_sheet_column_columns_changed(GSheetColumn *geo,
+g_sheet_column_columns_changed (GSheetColumn *geo,
glong first, glong n_columns)
{
g_return_if_fail (G_IS_SHEET_COLUMN (geo));
-static void g_sheet_row_base_init (gpointer g_class);
+static void g_sheet_row_base_init (gpointer g_class);
GType
gboolean
-g_sheet_row_get_visibility(const GSheetRow *row_geo,
+g_sheet_row_get_visibility (const GSheetRow *row_geo,
glong row)
{
g_return_val_if_fail (G_IS_SHEET_ROW (row_geo), FALSE);
}
gboolean
-g_sheet_row_get_sensitivity(const GSheetRow *row_geo,
+g_sheet_row_get_sensitivity (const GSheetRow *row_geo,
glong row)
{
g_return_val_if_fail (G_IS_SHEET_ROW (row_geo), FALSE);
GtkSheetButton *
-g_sheet_row_get_button(const GSheetRow *row_geo,
+g_sheet_row_get_button (const GSheetRow *row_geo,
glong row)
{
- GtkSheetButton *button = gtk_sheet_button_new();
+ GtkSheetButton *button = gtk_sheet_button_new ();
GSheetRowIface *iface = G_SHEET_ROW_GET_IFACE (row_geo);
g_return_val_if_fail (G_IS_SHEET_ROW (row_geo), FALSE);
if ( iface->get_button_label)
- button->label = iface->get_button_label(row_geo, row);
+ button->label = iface->get_button_label (row_geo, row);
return button;
}
*/
gint
-g_sheet_row_start_pixel(const GSheetRow *geo, glong row)
+g_sheet_row_start_pixel (const GSheetRow *geo, glong row)
{
gint i;
gint start_pixel = 0;
g_return_val_if_fail (G_IS_SHEET_ROW (geo), -1);
g_return_val_if_fail (row >= 0, -1);
- g_return_val_if_fail (row <
- g_sheet_row_get_row_count(geo),-1);
+ g_return_val_if_fail (row < g_sheet_row_get_row_count (geo), -1);
- if ( G_SHEET_ROW_GET_IFACE(geo)->top_ypixel)
- return (G_SHEET_ROW_GET_IFACE(geo)->top_ypixel)(geo, row);
+ if ( G_SHEET_ROW_GET_IFACE (geo)->top_ypixel)
+ return (G_SHEET_ROW_GET_IFACE (geo)->top_ypixel)(geo, row);
for ( i = 0 ; i < row ; ++i )
{
- if ( g_sheet_row_get_visibility(geo, i))
- start_pixel += g_sheet_row_get_height(geo, i);
+ if ( g_sheet_row_get_visibility (geo, i))
+ start_pixel += g_sheet_row_get_height (geo, i);
}
return start_pixel;
g_return_val_if_fail (G_IS_SHEET_ROW (geo), -1);
g_return_val_if_fail (pixel >= 0, -1) ;
- if ( G_SHEET_ROW_GET_IFACE(geo)->pixel_to_row)
- return (G_SHEET_ROW_GET_IFACE(geo)->pixel_to_row)(geo, pixel);
+ if ( G_SHEET_ROW_GET_IFACE (geo)->pixel_to_row)
+ return (G_SHEET_ROW_GET_IFACE (geo)->pixel_to_row)(geo, pixel);
cy = 0;
for (i = 0; i < g_sheet_row_get_row_count (geo); ++i )
g_sheet_row_get_visibility (geo, i))
return i;
- if(g_sheet_row_get_visibility (geo, i))
+ if (g_sheet_row_get_visibility (geo, i))
cy += g_sheet_row_get_height (geo, i);
}