[gnumeric] Set the "hexpand" property to TRUE for toolbars. [#655858]
- From: Jean BrÃfort <jbrefort src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnumeric] Set the "hexpand" property to TRUE for toolbars. [#655858]
- Date: Wed, 3 Aug 2011 06:31:07 +0000 (UTC)
commit 70e128954282dee34b097c2c77d5f711ea5f01fa
Author: Jean Brefort <jean brefort normalesup org>
Date: Wed Aug 3 08:35:03 2011 +0200
Set the "hexpand" property to TRUE for toolbars. [#655858]
ChangeLog | 5 +
component/gnumeric.c | 4 +-
plugins/excel/excel-xml-read.c | 6 +-
plugins/excel/xlsx-read-docprops.c | 18 ++--
plugins/excel/xlsx-read-drawing.c | 2 +-
plugins/excel/xlsx-read.c | 10 +-
plugins/excel/xlsx-utils.c | 4 +-
plugins/excel/xlsx-write-docprops.c | 48 ++++----
plugins/excel/xlsx-write-pivot.c | 4 +-
plugins/excel/xlsx-write.c | 246 ++++++++++++++++----------------
plugins/fn-tsa/functions.c | 6 +-
plugins/lotus-123/lotus-formula.c | 4 +-
plugins/lotus-123/lotus.c | 6 +-
plugins/openoffice/openoffice-read.c | 238 ++++++++++++++++----------------
plugins/openoffice/openoffice-write.c | 232 ++++++++++++++++----------------
src/application.c | 2 +-
src/collect.c | 16 +-
src/commands.c | 2 +-
src/compilation.h | 2 +-
src/dialogs/dialog-analysis-tools.c | 2 +-
src/dialogs/dialog-cell-format-cond.c | 216 ++++++++++++++--------------
src/dialogs/dialog-cell-format.c | 16 +-
src/dialogs/dialog-doc-metadata.c | 100 +++++++-------
src/dialogs/dialog-function-select.c | 2 +-
src/dialogs/dialog-goto-cell.c | 24 ++--
src/dialogs/dialog-printer-setup.c | 30 ++--
src/func.c | 6 +-
src/gnm-format.c | 8 +-
src/gui-clipboard.c | 4 +-
src/gui-file.c | 34 +++---
src/gui-file.h | 6 +-
src/gui-util.c | 16 +-
src/parser.y | 2 +-
src/print-cell.c | 6 +-
src/print-info.c | 16 +-
src/print-info.h | 10 +-
src/print.c | 34 +++---
src/rendered-value.c | 10 +-
src/sheet-control-gui.c | 2 +-
src/stf.c | 4 +-
src/style-conditions.c | 4 +-
src/wbc-gtk-actions.c | 22 ++--
src/wbc-gtk.c | 1 +
src/widgets/gnm-format-sel.c | 2 +-
src/widgets/gnumeric-expr-entry.c | 4 +-
src/workbook-control.c | 10 +-
src/workbook-view.c | 6 +-
src/workbook.c | 2 +-
src/xml-sax-read.c | 2 +-
src/xml-sax-write.c | 20 ++--
50 files changed, 741 insertions(+), 735 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index f81208e..d3253a3 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2011-08-03 Jean Brefort <jean brefort normalesup org>
+
+ * src/wbc-gtk.c (cb_add_menus_toolbars): set the "hexpand" property to
+ TRUE for toolbars. [#655858]
+
2011-08-02 Andreas J. Guelzow <aguelzow pyrshep ca>
* src/wbc-gtk.c (cb_add_menus_toolbars): the box is now a GtkHandleBox
diff --git a/component/gnumeric.c b/component/gnumeric.c
index cb344a7..b6051bf 100644
--- a/component/gnumeric.c
+++ b/component/gnumeric.c
@@ -149,7 +149,7 @@ go_gnm_component_render (GOComponent *component, cairo_t *cr, double width_pixel
cairo_scale (cr, ((double) width_pixels) / gognm->width, ((double) height_pixels) / gognm->height);
cairo_rectangle (cr, 0., 0., gognm->width, gognm->height);
cairo_clip (cr); /* not sure it is necessary */
- gnm_gtk_print_cell_range (cr, gognm->sheet, &range, 0., 0.,
+ gnm_gtk_print_cell_range (cr, gognm->sheet, &range, 0., 0.,
gognm->sheet->print_info);
/* Now render objects */
gnm_print_sheet_objects (cr, gognm->sheet, &range, 0., 0.);
@@ -302,7 +302,7 @@ go_plugin_init (GOPlugin *plugin, G_GNUC_UNUSED GOCmdContext *cc)
}
G_MODULE_EXPORT void
-go_plugin_shutdown (G_GNUC_UNUSED GOPlugin *plugin,
+go_plugin_shutdown (G_GNUC_UNUSED GOPlugin *plugin,
G_GNUC_UNUSED GOCmdContext *cc)
{
}
diff --git a/plugins/excel/excel-xml-read.c b/plugins/excel/excel-xml-read.c
index b9eaab1..87e8dce 100644
--- a/plugins/excel/excel-xml-read.c
+++ b/plugins/excel/excel-xml-read.c
@@ -492,7 +492,7 @@ xl_xml_data_end (GsfXMLIn *xin, G_GNUC_UNUSED GsfXMLBlob *blob)
"received '%s'"),
xin->content->str);
} else
- v = value_new_from_string (state->val_type, xin->content->str,
+ v = value_new_from_string (state->val_type, xin->content->str,
NULL, FALSE);
if (NULL != state->texpr) {
if (NULL != v)
@@ -1050,7 +1050,7 @@ xl_xml_probe_start_element (const xmlChar *name,
}
gboolean
-excel_xml_file_probe (G_GNUC_UNUSED GOFileOpener const *fo,
+excel_xml_file_probe (G_GNUC_UNUSED GOFileOpener const *fo,
GsfInput *input, GOFileProbeLevel pl)
{
if (pl == GO_FILE_PROBE_FILE_NAME) {
@@ -1065,7 +1065,7 @@ excel_xml_file_probe (G_GNUC_UNUSED GOFileOpener const *fo,
}
void
-excel_xml_file_open (G_GNUC_UNUSED GOFileOpener const *fo,
+excel_xml_file_open (G_GNUC_UNUSED GOFileOpener const *fo,
GOIOContext *io_context,
WorkbookView *wb_view, GsfInput *input)
{
diff --git a/plugins/excel/xlsx-read-docprops.c b/plugins/excel/xlsx-read-docprops.c
index b926484..49c5011 100644
--- a/plugins/excel/xlsx-read-docprops.c
+++ b/plugins/excel/xlsx-read-docprops.c
@@ -71,7 +71,7 @@ xlsx_read_prop_type (GsfXMLIn *xin, GType g_type)
XLSXReadState *state = (XLSXReadState *)xin->user_state;
GValue *res = g_new0 (GValue, 1);
if (gsf_xml_gvalue_from_str (res, g_type, xin->content->str))
- gsf_doc_meta_data_insert
+ gsf_doc_meta_data_insert
(state->metadata,
g_strdup (xin->node->user_data.v_str), res);
else
@@ -133,7 +133,7 @@ xlsx_read_custom_property_type (GsfXMLIn *xin, GType g_type)
{
XLSXReadState *state = (XLSXReadState *)xin->user_state;
GValue *res;
-
+
if (state->meta_prop_name == NULL) {
xlsx_warning (xin, _("Corrupt file: Second child element in custom property encountered."));
return;
@@ -141,12 +141,12 @@ xlsx_read_custom_property_type (GsfXMLIn *xin, GType g_type)
res = g_new0 (GValue, 1);
if (gsf_xml_gvalue_from_str (res, g_type, xin->content->str)) {
- gsf_doc_meta_data_insert
+ gsf_doc_meta_data_insert
(state->metadata,
state->meta_prop_name, res);
state->meta_prop_name = NULL;
} else
- g_free (res);
+ g_free (res);
}
static void
@@ -243,14 +243,14 @@ xlsx_read_docprops_core (XLSXReadState *state)
{
GsfInput *in;
/* optional */
- in = gsf_open_pkg_open_rel_by_type
+ in = gsf_open_pkg_open_rel_by_type
(GSF_INPUT (state->zip),
"http://schemas.openxmlformats.org/package/2006/relationships/metadata/"
"core-properties", NULL);
-
+
if (in == NULL) return;
xlsx_parse_stream (state, in, xlsx_docprops_core_dtd);
-
+
}
static void
@@ -258,7 +258,7 @@ xlsx_read_docprops_extended (XLSXReadState *state)
{
GsfInput *in;
/* optional */
- in = gsf_open_pkg_open_rel_by_type
+ in = gsf_open_pkg_open_rel_by_type
(GSF_INPUT (state->zip),
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/"
"extended-properties", NULL);
@@ -272,7 +272,7 @@ xlsx_read_docprops_custom (XLSXReadState *state)
{
GsfInput *in;
/* optional */
- in = gsf_open_pkg_open_rel_by_type
+ in = gsf_open_pkg_open_rel_by_type
(GSF_INPUT (state->zip),
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/"
"custom-properties", NULL);
diff --git a/plugins/excel/xlsx-read-drawing.c b/plugins/excel/xlsx-read-drawing.c
index af4b4f3..82ecd3e 100644
--- a/plugins/excel/xlsx-read-drawing.c
+++ b/plugins/excel/xlsx-read-drawing.c
@@ -965,7 +965,7 @@ xlsx_chart_grad_linear (GsfXMLIn *xin, xmlChar const **attrs)
g_return_if_fail (state->cur_style);
for (; attrs != NULL && attrs[0] && attrs[1] ; attrs += 2)
if (attr_int (xin, attrs, "ang", &ang))
- state->cur_style->fill.gradient.dir
+ state->cur_style->fill.gradient.dir
= xlsx_get_gradient_direction (ang / 60000.);
/* FIXME: we do not support the "scaled" attribute */
}
diff --git a/plugins/excel/xlsx-read.c b/plugins/excel/xlsx-read.c
index d150152..6b06517 100644
--- a/plugins/excel/xlsx-read.c
+++ b/plugins/excel/xlsx-read.c
@@ -3497,7 +3497,7 @@ xlsx_col_elem_begin (GsfXMLIn *xin, xmlChar const **attrs)
static void
xlsx_col_border_begin (GsfXMLIn *xin, xmlChar const **attrs)
-{
+{
XLSXReadState *state = (XLSXReadState *)xin->user_state;
gboolean diagonal_down = FALSE, diagonal_up = FALSE;
@@ -3505,16 +3505,16 @@ xlsx_col_border_begin (GsfXMLIn *xin, xmlChar const **attrs)
for (; attrs != NULL && attrs[0] && attrs[1] ; attrs += 2)
if (attr_bool (xin, attrs, "diagonalDown", &diagonal_down)) ;
else (attr_bool (xin, attrs, "diagonalUp", &diagonal_up)) ;
-
+
if (diagonal_up) {
- GnmBorder *border = gnm_style_border_fetch
+ GnmBorder *border = gnm_style_border_fetch
(GNM_STYLE_BORDER_THIN, style_color_black (), GNM_STYLE_BORDER_DIAGONAL);
gnm_style_set_border (state->style_accum,
MSTYLE_BORDER_DIAGONAL,
border);
}
if (diagonal_down) {
- GnmBorder *border = gnm_style_border_fetch
+ GnmBorder *border = gnm_style_border_fetch
(GNM_STYLE_BORDER_HAIR, style_color_black (), GNM_STYLE_BORDER_DIAGONAL);
gnm_style_set_border (state->style_accum,
MSTYLE_BORDER_REV_DIAGONAL,
@@ -3746,7 +3746,7 @@ xlsx_border_diagonal_end (GsfXMLIn *xin, G_GNUC_UNUSED GsfXMLBlob *blob)
if (NULL == state->border_color)
state->border_color = style_color_black ();
- new_border = gnm_style_border_fetch
+ new_border = gnm_style_border_fetch
(state->border_style, state->border_color, GNM_STYLE_BORDER_DIAGONAL);
border = gnm_style_get_border (state->style_accum, MSTYLE_BORDER_REV_DIAGONAL);
diff --git a/plugins/excel/xlsx-utils.c b/plugins/excel/xlsx-utils.c
index 15b67eb..dfd6b9f 100644
--- a/plugins/excel/xlsx-utils.c
+++ b/plugins/excel/xlsx-utils.c
@@ -171,12 +171,12 @@ xlsx_pivot_date_fmt (void)
*
* Returns a GOGradientDirection corresponding to the angle ang (0...360)
**/
-GOGradientDirection
+GOGradientDirection
xlsx_get_gradient_direction (double ang)
{
int ang_i;
g_return_val_if_fail (ang >=-360. && ang <= 360., GO_GRADIENT_N_TO_S);
-
+
ang_i = ang;
while (ang_i < 0)
ang_i += 360;
diff --git a/plugins/excel/xlsx-write-docprops.c b/plugins/excel/xlsx-write-docprops.c
index 3e219b1..6e4c458 100644
--- a/plugins/excel/xlsx-write-docprops.c
+++ b/plugins/excel/xlsx-write-docprops.c
@@ -2,7 +2,7 @@
/**
* xls-write-docprops.c: MS Excel XLSX export of document properties
*
- * Copyright (C) 2011 Andreas J. Guelzow, All rights reserved
+ * Copyright (C) 2011 Andreas J. Guelzow, All rights reserved
* aguelzow pyrshep ca
*
* This program is free software; you can redistribute it and/or
@@ -76,7 +76,7 @@ xlsx_map_to_bool (GsfXMLOut *output, GValue const *val)
xlsx_add_bool (output, NULL, g_value_get_int (val) != 0);
break;
case G_TYPE_STRING:
- xlsx_add_bool (output, NULL,
+ xlsx_add_bool (output, NULL,
0 == g_ascii_strcasecmp (g_value_get_string (val), "true")
|| 0 == g_ascii_strcasecmp (g_value_get_string (val), "yes"));
break;
@@ -108,8 +108,8 @@ xlsx_map_to_date_core (GsfXMLOut *output, GValue const *val)
gsf_timestamp_set_time (ts, tm.tv_sec);
str = gsf_timestamp_as_string (ts);
gsf_xml_out_add_cstr (output, NULL, str);
- g_free (str);
- }
+ g_free (str);
+ }
}
static void
@@ -134,7 +134,7 @@ xlsx_map_to_keys (GsfXMLOut *output, GValue const *val)
/* sets of keywords depending on laguage */
g_free (str);
}
- }
+ }
}
static output_function
@@ -143,7 +143,7 @@ xlsx_map_prop_name_to_output_fun (char const *name)
/* shared by all instances and never freed */
static GHashTable *xlsx_prop_name_map_output_fun_extended = NULL;
- if (NULL == xlsx_prop_name_map_output_fun_extended)
+ if (NULL == xlsx_prop_name_map_output_fun_extended)
{
static struct {
char const *gsf_key;
@@ -189,7 +189,7 @@ xlsx_map_prop_name_extended (char const *name)
/* shared by all instances and never freed */
static GHashTable *xlsx_prop_name_map_extended = NULL;
- if (NULL == xlsx_prop_name_map_extended)
+ if (NULL == xlsx_prop_name_map_extended)
{
static struct {
char const *gsf_key;
@@ -237,7 +237,7 @@ xlsx_map_prop_name_extended (char const *name)
/* GSF_META_NAME_OBJECT_COUNT */
/* GSF_META_NAME_SPREADSHEET_COUNT */
/* GSF_META_NAME_TABLE_COUNT */
- /* GSF_META_NAME_GENERATOR stored as Application and AppVersion */
+ /* GSF_META_NAME_GENERATOR stored as Application and AppVersion */
/* GSF_META_NAME_KEYWORD cmp with GSF_META_NAME_KEYWORDS in core*/
/* GSF_META_NAME_LAST_PRINTED cmp with GSF_META_NAME_PRINT_DATE in core*/
/* GSF_META_NAME_PRINTED_BY */
@@ -263,7 +263,7 @@ xlsx_meta_write_props_extended (char const *prop_name, GsfDocProp *prop, GsfXMLO
if (NULL != (mapped_name = xlsx_map_prop_name_extended (prop_name))) {
gsf_xml_out_start_element (output, mapped_name);
if (NULL != val) {
- output_function of = xlsx_map_prop_name_to_output_fun
+ output_function of = xlsx_map_prop_name_to_output_fun
(prop_name);
if (of != NULL)
of (output, val);
@@ -277,7 +277,7 @@ xlsx_meta_write_props_extended (char const *prop_name, GsfDocProp *prop, GsfXMLO
static void
xlsx_write_docprops_app (XLSXWriteState *state, GsfOutfile *root_part, GsfOutfile *docprops_dir)
{
- GsfOutput *part = gsf_outfile_open_pkg_add_rel
+ GsfOutput *part = gsf_outfile_open_pkg_add_rel
(docprops_dir, "app.xml",
"application/vnd.openxmlformats-officedocument.extended-properties+xml",
root_part,
@@ -298,10 +298,10 @@ xlsx_write_docprops_app (XLSXWriteState *state, GsfOutfile *root_part, GsfOutfil
gsf_xml_out_add_float (xml, NULL, version, 5);
gsf_xml_out_end_element (xml); /* </AppVersion> */
- gsf_doc_meta_data_foreach (meta, (GHFunc) xlsx_meta_write_props_extended, xml);
+ gsf_doc_meta_data_foreach (meta, (GHFunc) xlsx_meta_write_props_extended, xml);
gsf_xml_out_end_element (xml); /* </Properties> */
-
+
g_object_unref (xml);
gsf_output_close (part);
g_object_unref (part);
@@ -313,7 +313,7 @@ xlsx_map_prop_name (char const *name)
/* shared by all instances and never freed */
static GHashTable *xlsx_prop_name_map = NULL;
- if (NULL == xlsx_prop_name_map)
+ if (NULL == xlsx_prop_name_map)
{
static struct {
char const *gsf_key;
@@ -356,9 +356,9 @@ xlsx_meta_write_props (char const *prop_name, GsfDocProp *prop, GsfXMLOut *outpu
GValue const *val = gsf_doc_prop_get_val (prop);
if (NULL != (mapped_name = xlsx_map_prop_name (prop_name))) {
- gsf_xml_out_start_element (output, mapped_name);
+ gsf_xml_out_start_element (output, mapped_name);
if (NULL != val) {
- output_function of = xlsx_map_prop_name_to_output_fun
+ output_function of = xlsx_map_prop_name_to_output_fun
(prop_name);
if (of != NULL)
of (output, val);
@@ -373,7 +373,7 @@ xlsx_meta_write_props (char const *prop_name, GsfDocProp *prop, GsfXMLOut *outpu
static void
xlsx_write_docprops_core (XLSXWriteState *state, GsfOutfile *root_part, GsfOutfile *docprops_dir)
{
- GsfOutput *part = gsf_outfile_open_pkg_add_rel
+ GsfOutput *part = gsf_outfile_open_pkg_add_rel
(docprops_dir, "core.xml",
"application/vnd.openxmlformats-package.core-properties+xml",
root_part,
@@ -391,7 +391,7 @@ xlsx_write_docprops_core (XLSXWriteState *state, GsfOutfile *root_part, GsfOutfi
gsf_doc_meta_data_foreach (meta, (GHFunc) xlsx_meta_write_props, xml);
gsf_xml_out_end_element (xml); /* </cp:coreProperties> */
-
+
g_object_unref (xml);
gsf_output_close (part);
g_object_unref (part);
@@ -403,7 +403,7 @@ xlsx_map_to_pid (char const *name)
/* shared by all instances and never freed */
static GHashTable *xlsx_pid_map = NULL;
- if (NULL == xlsx_pid_map)
+ if (NULL == xlsx_pid_map)
{
static struct {
char const *name_key;
@@ -425,11 +425,11 @@ xlsx_map_to_pid (char const *name)
}
static void
-xlsx_meta_write_props_custom_type (char const *prop_name, GValue const *val, GsfXMLOut *xml, char const *type,
+xlsx_meta_write_props_custom_type (char const *prop_name, GValue const *val, GsfXMLOut *xml, char const *type,
int *custom_pid)
{
int pid = xlsx_map_to_pid (prop_name);
-
+
gsf_xml_out_start_element (xml, "property");
gsf_xml_out_add_cstr_unchecked (xml, "fmtid", "{D5CDD505-2E9C-101B-9397-08002B2CF9AE}");
@@ -443,7 +443,7 @@ xlsx_meta_write_props_custom_type (char const *prop_name, GValue const *val, Gsf
gsf_xml_out_start_element (xml, type);
if (NULL != val)
gsf_xml_out_add_gvalue (xml, NULL, val);
- gsf_xml_out_end_element (xml);
+ gsf_xml_out_end_element (xml);
gsf_xml_out_end_element (xml); /* </property> */
}
@@ -451,7 +451,7 @@ static void
xlsx_meta_write_props_custom (char const *prop_name, GsfDocProp *prop, GsfXMLOut *output)
{
int custom_pid = 29;
- if ((0 != strcmp (GSF_META_NAME_GENERATOR, prop_name)) && (NULL == xlsx_map_prop_name (prop_name))
+ if ((0 != strcmp (GSF_META_NAME_GENERATOR, prop_name)) && (NULL == xlsx_map_prop_name (prop_name))
&& (NULL == xlsx_map_prop_name_extended (prop_name))) {
GValue const *val = gsf_doc_prop_get_val (prop);
if (VAL_IS_GSF_TIMESTAMP(val))
@@ -480,7 +480,7 @@ xlsx_meta_write_props_custom (char const *prop_name, GsfDocProp *prop, GsfXMLOut
static void
xlsx_write_docprops_custom (XLSXWriteState *state, GsfOutfile *root_part, GsfOutfile *docprops_dir)
{
- GsfOutput *part = gsf_outfile_open_pkg_add_rel
+ GsfOutput *part = gsf_outfile_open_pkg_add_rel
(docprops_dir, "custom.xml",
"application/vnd.openxmlformats-officedocument.custom-properties+xml",
root_part,
@@ -495,7 +495,7 @@ xlsx_write_docprops_custom (XLSXWriteState *state, GsfOutfile *root_part, GsfOut
gsf_doc_meta_data_foreach (meta, (GHFunc) xlsx_meta_write_props_custom, xml);
gsf_xml_out_end_element (xml); /* </Properties> */
-
+
g_object_unref (xml);
gsf_output_close (part);
g_object_unref (part);
diff --git a/plugins/excel/xlsx-write-pivot.c b/plugins/excel/xlsx-write-pivot.c
index 64a98f6..4fd34f3 100644
--- a/plugins/excel/xlsx-write-pivot.c
+++ b/plugins/excel/xlsx-write-pivot.c
@@ -273,7 +273,7 @@ xlsx_write_pivot_cache_definition (XLSXWriteState *state, GsfOutfile *wb_part,
if (cache->refreshed_by) gsf_xml_out_add_cstr (xml, "refreshedBy", cache->refreshed_by);
if (cache->refreshed_on) {
if (state->version == ECMA_376_2006)
- gsf_xml_out_add_float (xml, "refreshedDate",
+ gsf_xml_out_add_float (xml, "refreshedDate",
go_val_as_float (cache->refreshed_on), -1);
else {
GOFormat const *format = go_format_new_from_XL ("yyyy-mm-dd\"T\"hh:mm:ss");
@@ -281,7 +281,7 @@ xlsx_write_pivot_cache_definition (XLSXWriteState *state, GsfOutfile *wb_part,
gsf_xml_out_add_cstr_unchecked (xml, "refreshedDateIso", date);
g_free (date);
go_format_unref (format);
- }
+ }
}
gsf_xml_out_add_int (xml, "createdVersion", cache->XL_created_ver);
gsf_xml_out_add_int (xml, "refreshedVersion", cache->XL_refresh_ver);
diff --git a/plugins/excel/xlsx-write.c b/plugins/excel/xlsx-write.c
index d38fb75..f58b314 100644
--- a/plugins/excel/xlsx-write.c
+++ b/plugins/excel/xlsx-write.c
@@ -203,9 +203,9 @@ xlsx_write_predefined_fills (GsfXMLOut *xml)
gsf_xml_out_start_element (xml, "fill");
gsf_xml_out_start_element (xml, "patternFill");
gsf_xml_out_add_cstr_unchecked (xml, "patternType", *f++);
- gsf_xml_out_end_element (xml);
gsf_xml_out_end_element (xml);
- }
+ gsf_xml_out_end_element (xml);
+ }
}
static gint
@@ -216,12 +216,12 @@ xlsx_find_predefined_fill (GnmStyle const *style)
return 0;
if (gnm_style_is_element_set (style, MSTYLE_PATTERN) &&
gnm_style_get_pattern (style) == 5 &&
- (!gnm_style_is_element_set (style, MSTYLE_COLOR_PATTERN) ||
+ (!gnm_style_is_element_set (style, MSTYLE_COLOR_PATTERN) ||
gnm_style_get_pattern_color (style)->go_color == GO_COLOR_BLACK) &&
- (!gnm_style_is_element_set (style, MSTYLE_COLOR_BACK) ||
+ (!gnm_style_is_element_set (style, MSTYLE_COLOR_BACK) ||
gnm_style_get_back_color (style)->go_color == GO_COLOR_WHITE))
return 1;
-
+
return -1;
}
@@ -329,9 +329,9 @@ xlsx_load_buildin_num_formats (GHashTable *hash)
static GHashTable *
xlsx_write_num_formats (XLSXWriteState *state, GsfXMLOut *xml)
{
- GHashTable *hash = g_hash_table_new_full
+ GHashTable *hash = g_hash_table_new_full
(g_str_hash, g_str_equal, g_free, NULL);
- GHashTable *num_format_hash = g_hash_table_new
+ GHashTable *num_format_hash = g_hash_table_new
(g_direct_hash, g_direct_equal);
unsigned int n = NUM_FORMAT_BASE;
unsigned int i, count;
@@ -360,20 +360,20 @@ xlsx_write_num_formats (XLSXWriteState *state, GsfXMLOut *xml)
}
g_hash_table_insert (num_format_hash, (gpointer) style, tmp);
}
-
+
count = num_format_array->len;
if (count != 0) {
gsf_xml_out_start_element (xml, "numFmts");
gsf_xml_out_add_int (xml, "count", count);
for (i = 0 , n = NUM_FORMAT_BASE; i < count ; i++, n++) {
gsf_xml_out_start_element (xml, "numFmt");
- gsf_xml_out_add_cstr
- (xml, "formatCode",
+ gsf_xml_out_add_cstr
+ (xml, "formatCode",
g_ptr_array_index (num_format_array, i));
gsf_xml_out_add_int (xml, "numFmtId", n);
- gsf_xml_out_end_element (xml);
+ gsf_xml_out_end_element (xml);
}
- gsf_xml_out_end_element (xml);
+ gsf_xml_out_end_element (xml);
}
g_ptr_array_free (num_format_array, TRUE);
g_hash_table_destroy (hash);
@@ -385,7 +385,7 @@ xlsx_write_color_element (GsfXMLOut *xml, char const *id, GOColor color)
{
gsf_xml_out_start_element (xml, id);
xlsx_add_rgb (xml, "rgb", color);
- gsf_xml_out_end_element (xml);
+ gsf_xml_out_end_element (xml);
}
static gint
@@ -396,17 +396,17 @@ xlsx_find_font (GnmStyle const *style, GPtrArray *styles)
GnmStyle const *old_style = g_ptr_array_index (styles, i);
if (style == old_style)
return (gint) i;
- if (gnm_style_is_element_set (style, MSTYLE_FONT_BOLD) !=
+ if (gnm_style_is_element_set (style, MSTYLE_FONT_BOLD) !=
gnm_style_is_element_set (old_style, MSTYLE_FONT_BOLD) ||
- gnm_style_is_element_set (style, MSTYLE_FONT_ITALIC) !=
+ gnm_style_is_element_set (style, MSTYLE_FONT_ITALIC) !=
gnm_style_is_element_set (old_style, MSTYLE_FONT_ITALIC) ||
- gnm_style_is_element_set (style, MSTYLE_FONT_COLOR) !=
+ gnm_style_is_element_set (style, MSTYLE_FONT_COLOR) !=
gnm_style_is_element_set (old_style, MSTYLE_FONT_COLOR) ||
- gnm_style_is_element_set (style, MSTYLE_FONT_NAME) !=
+ gnm_style_is_element_set (style, MSTYLE_FONT_NAME) !=
gnm_style_is_element_set (old_style, MSTYLE_FONT_NAME) ||
- gnm_style_is_element_set (style, MSTYLE_FONT_SIZE) !=
+ gnm_style_is_element_set (style, MSTYLE_FONT_SIZE) !=
gnm_style_is_element_set (old_style, MSTYLE_FONT_SIZE) ||
- gnm_style_is_element_set (style, MSTYLE_FONT_STRIKETHROUGH) !=
+ gnm_style_is_element_set (style, MSTYLE_FONT_STRIKETHROUGH) !=
gnm_style_is_element_set (old_style, MSTYLE_FONT_STRIKETHROUGH))
continue;
if (gnm_style_get_font_bold (style) != gnm_style_get_font_bold (old_style) ||
@@ -416,7 +416,7 @@ xlsx_find_font (GnmStyle const *style, GPtrArray *styles)
gnm_style_get_font_size (style) != gnm_style_get_font_size (old_style) ||
gnm_style_get_font_strike (style) != gnm_style_get_font_strike (old_style))
continue;
- if (0 == strcmp (gnm_style_get_font_name (style),
+ if (0 == strcmp (gnm_style_get_font_name (style),
gnm_style_get_font_name (old_style)))
return (gint) i;
}
@@ -429,7 +429,7 @@ xlsx_write_fonts (XLSXWriteState *state, GsfXMLOut *xml)
GHashTable *fonts_hash = g_hash_table_new (g_direct_hash, g_direct_equal);
GPtrArray *styles_w_fonts = g_ptr_array_new ();
unsigned int i;
-
+
for (i = 0 ; i < state->styles_array->len ; i++) {
GnmStyle const *style = g_ptr_array_index (state->styles_array, i);
if (gnm_style_is_element_set (style, MSTYLE_FONT_BOLD) ||
@@ -441,10 +441,10 @@ xlsx_write_fonts (XLSXWriteState *state, GsfXMLOut *xml)
gint font_n = xlsx_find_font (style, styles_w_fonts);
if (font_n < 0) {
g_ptr_array_add (styles_w_fonts, (gpointer)style);
- g_hash_table_insert (fonts_hash, (gpointer)style,
+ g_hash_table_insert (fonts_hash, (gpointer)style,
GINT_TO_POINTER (styles_w_fonts->len));
} else
- g_hash_table_insert (fonts_hash, (gpointer)style,
+ g_hash_table_insert (fonts_hash, (gpointer)style,
GINT_TO_POINTER (font_n + 1));
}
}
@@ -458,41 +458,41 @@ xlsx_write_fonts (XLSXWriteState *state, GsfXMLOut *xml)
if (gnm_style_is_element_set (style, MSTYLE_FONT_BOLD)) {
gsf_xml_out_start_element (xml, "b");
xlsx_add_bool (xml, "val", gnm_style_get_font_bold (style));
- gsf_xml_out_end_element (xml);
+ gsf_xml_out_end_element (xml);
}
if (gnm_style_is_element_set (style, MSTYLE_FONT_ITALIC)) {
gsf_xml_out_start_element (xml, "i");
xlsx_add_bool (xml, "val", gnm_style_get_font_italic (style));
- gsf_xml_out_end_element (xml);
+ gsf_xml_out_end_element (xml);
}
if (gnm_style_is_element_set (style, MSTYLE_FONT_COLOR))
- xlsx_write_color_element
- (xml, "color",
+ xlsx_write_color_element
+ (xml, "color",
gnm_style_get_font_color (style)->go_color);
if (gnm_style_is_element_set (style, MSTYLE_FONT_NAME)) {
gsf_xml_out_start_element (xml, "name");
gsf_xml_out_add_cstr
(xml, "val", gnm_style_get_font_name (style));
- gsf_xml_out_end_element (xml);
+ gsf_xml_out_end_element (xml);
}
if (gnm_style_is_element_set (style, MSTYLE_FONT_SIZE)) {
gsf_xml_out_start_element (xml, "sz");
- gsf_xml_out_add_float
+ gsf_xml_out_add_float
(xml, "val", gnm_style_get_font_size (style),
2);
- gsf_xml_out_end_element (xml);
+ gsf_xml_out_end_element (xml);
}
if (gnm_style_is_element_set (style, MSTYLE_FONT_STRIKETHROUGH)) {
gsf_xml_out_start_element (xml, "strike");
xlsx_add_bool (xml, "val", gnm_style_get_font_strike (style));
- gsf_xml_out_end_element (xml);
+ gsf_xml_out_end_element (xml);
}
- gsf_xml_out_end_element (xml); /* font */
+ gsf_xml_out_end_element (xml); /* font */
}
- gsf_xml_out_end_element (xml);
+ gsf_xml_out_end_element (xml);
}
-
+
g_ptr_array_free (styles_w_fonts, TRUE);
return fonts_hash;
}
@@ -502,7 +502,7 @@ xlsx_find_fill (GnmStyle const *style, GPtrArray *styles)
{
unsigned i;
int j;
-
+
j = xlsx_find_predefined_fill (style);
if (j >= 0)
return j;
@@ -511,7 +511,7 @@ xlsx_find_fill (GnmStyle const *style, GPtrArray *styles)
if (style == old_style)
return (gint) i;
if (!(gnm_style_is_element_set (style, MSTYLE_COLOR_BACK) !=
- gnm_style_is_element_set (old_style, MSTYLE_COLOR_BACK)
+ gnm_style_is_element_set (old_style, MSTYLE_COLOR_BACK)
|| gnm_style_is_element_set (style, MSTYLE_COLOR_PATTERN) !=
gnm_style_is_element_set (old_style, MSTYLE_COLOR_PATTERN)
|| gnm_style_is_element_set (style, MSTYLE_PATTERN) !=
@@ -519,10 +519,10 @@ xlsx_find_fill (GnmStyle const *style, GPtrArray *styles)
|| (gnm_style_is_element_set (style, MSTYLE_PATTERN) &&
gnm_style_get_pattern (style) != gnm_style_get_pattern (old_style))
|| (gnm_style_is_element_set (style, MSTYLE_COLOR_BACK) &&
- gnm_style_get_back_color (style)->go_color !=
+ gnm_style_get_back_color (style)->go_color !=
gnm_style_get_back_color (old_style)->go_color)
|| (gnm_style_is_element_set (style, MSTYLE_COLOR_PATTERN) &&
- gnm_style_get_pattern_color (style)->go_color !=
+ gnm_style_get_pattern_color (style)->go_color !=
gnm_style_get_pattern_color (old_style)->go_color)))
return (gint) i + N_PREDEFINED_FILLS;
}
@@ -544,20 +544,20 @@ xlsx_write_fills (XLSXWriteState *state, GsfXMLOut *xml)
gint fill_n = xlsx_find_fill (style, styles_w_fills);
if (fill_n < 0) {
g_ptr_array_add (styles_w_fills, (gpointer)style);
- g_hash_table_insert
- (fills_hash, (gpointer)style,
- GINT_TO_POINTER (styles_w_fills->len
+ g_hash_table_insert
+ (fills_hash, (gpointer)style,
+ GINT_TO_POINTER (styles_w_fills->len
+ N_PREDEFINED_FILLS));
} else
- g_hash_table_insert
- (fills_hash, (gpointer)style,
- GINT_TO_POINTER
+ g_hash_table_insert
+ (fills_hash, (gpointer)style,
+ GINT_TO_POINTER
(fill_n + 1));
}
}
gsf_xml_out_start_element (xml, "fills");
- gsf_xml_out_add_int (xml, "count", styles_w_fills->len
+ gsf_xml_out_add_int (xml, "count", styles_w_fills->len
+ N_PREDEFINED_FILLS);
/* Excel considers the first few fills special (not according to */
/* ECMA) */
@@ -570,43 +570,43 @@ xlsx_write_fills (XLSXWriteState *state, GsfXMLOut *xml)
gint pattern = gnm_style_get_pattern (style);
switch (pattern) {
case 0:
- gsf_xml_out_add_cstr_unchecked (xml, "patternType",
+ gsf_xml_out_add_cstr_unchecked (xml, "patternType",
"none");
break;
case 1:
- gsf_xml_out_add_cstr_unchecked (xml, "patternType",
+ gsf_xml_out_add_cstr_unchecked (xml, "patternType",
"solid");
if (gnm_style_is_element_set (style, MSTYLE_COLOR_BACK)) {
- xlsx_write_color_element
- (xml, "fgColor",
+ xlsx_write_color_element
+ (xml, "fgColor",
gnm_style_get_back_color (style)->go_color);
}
break;
default:
- if (pattern < 2 || pattern > (gint)G_N_ELEMENTS (pats))
- gsf_xml_out_add_cstr_unchecked (xml, "patternType",
+ if (pattern < 2 || pattern > (gint)G_N_ELEMENTS (pats))
+ gsf_xml_out_add_cstr_unchecked (xml, "patternType",
"none");
else
- gsf_xml_out_add_cstr_unchecked (xml, "patternType",
+ gsf_xml_out_add_cstr_unchecked (xml, "patternType",
pats[pattern - 1]);
break;
}
if (pattern > 1) {
if (gnm_style_is_element_set (style, MSTYLE_COLOR_BACK))
- xlsx_write_color_element
- (xml, "fgColor",
+ xlsx_write_color_element
+ (xml, "fgColor",
gnm_style_get_back_color (style)->go_color);
if (gnm_style_is_element_set (style, MSTYLE_COLOR_PATTERN))
- xlsx_write_color_element
- (xml, "bgColor",
+ xlsx_write_color_element
+ (xml, "bgColor",
gnm_style_get_pattern_color (style)->go_color);
}
}
- gsf_xml_out_end_element (xml);
- gsf_xml_out_end_element (xml);
+ gsf_xml_out_end_element (xml);
+ gsf_xml_out_end_element (xml);
}
- gsf_xml_out_end_element (xml);
-
+ gsf_xml_out_end_element (xml);
+
g_ptr_array_free (styles_w_fills, TRUE);
return fills_hash;
}
@@ -619,17 +619,17 @@ xlsx_find_border (GnmStyle const *style, GPtrArray *styles)
GnmStyle const *old_style = g_ptr_array_index (styles, i);
if (style == old_style)
return (gint) i;
- if (gnm_style_is_element_set (style, MSTYLE_BORDER_TOP) !=
+ if (gnm_style_is_element_set (style, MSTYLE_BORDER_TOP) !=
gnm_style_is_element_set (old_style, MSTYLE_BORDER_TOP) ||
- gnm_style_is_element_set (style, MSTYLE_BORDER_BOTTOM) !=
+ gnm_style_is_element_set (style, MSTYLE_BORDER_BOTTOM) !=
gnm_style_is_element_set (old_style, MSTYLE_BORDER_BOTTOM) ||
- gnm_style_is_element_set (style, MSTYLE_BORDER_LEFT) !=
+ gnm_style_is_element_set (style, MSTYLE_BORDER_LEFT) !=
gnm_style_is_element_set (old_style, MSTYLE_BORDER_LEFT) ||
- gnm_style_is_element_set (style, MSTYLE_BORDER_RIGHT) !=
+ gnm_style_is_element_set (style, MSTYLE_BORDER_RIGHT) !=
gnm_style_is_element_set (old_style, MSTYLE_BORDER_RIGHT) ||
- gnm_style_is_element_set (style, MSTYLE_BORDER_REV_DIAGONAL) !=
+ gnm_style_is_element_set (style, MSTYLE_BORDER_REV_DIAGONAL) !=
gnm_style_is_element_set (old_style, MSTYLE_BORDER_REV_DIAGONAL) ||
- gnm_style_is_element_set (style, MSTYLE_BORDER_DIAGONAL) !=
+ gnm_style_is_element_set (style, MSTYLE_BORDER_DIAGONAL) !=
gnm_style_is_element_set (old_style, MSTYLE_BORDER_DIAGONAL))
continue;
if (gnm_style_get_border (style, MSTYLE_BORDER_TOP)
@@ -663,7 +663,7 @@ xlsx_write_border (XLSXWriteState *state, GsfXMLOut *xml, GnmBorder *border, Gnm
gsf_xml_out_start_element (xml, "bottom");
break;
case MSTYLE_BORDER_LEFT:
- gsf_xml_out_start_element
+ gsf_xml_out_start_element
(xml, (state->version == ECMA_376_2006) ? "left" : "start");
break;
case MSTYLE_BORDER_DIAGONAL:
@@ -672,7 +672,7 @@ xlsx_write_border (XLSXWriteState *state, GsfXMLOut *xml, GnmBorder *border, Gnm
break;
default:
case MSTYLE_BORDER_RIGHT:
- gsf_xml_out_start_element
+ gsf_xml_out_start_element
(xml, (state->version == ECMA_376_2006) ? "right" : "end");
break;
}
@@ -715,7 +715,7 @@ xlsx_write_border (XLSXWriteState *state, GsfXMLOut *xml, GnmBorder *border, Gnm
break;
case GNM_STYLE_BORDER_SLANTED_DASH_DOT:
gsf_xml_out_add_cstr_unchecked (xml, "style", "slantDashDot");
- break;
+ break;
default:
case GNM_STYLE_BORDER_NONE:
gsf_xml_out_add_cstr_unchecked (xml, "style", "none");
@@ -724,8 +724,8 @@ xlsx_write_border (XLSXWriteState *state, GsfXMLOut *xml, GnmBorder *border, Gnm
if (border->color != NULL)
xlsx_write_color_element (xml, "color", border->color->go_color);
-
- gsf_xml_out_end_element (xml);
+
+ gsf_xml_out_end_element (xml);
}
static GHashTable *
@@ -734,7 +734,7 @@ xlsx_write_borders (XLSXWriteState *state, GsfXMLOut *xml)
GHashTable *border_hash = g_hash_table_new (g_direct_hash, g_direct_equal);
GPtrArray *styles_w_border = g_ptr_array_new ();
unsigned int i;
-
+
for (i = 0 ; i < state->styles_array->len ; i++) {
GnmStyle const *style = g_ptr_array_index (state->styles_array, i);
if (gnm_style_is_element_set (style, MSTYLE_BORDER_TOP) ||
@@ -746,10 +746,10 @@ xlsx_write_borders (XLSXWriteState *state, GsfXMLOut *xml)
gint border_n = xlsx_find_border (style, styles_w_border);
if (border_n < 0) {
g_ptr_array_add (styles_w_border, (gpointer)style);
- g_hash_table_insert (border_hash, (gpointer)style,
+ g_hash_table_insert (border_hash, (gpointer)style,
GINT_TO_POINTER (styles_w_border->len));
} else
- g_hash_table_insert (border_hash, (gpointer)style,
+ g_hash_table_insert (border_hash, (gpointer)style,
GINT_TO_POINTER (border_n + 1));
}
}
@@ -762,41 +762,41 @@ xlsx_write_borders (XLSXWriteState *state, GsfXMLOut *xml)
gboolean diagonal_border_written = FALSE;
gsf_xml_out_start_element (xml, "border");
if (gnm_style_is_element_set (style, MSTYLE_BORDER_DIAGONAL)) {
- GnmBorder *border = gnm_style_get_border
+ GnmBorder *border = gnm_style_get_border
(style, MSTYLE_BORDER_DIAGONAL);
- gsf_xml_out_add_bool
+ gsf_xml_out_add_bool
(xml, "diagonalUp",
(border->line_type != GNM_STYLE_BORDER_NONE));
}
if (gnm_style_is_element_set (style, MSTYLE_BORDER_REV_DIAGONAL)) {
- GnmBorder *border = gnm_style_get_border
+ GnmBorder *border = gnm_style_get_border
(style, MSTYLE_BORDER_REV_DIAGONAL);
- gsf_xml_out_add_bool
+ gsf_xml_out_add_bool
(xml, "diagonalDown",
(border->line_type != GNM_STYLE_BORDER_NONE));
}
if (gnm_style_is_element_set (style, MSTYLE_BORDER_LEFT))
xlsx_write_border (state, xml,
- gnm_style_get_border
+ gnm_style_get_border
(style, MSTYLE_BORDER_LEFT),
MSTYLE_BORDER_LEFT);
if (gnm_style_is_element_set (style, MSTYLE_BORDER_RIGHT))
xlsx_write_border (state, xml,
- gnm_style_get_border
+ gnm_style_get_border
(style, MSTYLE_BORDER_RIGHT),
MSTYLE_BORDER_RIGHT);
if (gnm_style_is_element_set (style, MSTYLE_BORDER_TOP))
- xlsx_write_border (state, xml,
- gnm_style_get_border
- (style, MSTYLE_BORDER_TOP),
+ xlsx_write_border (state, xml,
+ gnm_style_get_border
+ (style, MSTYLE_BORDER_TOP),
MSTYLE_BORDER_TOP);
if (gnm_style_is_element_set (style, MSTYLE_BORDER_BOTTOM))
xlsx_write_border (state, xml,
- gnm_style_get_border
+ gnm_style_get_border
(style, MSTYLE_BORDER_BOTTOM),
MSTYLE_BORDER_BOTTOM);
if (gnm_style_is_element_set (style, MSTYLE_BORDER_DIAGONAL)) {
- GnmBorder *border = gnm_style_get_border
+ GnmBorder *border = gnm_style_get_border
(style, MSTYLE_BORDER_DIAGONAL);
if (border->line_type != GNM_STYLE_BORDER_NONE) {
diagonal_border_written = TRUE;
@@ -805,9 +805,9 @@ xlsx_write_borders (XLSXWriteState *state, GsfXMLOut *xml)
MSTYLE_BORDER_DIAGONAL);
}
}
- if (!diagonal_border_written &&
+ if (!diagonal_border_written &&
gnm_style_is_element_set (style, MSTYLE_BORDER_REV_DIAGONAL)) {
- GnmBorder *border = gnm_style_get_border
+ GnmBorder *border = gnm_style_get_border
(style, MSTYLE_BORDER_REV_DIAGONAL);
if (border->line_type != GNM_STYLE_BORDER_NONE) {
xlsx_write_border (state, xml,
@@ -816,10 +816,10 @@ xlsx_write_borders (XLSXWriteState *state, GsfXMLOut *xml)
}
}
gsf_xml_out_end_element (xml); /* border */
- }
- gsf_xml_out_end_element (xml);
+ }
+ gsf_xml_out_end_element (xml);
}
-
+
g_ptr_array_free (styles_w_border, TRUE);
return border_hash;
}
@@ -836,43 +836,43 @@ xlsx_write_style_want_alignment (GnmStyle const *style)
}
static void
-xlsx_write_style_write_alignment (XLSXWriteState *state, GsfXMLOut *xml,
+xlsx_write_style_write_alignment (XLSXWriteState *state, GsfXMLOut *xml,
GnmStyle const *style)
{
gsf_xml_out_start_element (xml, "alignment");
if (gnm_style_is_element_set (style, MSTYLE_ALIGN_H)) {
switch (gnm_style_get_align_h (style)) {
case HALIGN_LEFT:
- gsf_xml_out_add_cstr_unchecked (xml, "horizontal",
+ gsf_xml_out_add_cstr_unchecked (xml, "horizontal",
"left");
break;
case HALIGN_RIGHT:
- gsf_xml_out_add_cstr_unchecked (xml, "horizontal",
+ gsf_xml_out_add_cstr_unchecked (xml, "horizontal",
"right");
break;
case HALIGN_CENTER:
- gsf_xml_out_add_cstr_unchecked (xml, "horizontal",
+ gsf_xml_out_add_cstr_unchecked (xml, "horizontal",
"center");
break;
case HALIGN_FILL:
- gsf_xml_out_add_cstr_unchecked (xml, "horizontal",
+ gsf_xml_out_add_cstr_unchecked (xml, "horizontal",
"fill");
break;
case HALIGN_JUSTIFY:
- gsf_xml_out_add_cstr_unchecked (xml, "horizontal",
+ gsf_xml_out_add_cstr_unchecked (xml, "horizontal",
"justify");
break;
case HALIGN_CENTER_ACROSS_SELECTION:
- gsf_xml_out_add_cstr_unchecked (xml, "horizontal",
+ gsf_xml_out_add_cstr_unchecked (xml, "horizontal",
"centerContinuous");
break;
case HALIGN_DISTRIBUTED:
- gsf_xml_out_add_cstr_unchecked (xml, "horizontal",
+ gsf_xml_out_add_cstr_unchecked (xml, "horizontal",
"distributed");
break;
case HALIGN_GENERAL:
default:
- gsf_xml_out_add_cstr_unchecked (xml, "horizontal",
+ gsf_xml_out_add_cstr_unchecked (xml, "horizontal",
"general");
break;
}
@@ -880,27 +880,27 @@ xlsx_write_style_write_alignment (XLSXWriteState *state, GsfXMLOut *xml,
if (gnm_style_is_element_set (style, MSTYLE_ALIGN_V)) {
switch (gnm_style_get_align_v (style)) {
case VALIGN_TOP:
- gsf_xml_out_add_cstr_unchecked (xml, "vertical",
+ gsf_xml_out_add_cstr_unchecked (xml, "vertical",
"top");
break;
case VALIGN_BOTTOM:
- gsf_xml_out_add_cstr_unchecked (xml, "vertical",
+ gsf_xml_out_add_cstr_unchecked (xml, "vertical",
"bottom");
break;
case VALIGN_CENTER:
- gsf_xml_out_add_cstr_unchecked (xml, "vertical",
+ gsf_xml_out_add_cstr_unchecked (xml, "vertical",
"center");
break;
case VALIGN_JUSTIFY:
- gsf_xml_out_add_cstr_unchecked (xml, "vertical",
+ gsf_xml_out_add_cstr_unchecked (xml, "vertical",
"justify");
break;
default:
case VALIGN_DISTRIBUTED:
- gsf_xml_out_add_cstr_unchecked (xml, "vertical",
+ gsf_xml_out_add_cstr_unchecked (xml, "vertical",
"distributed");
break;
- }
+ }
}
if (gnm_style_is_element_set (style, MSTYLE_WRAP_TEXT)) {
gsf_xml_out_add_bool (xml, "wrapText", gnm_style_get_wrap_text (style));
@@ -914,11 +914,11 @@ xlsx_write_style_write_alignment (XLSXWriteState *state, GsfXMLOut *xml,
if (gnm_style_is_element_set (style, MSTYLE_INDENT)) {
gsf_xml_out_add_int (xml, "indent", gnm_style_get_indent (style));
}
- gsf_xml_out_end_element (xml);
+ gsf_xml_out_end_element (xml);
}
static void
-xlsx_write_style (XLSXWriteState *state, GsfXMLOut *xml,
+xlsx_write_style (XLSXWriteState *state, GsfXMLOut *xml,
GnmStyle const *style, GHashTable *fills_hash,
GHashTable *num_format_hash, GHashTable *fonts_hash,
GHashTable *border_hash, gint id)
@@ -944,27 +944,27 @@ xlsx_write_style (XLSXWriteState *state, GsfXMLOut *xml,
if (border)
gsf_xml_out_add_int (xml, "borderId", GPOINTER_TO_INT (tmp_border) - 1);
if (num_fmt)
- gsf_xml_out_add_int
- (xml, "numFmtId",
+ gsf_xml_out_add_int
+ (xml, "numFmtId",
GPOINTER_TO_INT (g_hash_table_lookup (num_format_hash, style)));
if (id >= 0)
gsf_xml_out_add_int (xml, "xfId", id);
if (alignment)
xlsx_write_style_write_alignment (state, xml, style);
-
+
}
static void
-xlsx_write_cellStyleXfs (XLSXWriteState *state, GsfXMLOut *xml,
+xlsx_write_cellStyleXfs (XLSXWriteState *state, GsfXMLOut *xml,
GHashTable *fills_hash, GHashTable *num_format_hash,
GHashTable *fonts_hash, GHashTable *border_hash)
{
gsf_xml_out_start_element (xml, "cellStyleXfs");
gsf_xml_out_add_int (xml, "count", 1);
gsf_xml_out_start_element (xml, "xf");
- xlsx_write_style
- (state, xml,
+ xlsx_write_style
+ (state, xml,
g_ptr_array_index (state->styles_array, 0),
fills_hash, num_format_hash, fonts_hash,
border_hash, -1);
@@ -973,7 +973,7 @@ xlsx_write_cellStyleXfs (XLSXWriteState *state, GsfXMLOut *xml,
}
static void
-xlsx_write_cellXfs (XLSXWriteState *state, GsfXMLOut *xml,
+xlsx_write_cellXfs (XLSXWriteState *state, GsfXMLOut *xml,
GHashTable *fills_hash, GHashTable *num_format_hash,
GHashTable *fonts_hash, GHashTable *border_hash)
{
@@ -983,15 +983,15 @@ xlsx_write_cellXfs (XLSXWriteState *state, GsfXMLOut *xml,
gsf_xml_out_add_int (xml, "count", state->styles_array->len);
for (i = 0 ; i < state->styles_array->len ; i++) {
gsf_xml_out_start_element (xml, "xf");
- xlsx_write_style
- (state, xml,
+ xlsx_write_style
+ (state, xml,
g_ptr_array_index (state->styles_array, i),
fills_hash, num_format_hash, fonts_hash,
border_hash, 0);
- gsf_xml_out_end_element (xml);
+ gsf_xml_out_end_element (xml);
}
gsf_xml_out_end_element (xml);
- }
+ }
}
static void
@@ -1020,7 +1020,7 @@ xlsx_write_styles (XLSXWriteState *state, GsfOutfile *wb_part)
/* <xsd:element name="tableStyles" type="CT_TableStyles" minOccurs="0" maxOccurs="1"/> */
/* <xsd:element name="colors" type="CT_Colors" minOccurs="0" maxOccurs="1"/> */
/* <xsd:element name="extLst" type="CT_ExtensionList" minOccurs="0" maxOccurs="1"/> */
-
+
g_hash_table_destroy (fills_hash);
g_hash_table_destroy (fonts_hash);
g_hash_table_destroy (num_format_hash);
@@ -1203,7 +1203,7 @@ xlsx_write_cells (XLSXWriteState *state, GsfXMLOut *xml, GnmRange const *extent)
GnmStyle const *style = sheet_style_get (state->sheet, c, r);
gint style_id = (style != NULL) ?
style_id = xlsx_get_style_id (state, style) : -1;
-
+
if (NULL != (cell = sheet_cell_get (state->sheet, c, r))) {
xlsx_write_init_row (&needs_row, xml, r, cheesy_span);
val = cell->value;
@@ -2067,14 +2067,14 @@ xlsx_write_named_expression (gpointer key, GnmNamedExpr *nexpr, XLSXClosure *clo
gsf_xml_out_add_cstr (closure->xml, "name", expr_name_name (nexpr));
}
if (nexpr->pos.sheet != NULL)
- gsf_xml_out_add_int (closure->xml, "localSheetId",
+ gsf_xml_out_add_int (closure->xml, "localSheetId",
nexpr->pos.sheet->index_in_wb);
formula = expr_name_as_string (nexpr, NULL, closure->state->convs);
gsf_xml_out_add_cstr (closure->xml, NULL, formula);
g_free (formula);
-
- gsf_xml_out_end_element (closure->xml);
+
+ gsf_xml_out_end_element (closure->xml);
}
static void
diff --git a/plugins/fn-tsa/functions.c b/plugins/fn-tsa/functions.c
index e571c12..6d841f0 100644
--- a/plugins/fn-tsa/functions.c
+++ b/plugins/fn-tsa/functions.c
@@ -426,7 +426,7 @@ gnumeric_interpolation (GnmFuncEvalInfo *ei, GnmValue const * const *argv)
g_free (vals2);
return value_new_error_std (ei->pos, GNM_ERROR_VALUE);
}
-
+
/* argv[3] */
if (argv[3]) {
@@ -464,9 +464,9 @@ gnumeric_interpolation (GnmFuncEvalInfo *ei, GnmValue const * const *argv)
}
/* argv[0] & argv[1] */
-
+
flags = COLLECT_IGNORE_BLANKS | COLLECT_IGNORE_STRINGS | COLLECT_IGNORE_BOOLS;
- error = collect_float_pairs (argv[0], argv[1], ei->pos, flags, &vals0, &vals1,
+ error = collect_float_pairs (argv[0], argv[1], ei->pos, flags, &vals0, &vals1,
&n0, &constp);
if (error) {
diff --git a/plugins/lotus-123/lotus-formula.c b/plugins/lotus-123/lotus-formula.c
index 0964e3f..0bd464a 100644
--- a/plugins/lotus-123/lotus-formula.c
+++ b/plugins/lotus-123/lotus-formula.c
@@ -509,7 +509,7 @@ make_function (LotusState *state, GnmExprList **stack, guint8 const *data, const
f = works_ordinal_to_info[*data];
} else {
if (*data <= LOTUS_MAX_ORDINAL)
- f = lotus_ordinal_to_info[*data];
+ f = lotus_ordinal_to_info[*data];
}
if (f == NULL) {
@@ -861,7 +861,7 @@ lotus_parse_formula_new (LotusState *state, GnmParsePos *orig,
if (!g_ascii_isalnum (p[-1]))
break;
- f = g_hash_table_lookup ((state->is_works) ?
+ f = g_hash_table_lookup ((state->is_works) ?
works_funcname_to_info
: lotus_funcname_to_info, p);
handle_named_func (&stack, orig,
diff --git a/plugins/lotus-123/lotus.c b/plugins/lotus-123/lotus.c
index 8963b52..fb5d58c 100644
--- a/plugins/lotus-123/lotus.c
+++ b/plugins/lotus-123/lotus.c
@@ -2462,8 +2462,8 @@ cell_set_fmt (LotusState *state, GnmCell *cell, int fmt)
range.start = cell->pos;
range.end = range.start;
-
- style = g_hash_table_lookup (state->style_pool,
+
+ style = g_hash_table_lookup (state->style_pool,
GINT_TO_POINTER (fmt));
if (style) {
@@ -2795,7 +2795,7 @@ lotus_read_works (LotusState *state, record_t *r)
memcpy(font->typeface, r->data + 2, l);
font->typeface[l] = 0;
font->size = r->data[36];
-
+
codepage = gnm_font_override_codepage (font->typeface);
if (codepage != -1)
font->converter = gsf_msole_iconv_open_for_import (codepage);
diff --git a/plugins/openoffice/openoffice-read.c b/plugins/openoffice/openoffice-read.c
index bc4b7b5..432f450 100644
--- a/plugins/openoffice/openoffice-read.c
+++ b/plugins/openoffice/openoffice-read.c
@@ -367,7 +367,7 @@ typedef struct {
struct {
GnmPageBreaks *h, *v;
} page_breaks;
-
+
PrintInformation *cur_pi;
PrintHF *cur_hf;
char **cur_hf_format;
@@ -1182,7 +1182,7 @@ two_quotes :
tmp = col_parse (ptr, &ss_max, &ref->col, &ref->col_relative);
if (!tmp && !oo_cellref_check_for_err (ref, &ptr))
return start;
- if (tmp)
+ if (tmp)
ptr = tmp;
tmp = row_parse (ptr, &ss_max, &ref->row, &ref->row_relative);
if (!tmp && !oo_cellref_check_for_err (ref, &ptr))
@@ -1194,7 +1194,7 @@ two_quotes :
g_free (new_sheet_name);
return ptr;
}
-
+
if (new_sheet_name != NULL) {
Sheet *old_sheet = workbook_sheet_by_index (pp->wb, 0);
ref->sheet = sheet_new (pp->wb, new_sheet_name,
@@ -1263,10 +1263,10 @@ oo_rangeref_parse (GnmRangeRef *ref, char const *start, GnmParsePos const *pp,
ptr = odf_parse_external (start, &external, convs);
- ptr = oo_cellref_parse (&ref->a, ptr, pp,
+ ptr = oo_cellref_parse (&ref->a, ptr, pp,
external == NULL ? NULL : &external_sheet_1);
if (*ptr == ':')
- ptr = oo_cellref_parse (&ref->b, ptr+1, pp,
+ ptr = oo_cellref_parse (&ref->b, ptr+1, pp,
external == NULL ? NULL : &external_sheet_2);
else
ref->b = ref->a;
@@ -1279,22 +1279,22 @@ oo_rangeref_parse (GnmRangeRef *ref, char const *start, GnmParsePos const *pp,
ext_wb = (*convs->input.external_wb) (convs, ref_wb, external);
if (ext_wb == NULL) {
if (oconv != NULL)
- oo_warning (oconv->xin,
+ oo_warning (oconv->xin,
_("Ignoring reference to unknown "
- "external workbook '%s'"),
+ "external workbook '%s'"),
external);
ref->a.sheet = invalid_sheet;
} else {
if (external_sheet_1 != NULL)
- ref->a.sheet = workbook_sheet_by_name
+ ref->a.sheet = workbook_sheet_by_name
(ext_wb, external_sheet_1);
- else
+ else
ref->a.sheet = workbook_sheet_by_index
(ext_wb, 0);
if (external_sheet_2 != NULL)
- ref->b.sheet = workbook_sheet_by_name
+ ref->b.sheet = workbook_sheet_by_name
(ext_wb, external_sheet_1);
- else
+ else
ref->b.sheet = NULL;
}
g_free (external);
@@ -1350,7 +1350,7 @@ odf_strunescape (char const *string, GString *target,
error:
g_string_truncate (target, oldlen);
- return NULL;
+ return NULL;
}
static void
@@ -1372,7 +1372,7 @@ static odf_fix_expr_names_t *
odf_fix_expr_names_t_new (OOParseState *state)
{
odf_fix_expr_names_t *fen = g_new (odf_fix_expr_names_t, 1);
-
+
fen->fixed2orig = g_hash_table_new (g_str_hash, g_str_equal);
fen->orig2fixed = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, g_free);
fen->state = state;
@@ -1416,7 +1416,7 @@ odf_fix_en_validate (char const *name, odf_fix_expr_names_t *fen)
return TRUE;
}
-static void
+static void
odf_fix_en_collect (gchar const *key, G_GNUC_UNUSED GnmNamedExpr *nexpr, odf_fix_expr_names_t *fen)
{
GString *str;
@@ -1434,7 +1434,7 @@ odf_fix_en_collect (gchar const *key, G_GNUC_UNUSED GnmNamedExpr *nexpr, odf_fix
odf_fix_expr_names_t_add (fen, key, g_string_free (str, FALSE));
}
-static void
+static void
odf_fix_en_apply (const char *orig, GnmNamedExpr *nexpr, GHashTable *orig2fixed)
{
const char *fixed = g_hash_table_lookup (orig2fixed, orig);
@@ -1467,9 +1467,9 @@ odf_fix_expr_names (OOParseState *state)
* @name: tentative name
*
* returns TRUE if the given name is valid, FALSE otherwise.
- *
- * We are accepting names here that contain periods or look like addresses.
- * They need to be replaced when we have finished parsing the file since
+ *
+ * We are accepting names here that contain periods or look like addresses.
+ * They need to be replaced when we have finished parsing the file since
* they are not allowed inside Gnumeric.
*/
static gboolean
@@ -1513,7 +1513,7 @@ oo_func_map_in (GnmConventions const *convs, Workbook *scope,
static GnmConventions *
oo_conventions_new (OOParseState *state, GsfXMLIn *xin)
{
- GnmConventions *conv = gnm_conventions_new_full
+ GnmConventions *conv = gnm_conventions_new_full
(sizeof (ODFConventions));
ODFConventions *oconv = (ODFConventions *)conv;
conv->decode_ampersands = TRUE;
@@ -1591,7 +1591,7 @@ oo_expr_parse_str (GsfXMLIn *xin, char const *str,
/* There are faulty expressions in the wild that */
/* are references w/o [] */
char *test = g_strdup_printf ("[%s]", str);
- texpr = oo_expr_parse_str_try (xin, test, pp,
+ texpr = oo_expr_parse_str_try (xin, test, pp,
flags, type, NULL);
g_free (test);
}
@@ -1604,12 +1604,12 @@ oo_expr_parse_str (GsfXMLIn *xin, char const *str,
}
static GnmExprTop const *
-odf_parse_range_address_or_expr (GsfXMLIn *xin, char const *str)
+odf_parse_range_address_or_expr (GsfXMLIn *xin, char const *str)
{
OOParseState *state = (OOParseState *)xin->user_state;
GnmExprTop const *texpr = NULL;
OOFormula f_type = odf_get_formula_type (xin, &str);
-
+
if (f_type != FORMULA_NOT_SUPPORTED) {
GnmParsePos pp;
GnmRangeRef ref;
@@ -1617,7 +1617,7 @@ odf_parse_range_address_or_expr (GsfXMLIn *xin, char const *str)
(&ref, str,
parse_pos_init_sheet (&pp, state->pos.sheet),
NULL);
- if (ptr == str
+ if (ptr == str
|| ref.a.sheet == invalid_sheet)
texpr = oo_expr_parse_str (xin, str,
&state->pos,
@@ -1684,10 +1684,10 @@ odf_pi_parse_format_spec (GsfXMLIn *xin, char **fmt, char const *needle, char co
if (formula == NULL)
goto stop_parse;
-
+
f_type = odf_get_formula_type (xin, &formula);
if (f_type == FORMULA_NOT_SUPPORTED) {
- oo_warning (xin, _("Unsupported formula type encountered: %s"),
+ oo_warning (xin, _("Unsupported formula type encountered: %s"),
orig_formula);
goto stop_parse;
}
@@ -1701,7 +1701,7 @@ odf_pi_parse_format_spec (GsfXMLIn *xin, char **fmt, char const *needle, char co
(xin, formula, &state->pos, GNM_EXPR_PARSE_DEFAULT, f_type);
if (texpr != NULL) {
- text = gnm_expr_top_as_string (texpr, &state->pos,
+ text = gnm_expr_top_as_string (texpr, &state->pos,
gnm_conventions_default);
gnm_expr_top_unref (texpr);
@@ -1714,7 +1714,7 @@ odf_pi_parse_format_spec (GsfXMLIn *xin, char **fmt, char const *needle, char co
g_string_insert (str, start_pos, subs);
start = start_pos + strlen (subs);
g_free (subs);
- }
+ }
} else
break;
}
@@ -1835,12 +1835,12 @@ oo_table_start (GsfXMLIn *xin, xmlChar const **attrs)
if (style) {
PrintInformation *pi = NULL;
if (style->master_page_name)
- pi = g_hash_table_lookup (state->styles.master_pages,
+ pi = g_hash_table_lookup (state->styles.master_pages,
style->master_page_name);
if (pi != NULL) {
print_info_free (state->pos.sheet->print_info);
state->pos.sheet->print_info = print_info_dup (pi);
- odf_pi_parse_expressions (xin, state->pos.sheet->print_info);
+ odf_pi_parse_expressions (xin, state->pos.sheet->print_info);
}
g_object_set (state->pos.sheet,
"visibility", style->visibility,
@@ -1867,7 +1867,7 @@ oo_table_start (GsfXMLIn *xin, xmlChar const **attrs)
NULL);
style_color_unref (color);
}
-
+
}
g_free (style_name);
}
@@ -1968,8 +1968,8 @@ odf_validation_new_list (GsfXMLIn *xin, odf_validation_t *val, guint offset)
}
static GnmValidation *
-odf_validation_new_single_expr (GsfXMLIn *xin, odf_validation_t *val,
- char const *start, ValidationType val_type,
+odf_validation_new_single_expr (GsfXMLIn *xin, odf_validation_t *val,
+ char const *start, ValidationType val_type,
ValidationOp val_op)
{
OOParseState *state = (OOParseState *)xin->user_state;
@@ -2012,8 +2012,8 @@ odf_validation_new_single_expr (GsfXMLIn *xin, odf_validation_t *val,
}
static GnmValidation *
-odf_validation_new_pair_expr (GsfXMLIn *xin, odf_validation_t *val,
- char const *start, ValidationType val_type,
+odf_validation_new_pair_expr (GsfXMLIn *xin, odf_validation_t *val,
+ char const *start, ValidationType val_type,
ValidationOp val_op)
{
OOParseState *state = (OOParseState *)xin->user_state;
@@ -2051,10 +2051,10 @@ odf_validation_new_pair_expr (GsfXMLIn *xin, odf_validation_t *val,
while (1) {
gchar * try = g_strrstr_len (pair, len, ",");
GnmExprTop const *texpr;
-
- if (try == NULL || try == pair)
+
+ if (try == NULL || try == pair)
goto pair_error;
-
+
texpr = oo_expr_parse_str
(xin, try + 1, &pp,
GNM_EXPR_PARSE_FORCE_EXPLICIT_SHEET_REFERENCES,
@@ -2125,8 +2125,8 @@ odf_validation_new_op (GsfXMLIn *xin, odf_validation_t *val, guint offset, Valid
} else if (g_str_has_prefix (start, "<")) {
val_op = VALIDATION_OP_LT;
start += 1;
- }
-
+ }
+
if (val_op == VALIDATION_OP_NONE)
return NULL;
@@ -2146,36 +2146,36 @@ odf_validations_analyze (GsfXMLIn *xin, odf_validation_t *val, guint offset, Val
str++;
if (g_str_has_prefix (str, "cell-content-is-in-list"))
- return odf_validation_new_list
+ return odf_validation_new_list
(xin, val, str - val->condition + strlen ("cell-content-is-in-list"));
else if (g_str_has_prefix (str, "cell-content-text-length()"))
return odf_validation_new_op
- (xin, val, str - val->condition + strlen ("cell-content-text-length()"),
+ (xin, val, str - val->condition + strlen ("cell-content-text-length()"),
VALIDATION_TYPE_TEXT_LENGTH);
else if (g_str_has_prefix (str, "cell-content-text-length-is-between"))
return odf_validation_new_between
- (xin, val, str - val->condition + strlen ("cell-content-text-length-is-between"),
+ (xin, val, str - val->condition + strlen ("cell-content-text-length-is-between"),
VALIDATION_TYPE_TEXT_LENGTH, TRUE);
else if (g_str_has_prefix (str, "cell-content-text-length-is-not-between"))
return odf_validation_new_between
- (xin, val, str - val->condition + strlen ("cell-content-text-length-is-not-between"),
+ (xin, val, str - val->condition + strlen ("cell-content-text-length-is-not-between"),
VALIDATION_TYPE_TEXT_LENGTH, FALSE);
else if (g_str_has_prefix (str, "cell-content-is-decimal-number() and"))
- return odf_validations_analyze
- (xin, val, str - val->condition + strlen ("cell-content-is-decimal-number() and"),
+ return odf_validations_analyze
+ (xin, val, str - val->condition + strlen ("cell-content-is-decimal-number() and"),
VALIDATION_TYPE_AS_NUMBER);
else if (g_str_has_prefix (str, "cell-content-is-whole-number() and"))
- return odf_validations_analyze
- (xin, val, str - val->condition + strlen ("cell-content-is-whole-number() and"),
+ return odf_validations_analyze
+ (xin, val, str - val->condition + strlen ("cell-content-is-whole-number() and"),
VALIDATION_TYPE_AS_INT);
else if (g_str_has_prefix (str, "cell-content-is-date() and"))
- return odf_validations_analyze
- (xin, val, str - val->condition + strlen ("cell-content-is-date() and"),
- VALIDATION_TYPE_AS_DATE);
+ return odf_validations_analyze
+ (xin, val, str - val->condition + strlen ("cell-content-is-date() and"),
+ VALIDATION_TYPE_AS_DATE);
else if (g_str_has_prefix (str, "cell-content-is-time() and"))
- return odf_validations_analyze
- (xin, val, str - val->condition + strlen ("cell-content-is-time() and"),
- VALIDATION_TYPE_AS_TIME);
+ return odf_validations_analyze
+ (xin, val, str - val->condition + strlen ("cell-content-is-time() and"),
+ VALIDATION_TYPE_AS_TIME);
else if (g_str_has_prefix (str, "is-true-formula")) {
if (vtype != VALIDATION_TYPE_ANY) {
oo_warning
@@ -2184,19 +2184,19 @@ odf_validations_analyze (GsfXMLIn *xin, odf_validation_t *val, guint offset, Val
val->condition, str);
}
return odf_validation_new_single_expr
- (xin, val, str + strlen ("is-true-formula"), VALIDATION_TYPE_CUSTOM,
+ (xin, val, str + strlen ("is-true-formula"), VALIDATION_TYPE_CUSTOM,
VALIDATION_OP_NONE);
} else if (g_str_has_prefix (str, "cell-content()"))
return odf_validation_new_op
- (xin, val, str - val->condition + strlen ("cell-content()"),
+ (xin, val, str - val->condition + strlen ("cell-content()"),
vtype);
else if (g_str_has_prefix (str, "cell-content-is-between"))
return odf_validation_new_between
- (xin, val, str - val->condition + strlen ("cell-content-is-between"),
+ (xin, val, str - val->condition + strlen ("cell-content-is-between"),
vtype, TRUE);
else if (g_str_has_prefix (str, "cell-content-is-not-between"))
return odf_validation_new_between
- (xin, val, str - val->condition + strlen ("cell-content-is-not-between"),
+ (xin, val, str - val->condition + strlen ("cell-content-is-not-between"),
vtype, FALSE);
return NULL;
@@ -2217,7 +2217,7 @@ odf_validations_translate (GsfXMLIn *xin, char const *name)
}
if (val->condition != NULL && val->f_type != FORMULA_NOT_SUPPORTED) {
- GnmValidation *validation = odf_validations_analyze
+ GnmValidation *validation = odf_validations_analyze
(xin, val, 0, VALIDATION_TYPE_ANY);
if (validation != NULL) {
GError *err;
@@ -2326,16 +2326,16 @@ oo_table_end (GsfXMLIn *xin, G_GNUC_UNUSED GsfXMLBlob *blob)
if (state->print.rep_rows_to < 0)
state->print.rep_rows_to = max_rows - 1;
g_free (state->pos.sheet->print_info->repeat_top);
- state->pos.sheet->print_info->repeat_top
- = g_strdup (rows_name (state->print.rep_rows_from,
+ state->pos.sheet->print_info->repeat_top
+ = g_strdup (rows_name (state->print.rep_rows_from,
state->print.rep_rows_to));
}
if (state->print.rep_cols_from >= 0) {
if (state->print.rep_cols_to < 0)
state->print.rep_cols_to = max_cols - 1;
g_free (state->pos.sheet->print_info->repeat_left);
- state->pos.sheet->print_info->repeat_left
- = g_strdup (cols_name (state->print.rep_cols_from,
+ state->pos.sheet->print_info->repeat_left
+ = g_strdup (cols_name (state->print.rep_cols_from,
state->print.rep_cols_to));
}
@@ -2733,7 +2733,7 @@ oo_cell_start (GsfXMLIn *xin, xmlChar const **attrs)
state->col_inc = 1;
state->content_is_error = FALSE;
for (; attrs != NULL && attrs[0] && attrs[1] ; attrs += 2) {
- if (oo_attr_int_range (xin, attrs, OO_NS_TABLE, "number-columns-repeated",
+ if (oo_attr_int_range (xin, attrs, OO_NS_TABLE, "number-columns-repeated",
&state->col_inc, 0, INT_MAX))
;
else if (gsf_xml_in_namecmp (xin, CXML2C (attrs[0]), OO_NS_TABLE, "formula")) {
@@ -2747,8 +2747,8 @@ oo_cell_start (GsfXMLIn *xin, xmlChar const **attrs)
expr_string = CXML2C (attrs[1]);
f_type = odf_get_formula_type (xin, &expr_string);
if (f_type == FORMULA_NOT_SUPPORTED) {
- oo_warning (xin,
- _("Unsupported formula type encountered: %s"),
+ oo_warning (xin,
+ _("Unsupported formula type encountered: %s"),
expr_string);
continue;
}
@@ -2764,11 +2764,11 @@ oo_cell_start (GsfXMLIn *xin, xmlChar const **attrs)
*/
state->content_is_error = TRUE;
else
- texpr = oo_expr_parse_str
+ texpr = oo_expr_parse_str
(xin, expr_string,
&state->pos, GNM_EXPR_PARSE_DEFAULT, f_type);
} else if (oo_attr_bool (xin, attrs,
- (state->ver == OOO_VER_OPENDOC) ?
+ (state->ver == OOO_VER_OPENDOC) ?
OO_NS_OFFICE : OO_NS_TABLE,
"boolean-value", &bool_val))
val = value_new_bool (bool_val);
@@ -2787,8 +2787,8 @@ oo_cell_start (GsfXMLIn *xin, xmlChar const **attrs)
unsigned d_serial = go_date_g_to_serial (&date,
workbook_date_conv (state->pos.wb));
if (n >= 6) {
- double time_frac
- = h + ((double)mi / 60.) +
+ double time_frac
+ = h + ((double)mi / 60.) +
((double)s / 3600.);
val = value_new_float (d_serial + time_frac / 24.);
has_datetime = TRUE;
@@ -2799,7 +2799,7 @@ oo_cell_start (GsfXMLIn *xin, xmlChar const **attrs)
}
}
} else if (gsf_xml_in_namecmp (xin, CXML2C (attrs[0]),
- (state->ver == OOO_VER_OPENDOC) ?
+ (state->ver == OOO_VER_OPENDOC) ?
OO_NS_OFFICE : OO_NS_TABLE,
"time-value")) {
unsigned h, m, s;
@@ -2809,7 +2809,7 @@ oo_cell_start (GsfXMLIn *xin, xmlChar const **attrs)
has_time = TRUE;
}
} else if (gsf_xml_in_namecmp (xin, CXML2C (attrs[0]),
- (state->ver == OOO_VER_OPENDOC) ?
+ (state->ver == OOO_VER_OPENDOC) ?
OO_NS_OFFICE : OO_NS_TABLE,
"string-value"))
val = value_new_string (CXML2C (attrs[1]));
@@ -2817,23 +2817,23 @@ oo_cell_start (GsfXMLIn *xin, xmlChar const **attrs)
(state->ver == OOO_VER_OPENDOC) ? OO_NS_OFFICE : OO_NS_TABLE,
"value", &float_val))
val = value_new_float (float_val);
- else if (oo_attr_int_range (xin, attrs, OO_NS_TABLE,
- "number-matrix-columns-spanned",
+ else if (oo_attr_int_range (xin, attrs, OO_NS_TABLE,
+ "number-matrix-columns-spanned",
&array_cols, 0, INT_MAX))
;
- else if (oo_attr_int_range (xin, attrs, OO_NS_TABLE,
- "number-matrix-rows-spanned",
+ else if (oo_attr_int_range (xin, attrs, OO_NS_TABLE,
+ "number-matrix-rows-spanned",
&array_rows, 0, INT_MAX))
;
- else if (oo_attr_int_range (xin, attrs, OO_NS_TABLE,
+ else if (oo_attr_int_range (xin, attrs, OO_NS_TABLE,
"number-columns-spanned", &merge_cols, 0, INT_MAX))
;
- else if (oo_attr_int_range (xin, attrs, OO_NS_TABLE,
+ else if (oo_attr_int_range (xin, attrs, OO_NS_TABLE,
"number-rows-spanned", &merge_rows, 0, INT_MAX))
;
else if (gsf_xml_in_namecmp (xin, CXML2C (attrs[0]), OO_NS_TABLE, "style-name"))
style_name = attrs[1];
- else if (gsf_xml_in_namecmp (xin, CXML2C (attrs[0]), OO_NS_TABLE,
+ else if (gsf_xml_in_namecmp (xin, CXML2C (attrs[0]), OO_NS_TABLE,
"content-validation-name"))
validation_name = attrs[1];
}
@@ -2868,7 +2868,7 @@ oo_cell_start (GsfXMLIn *xin, xmlChar const **attrs)
((!gnm_style_is_element_set (style, MSTYLE_FORMAT))
|| go_format_is_general (gnm_style_get_format (style)))) {
GOFormat *format;
- style = (style == NULL) ? gnm_style_new () :
+ style = (style == NULL) ? gnm_style_new () :
gnm_style_dup (style);
gnm_style_ref (style);
/* Now we have 2 references for style */
@@ -2884,17 +2884,17 @@ oo_cell_start (GsfXMLIn *xin, xmlChar const **attrs)
format = go_format_default_time ();
g_hash_table_replace (state->styles.cell_time,
g_strdup (style_name), style);
- }
+ }
gnm_style_set_format (style, format);
/* Since (has_datetime || has_date || has_time) we now */
/* have 1 references for style */
- } else
+ } else
gnm_style_ref (style);
/* 1 reference for style*/
} else if (style != NULL)
gnm_style_ref (style);
/* 1 reference for style*/
- } else
+ } else
gnm_style_ref (style);
/* 1 reference for style*/
}
@@ -2915,8 +2915,8 @@ oo_cell_start (GsfXMLIn *xin, xmlChar const **attrs)
if (style == NULL && (merge_cols > 1 || merge_rows > 1)) {
/* We may not have a new style but the current cell may */
/* have been assigned a style earlier */
- GnmStyle const *old_style
- = sheet_style_get (state->pos.sheet, state->pos.eval.col,
+ GnmStyle const *old_style
+ = sheet_style_get (state->pos.sheet, state->pos.eval.col,
state->pos.eval.row);
if (old_style != NULL)
style = gnm_style_dup (old_style);
@@ -3445,7 +3445,7 @@ oo_style (GsfXMLIn *xin, xmlChar const **attrs)
gnm_style_unref (state->cur_style.cells);
/* one reference left for state->cur_style.cells */
}
-
+
break;
case OO_STYLE_COL:
@@ -4404,12 +4404,12 @@ odf_get_paper_size (gnm_float width, gnm_float height, gint orient)
w_diff = n_height - width;
h_diff = n_width - height;
}
-
+
if (w_diff > -2. && w_diff < 2. && h_diff > -2 && h_diff < 2) {
size = gtk_paper_size_copy (n_size);
break;
}
- }
+ }
go_list_free_custom (plist, (GFreeFunc)gtk_paper_size_free);
if (size != NULL)
@@ -4443,7 +4443,7 @@ odf_header_properties (GsfXMLIn *xin, xmlChar const **attrs)
height_set = TRUE;
} else if (oo_attr_distance (xin, attrs, OO_NS_FO, "min-height", &pts))
if (!height_set)
- print_info_set_edge_to_below_header
+ print_info_set_edge_to_below_header
(state->print.cur_pi, pts + page_margin);
}
@@ -4467,7 +4467,7 @@ odf_footer_properties (GsfXMLIn *xin, xmlChar const **attrs)
height_set = TRUE;
} else if (oo_attr_distance (xin, attrs, OO_NS_FO, "min-height", &pts))
if (!height_set)
- print_info_set_edge_to_above_footer
+ print_info_set_edge_to_above_footer
(state->print.cur_pi, pts + page_margin);
}
@@ -4530,7 +4530,7 @@ odf_page_layout_properties (GsfXMLIn *xin, xmlChar const **attrs)
} else if (oo_attr_enum (xin, attrs, OO_NS_STYLE, "print-orientation",
print_orientation_type, &orient)) {
gtk_page_setup_set_orientation (gps, orient);
- } else if (gsf_xml_in_namecmp (xin, CXML2C (attrs[0]),
+ } else if (gsf_xml_in_namecmp (xin, CXML2C (attrs[0]),
OO_NS_STYLE, "print")) {
gchar **items = g_strsplit (CXML2C (attrs[1]), " ", 0);
gchar **items_c = items;
@@ -4546,7 +4546,7 @@ odf_page_layout_properties (GsfXMLIn *xin, xmlChar const **attrs)
/* ODF does not distinguish AT_END and IN_PLACE */
state->print.cur_pi->comment_placement = PRINT_COMMENTS_AT_END;
g_strfreev (items_c);
- } else if (gsf_xml_in_namecmp (xin, CXML2C (attrs[0]),
+ } else if (gsf_xml_in_namecmp (xin, CXML2C (attrs[0]),
OO_GNUM_NS_EXT, "style-print")) {
gchar **items = g_strsplit (CXML2C (attrs[1]), " ", 0);
gchar **items_c = items;
@@ -4578,13 +4578,13 @@ odf_page_layout_properties (GsfXMLIn *xin, xmlChar const **attrs)
PRINT_COMMENTS_IN_PLACE;
/* STYLE "writing-mode" is being ignored since we can't store it anywhere atm */
-
+
if (h_set && w_set) {
GtkPaperSize *size;
size = odf_get_paper_size (width, height, orient);
gtk_page_setup_set_paper_size (gps, size);
gtk_paper_size_free (size);
-
+
}
}
@@ -4599,7 +4599,7 @@ odf_page_layout (GsfXMLIn *xin, xmlChar const **attrs)
name = CXML2C (attrs[1]);
if (name != NULL) {
- state->print.cur_pi = print_info_new (TRUE);
+ state->print.cur_pi = print_info_new (TRUE);
g_hash_table_insert (state->styles.page_layouts, g_strdup (name), state->print.cur_pi);
} else
oo_warning (xin, _("Missing page layout identifier"));
@@ -4640,9 +4640,9 @@ odf_master_page (GsfXMLIn *xin, xmlChar const **attrs)
print_hf_free (state->print.cur_pi->footer);
state->print.cur_pi->header = print_hf_new (NULL, NULL, NULL);
state->print.cur_pi->footer = print_hf_new (NULL, NULL, NULL);
-
+
g_hash_table_insert (state->styles.master_pages, g_strdup (name), state->print.cur_pi);
- } else
+ } else
oo_warning (xin, _("Master page style without name encountered!"));
}
@@ -4687,7 +4687,7 @@ odf_header_footer (GsfXMLIn *xin, xmlChar const **attrs)
if (margin >= state->print.cur_pi->edge_to_above_footer)
print_info_set_edge_to_above_footer (state->print.cur_pi, margin + 1);
} else
- print_info_set_edge_to_above_footer (state->print.cur_pi, margin);
+ print_info_set_edge_to_above_footer (state->print.cur_pi, margin);
}
state->print.cur_hf_format = &state->print.cur_hf->middle_format;
}
@@ -4719,7 +4719,7 @@ odf_hf_span (GsfXMLIn *xin, G_GNUC_UNUSED GsfXMLBlob *blob)
if (state->print.cur_hf_format == NULL)
return;
-
+
if (*(state->print.cur_hf_format) == NULL)
new = g_strdup (xin->content->str);
else
@@ -4733,7 +4733,7 @@ odf_hf_item (GsfXMLIn *xin, char const *item)
{
OOParseState *state = (OOParseState *)xin->user_state;
char *new;
-
+
if (state->print.cur_hf_format == NULL)
return;
@@ -4742,7 +4742,7 @@ odf_hf_item (GsfXMLIn *xin, char const *item)
else
new = g_strconcat (*(state->print.cur_hf_format), "&[", _(item), "]", NULL);
g_free (*(state->print.cur_hf_format));
- *(state->print.cur_hf_format) = new;
+ *(state->print.cur_hf_format) = new;
}
static void
@@ -4764,7 +4764,7 @@ odf_hf_item_w_data_style (GsfXMLIn *xin, xmlChar const **attrs, char const *item
if (data_style_name == NULL)
odf_hf_item (xin, item);
else {
- GOFormat const *fmt =
+ GOFormat const *fmt =
g_hash_table_lookup (state->formats, data_style_name);
if (fmt != NULL) {
char const *fmt_str = go_format_as_XL (fmt);
@@ -4818,7 +4818,7 @@ odf_hf_file (GsfXMLIn *xin, xmlChar const **attrs)
for (; attrs != NULL && attrs[0] && attrs[1] ; attrs += 2)
if (oo_attr_enum (xin, attrs, OO_NS_TABLE, "display-list", dropdown_types, &tmp)) ;
-
+
switch (tmp) {
case 0:
odf_hf_item (xin, _("path"));
@@ -4834,7 +4834,7 @@ odf_hf_file (GsfXMLIn *xin, xmlChar const **attrs)
case 2:
odf_hf_item (xin, _("file"));
break;
- }
+ }
}
static void
@@ -4867,7 +4867,7 @@ odf_hf_expression (GsfXMLIn *xin, xmlChar const **attrs)
char *new;
new = g_strconcat ((tmp == 1) ? "cellt" : "cell", ":", str, NULL);
odf_hf_item (xin, new);
- g_free (new);
+ g_free (new);
}
}
@@ -6080,15 +6080,15 @@ oo_db_range_start (GsfXMLIn *xin, xmlChar const **attrs)
for (; attrs != NULL && attrs[0] && attrs[1] ; attrs += 2)
if (gsf_xml_in_namecmp (xin, CXML2C (attrs[0]), OO_NS_TABLE, "target-range-address")) {
- char const *ptr = oo_cellref_parse
+ char const *ptr = oo_cellref_parse
(&ref.a, CXML2C (attrs[1]), &state->pos, NULL);
if (ref.a.sheet != invalid_sheet &&
':' == *ptr &&
'\0' == *oo_cellref_parse (&ref.b, ptr+1, &state->pos, NULL) &&
ref.b.sheet != invalid_sheet) {
- state->filter = gnm_filter_new
+ state->filter = gnm_filter_new
(ref.a.sheet, range_init_rangeref (&r, &ref));
- expr = gnm_expr_new_constant
+ expr = gnm_expr_new_constant
(value_new_cellrange_r (ref.a.sheet, &r));
} else
oo_warning (xin, _("Invalid DB range '%s'"), attrs[1]);
@@ -6405,7 +6405,7 @@ od_draw_control_start (GsfXMLIn *xin, xmlChar const **attrs)
(&ref, oc->linked_cell,
parse_pos_init_sheet (&pp, state->pos.sheet),
NULL);
- if (ptr != oc->linked_cell
+ if (ptr != oc->linked_cell
&& ref.a.sheet != invalid_sheet) {
GnmValue *v = value_new_cellrange
(&ref.a, &ref.a, 0, 0);
@@ -6444,7 +6444,7 @@ od_draw_control_start (GsfXMLIn *xin, xmlChar const **attrs)
(&ref, oc->source_cell_range,
parse_pos_init_sheet (&pp, state->pos.sheet),
NULL);
- if (ptr != oc->source_cell_range &&
+ if (ptr != oc->source_cell_range &&
ref.a.sheet != invalid_sheet) {
GnmValue *v = value_new_cellrange
(&ref.a, &ref.b, 0, 0);
@@ -6949,7 +6949,7 @@ oo_plot_assign_dim (GsfXMLIn *xin, xmlChar const *range, int dim_type, char cons
if (NULL != range) {
GnmRangeRef ref;
- char const *ptr = oo_rangeref_parse
+ char const *ptr = oo_rangeref_parse
(&ref, CXML2C (range),
parse_pos_init_sheet (&pp, state->pos.sheet),
NULL);
@@ -7088,10 +7088,10 @@ oo_plot_area (GsfXMLIn *xin, xmlChar const **attrs)
GnmEvalPos ep;
GnmRangeRef ref;
Sheet *dummy;
- char const *ptr = oo_rangeref_parse
+ char const *ptr = oo_rangeref_parse
(&ref, CXML2C (source_range_str),
parse_pos_init_sheet (&pp, state->pos.sheet), NULL);
- if (ptr != CXML2C (source_range_str)
+ if (ptr != CXML2C (source_range_str)
&& ref.a.sheet != invalid_sheet) {
gnm_rangeref_normalize (&ref,
eval_pos_init_sheet (&ep, state->pos.sheet),
@@ -7153,7 +7153,7 @@ oo_plot_area (GsfXMLIn *xin, xmlChar const **attrs)
if (oo_style_has_property (state->chart.i_plot_styles, "multi-series", FALSE)) {
type = "XLSurfacePlot";
state->chart.plot_type = OO_PLOT_XL_SURFACE;
- } else if (oo_style_has_property (state->chart.i_plot_styles,
+ } else if (oo_style_has_property (state->chart.i_plot_styles,
"three-dimensional", FALSE)) {
type = "GogSurfacePlot";
state->chart.plot_type = OO_PLOT_SURFACE;
@@ -7164,7 +7164,7 @@ oo_plot_area (GsfXMLIn *xin, xmlChar const **attrs)
case OO_PLOT_GANTT: type = "GogDropBarPlot"; break;
case OO_PLOT_POLAR: type = "GogPolarPlot"; break;
case OO_PLOT_XYZ_SURFACE:
- if (oo_style_has_property (state->chart.i_plot_styles,
+ if (oo_style_has_property (state->chart.i_plot_styles,
"three-dimensional", FALSE))
type = "GogXYZSurfacePlot";
else
@@ -7296,12 +7296,12 @@ oo_plot_series (GsfXMLIn *xin, xmlChar const **attrs)
GnmValue *v;
GnmExprTop const *texpr;
GnmParsePos pp;
- char const *ptr = oo_rangeref_parse
+ char const *ptr = oo_rangeref_parse
(&ref, CXML2C (attrs[1]),
- parse_pos_init_sheet
+ parse_pos_init_sheet
(&pp, state->pos.sheet),
NULL);
- if (ptr == CXML2C (attrs[1]) ||
+ if (ptr == CXML2C (attrs[1]) ||
ref.a.sheet == invalid_sheet)
return;
v = value_new_cellrange (&ref.a, &ref.b, 0, 0);
@@ -7987,7 +7987,7 @@ odf_line (GsfXMLIn *xin, xmlChar const **attrs)
(&ref, CXML2C (attrs[1]),
parse_pos_init_sheet (&pp, state->pos.sheet),
NULL);
- if (ptr != CXML2C (attrs[1])
+ if (ptr != CXML2C (attrs[1])
&& ref.a.sheet != invalid_sheet) {
cell_base.end.col = ref.a.col;
cell_base.end.row = ref.a.row;
@@ -8619,7 +8619,7 @@ static void
odf_find_version (GsfXMLIn *xin, xmlChar const **attrs)
{
OOParseState *state = (OOParseState *)xin->user_state;
-
+
for (; attrs != NULL && attrs[0] && attrs[1] ; attrs += 2)
if (oo_attr_float (xin, attrs, OO_NS_OFFICE,
"version", &state->ver_odf));
diff --git a/plugins/openoffice/openoffice-write.c b/plugins/openoffice/openoffice-write.c
index b409cdd..22992f0 100644
--- a/plugins/openoffice/openoffice-write.c
+++ b/plugins/openoffice/openoffice-write.c
@@ -638,7 +638,7 @@ odf_write_table_style (GnmOOExport *state, Sheet const *sheet)
{
char *name = table_style_name (sheet);
char *mp_name = table_master_page_style_name (sheet);
-
+
odf_start_style (state->xml, name, "table");
gsf_xml_out_add_cstr_unchecked (state->xml, STYLE "master-page-name", mp_name);
@@ -1856,7 +1856,7 @@ odf_print_string (GnmConventionsOut *out, char const *str, char quote)
g_string_append_c (target, quote);
}
g_string_append_c (target, quote);
-
+
}
static void
@@ -1884,15 +1884,15 @@ odf_cellref_as_string_base (GnmConventionsOut *out,
g_string_append_c (target, '.');
gnm_cellpos_init_cellref_ss (&pos, cell_ref, &out->pp->eval, ss);
-
+
if (!cell_ref->col_relative)
g_string_append_c (target, '$');
g_string_append (target, col_name (pos.col));
-
+
if (!cell_ref->row_relative)
g_string_append_c (target, '$');
g_string_append (target, row_name (pos.row));
-
+
}
static void
@@ -2525,7 +2525,7 @@ odf_expr_conventions_new (void)
}
static gboolean
-odf_cell_is_covered (G_GNUC_UNUSED Sheet const *sheet,
+odf_cell_is_covered (G_GNUC_UNUSED Sheet const *sheet,
G_GNUC_UNUSED GnmCell *current_cell,
int col, int row, GnmRange const *merge_range,
GSList **merge_ranges)
@@ -3214,7 +3214,7 @@ finder (gconstpointer a, gconstpointer b)
}
static int
-write_styled_cells (GnmOOExport *state, G_GNUC_UNUSED Sheet const *sheet,
+write_styled_cells (GnmOOExport *state, G_GNUC_UNUSED Sheet const *sheet,
int row, int row_length,
int max_rows, GnmStyleList *list)
{
@@ -3418,16 +3418,16 @@ odf_write_sheet (GnmOOExport *state)
extent = sheet_get_extent (sheet, FALSE);
cell_extent = sheet_get_cells_extent (sheet);
extent = range_union (&extent, &cell_extent);
-
+
style_extent = extent;
/* We only want to get the common column style */
sheet_style_get_extent (sheet, &style_extent, col_styles);
- repeat_top_use = print_load_repeat_range
+ repeat_top_use = print_load_repeat_range
(sheet->print_info->repeat_top, &r, sheet);
repeat_top_start = repeat_top_use ? r.start.row : 0;
repeat_top_end = repeat_top_use ? r.end.row : 0;
- repeat_left_use = print_load_repeat_range
+ repeat_left_use = print_load_repeat_range
(sheet->print_info->repeat_left, &r, sheet);
repeat_left_start = repeat_left_use ? r.start.col : 0;
repeat_left_end = repeat_left_use ? r.end.col : 0;
@@ -3440,22 +3440,22 @@ odf_write_sheet (GnmOOExport *state)
/* MS Excel 2010 stumbles over it */
/* gsf_xml_out_start_element */
/* (state->xml, TABLE "table-columns"); */
- odf_write_formatted_columns (state, sheet, col_styles,
+ odf_write_formatted_columns (state, sheet, col_styles,
0, repeat_left_start);
/* gsf_xml_out_end_element (state->xml); */
}
- gsf_xml_out_start_element
+ gsf_xml_out_start_element
(state->xml, TABLE "table-header-columns");
- odf_write_formatted_columns (state, sheet, col_styles,
- repeat_left_start,
+ odf_write_formatted_columns (state, sheet, col_styles,
+ repeat_left_start,
repeat_left_end + 1);
- gsf_xml_out_end_element (state->xml);
+ gsf_xml_out_end_element (state->xml);
if (repeat_left_end < max_cols) {
/* While ODF allows the TABLE "table-columns" wrapper, */
/* MS Excel 2010 stumbles over it */
/* gsf_xml_out_start_element */
/* (state->xml, TABLE "table-columns"); */
- odf_write_formatted_columns (state, sheet, col_styles,
+ odf_write_formatted_columns (state, sheet, col_styles,
repeat_left_end + 1, max_cols);
/* gsf_xml_out_end_element (state->xml); */
}
@@ -3489,7 +3489,7 @@ odf_write_sheet (GnmOOExport *state)
}
esr = MAX (extent.start.row, repeat_top_start);
eer = MIN (extent.end.row, repeat_top_end);
- gsf_xml_out_start_element
+ gsf_xml_out_start_element
(state->xml, TABLE "table-header-rows");
odf_write_styled_empty_rows (state, sheet, repeat_top_start, esr,
max_cols, pb, col_styles);
@@ -3499,7 +3499,7 @@ odf_write_sheet (GnmOOExport *state)
max_cols, &sheet_merges, pb, col_styles);
odf_write_styled_empty_rows (state, sheet, eer + 1, repeat_top_end + 1,
max_cols, pb, col_styles);
- gsf_xml_out_end_element (state->xml);
+ gsf_xml_out_end_element (state->xml);
if (repeat_top_end < max_rows) {
esr = MAX (extent.start.row, repeat_top_end + 1);
eer = MAX (extent.end.row, repeat_top_end + 1);
@@ -3507,7 +3507,7 @@ odf_write_sheet (GnmOOExport *state)
/* MS Excel 2010 stumbles over it */
/* gsf_xml_out_start_element */
/* (state->xml, TABLE "table-rows"); */
- odf_write_styled_empty_rows (state, sheet, repeat_top_end + 1,
+ odf_write_styled_empty_rows (state, sheet, repeat_top_end + 1,
esr,
max_cols, pb, col_styles);
odf_write_content_rows (state, sheet,
@@ -3987,7 +3987,7 @@ odf_validation_base_cell_address (GnmOOExport *state,
}
static void
-odf_validation_append_expression (GnmOOExport *state, GString *str, GnmExprTop const *texpr,
+odf_validation_append_expression (GnmOOExport *state, GString *str, GnmExprTop const *texpr,
GnmParsePos *pp)
{
char *formula;
@@ -3998,8 +3998,8 @@ odf_validation_append_expression (GnmOOExport *state, GString *str, GnmExprTop c
}
static void
-odf_validation_append_expression_pair (GnmOOExport *state, GString *str,
- GnmValidation const *val,
+odf_validation_append_expression_pair (GnmOOExport *state, GString *str,
+ GnmValidation const *val,
GnmParsePos *pp)
{
str = g_string_append_c (str, '(');
@@ -4012,7 +4012,7 @@ odf_validation_append_expression_pair (GnmOOExport *state, GString *str,
static void
odf_validation_general (GnmOOExport *state, GnmValidation const *val,
- G_GNUC_UNUSED Sheet *sheet,
+ G_GNUC_UNUSED Sheet *sheet,
G_GNUC_UNUSED GnmStyleRegion const *sr,
char const *prefix, GnmParsePos *pp)
{
@@ -4064,7 +4064,7 @@ odf_validation_general (GnmOOExport *state, GnmValidation const *val,
static void
odf_validation_length (GnmOOExport *state, GnmValidation const *val,
- G_GNUC_UNUSED Sheet *sheet,
+ G_GNUC_UNUSED Sheet *sheet,
G_GNUC_UNUSED GnmStyleRegion const *sr, GnmParsePos *pp)
{
GString *str = g_string_new ("of:");
@@ -4113,7 +4113,7 @@ odf_validation_length (GnmOOExport *state, GnmValidation const *val,
static void
odf_validation_custom (GnmOOExport *state, GnmValidation const *val,
- G_GNUC_UNUSED Sheet *sheet,
+ G_GNUC_UNUSED Sheet *sheet,
G_GNUC_UNUSED GnmStyleRegion const *sr, GnmParsePos *pp)
{
GString *str = g_string_new (NULL);
@@ -4128,7 +4128,7 @@ odf_validation_custom (GnmOOExport *state, GnmValidation const *val,
static void
odf_validation_in_list (GnmOOExport *state, GnmValidation const *val,
- G_GNUC_UNUSED Sheet *sheet,
+ G_GNUC_UNUSED Sheet *sheet,
G_GNUC_UNUSED GnmStyleRegion const *sr, GnmParsePos *pp)
{
GString *str;
@@ -4172,19 +4172,19 @@ odf_print_spreadsheet_content_validations (GnmOOExport *state)
odf_validation_general (state, val, sheet, sr, "", &pp);
break;
case VALIDATION_TYPE_AS_INT:
- odf_validation_general (state, val, sheet, sr,
+ odf_validation_general (state, val, sheet, sr,
"cell-content-is-whole-number() and ", &pp);
break;
case VALIDATION_TYPE_AS_NUMBER:
- odf_validation_general (state, val, sheet, sr,
+ odf_validation_general (state, val, sheet, sr,
"cell-content-is-decimal-number() and ", &pp);
break;
case VALIDATION_TYPE_AS_DATE:
- odf_validation_general (state, val, sheet, sr,
+ odf_validation_general (state, val, sheet, sr,
"ell-content-is-date() and ", &pp);
break;
case VALIDATION_TYPE_AS_TIME:
- odf_validation_general (state, val, sheet, sr,
+ odf_validation_general (state, val, sheet, sr,
"ell-content-is-time() and ", &pp);
break;
case VALIDATION_TYPE_IN_LIST:
@@ -4242,7 +4242,7 @@ odf_print_spreadsheet_content_prelude (GnmOOExport *state)
}
static void
-odf_write_named_expression (G_GNUC_UNUSED gpointer key, GnmNamedExpr *nexpr,
+odf_write_named_expression (G_GNUC_UNUSED gpointer key, GnmNamedExpr *nexpr,
GnmOOExport *state)
{
char const *name;
@@ -4535,13 +4535,13 @@ odf_write_this_conditional_xl_style (char const *xl, char const *name, GnmOOExpo
gsf_xml_out_end_element (state->xml); /* </number:number-style> */
}
-static void
+static void
odf_render_tab (GnmOOExport *state, G_GNUC_UNUSED char const *args)
{
- gsf_xml_out_simple_element (state->xml, TEXT "sheet-name", NULL);
+ gsf_xml_out_simple_element (state->xml, TEXT "sheet-name", NULL);
}
-static void
+static void
odf_render_page (GnmOOExport *state, G_GNUC_UNUSED char const *args)
{
gsf_xml_out_start_element (state->xml, TEXT "page-number");
@@ -4550,7 +4550,7 @@ odf_render_page (GnmOOExport *state, G_GNUC_UNUSED char const *args)
gsf_xml_out_end_element (state->xml);
}
-static void
+static void
odf_render_pages (GnmOOExport *state, G_GNUC_UNUSED char const *args)
{
gsf_xml_out_start_element (state->xml, TEXT "page-count");
@@ -4559,7 +4559,7 @@ odf_render_pages (GnmOOExport *state, G_GNUC_UNUSED char const *args)
gsf_xml_out_end_element (state->xml);
}
-static void
+static void
odf_render_date (GnmOOExport *state, char const *args)
{
const char *style_name;
@@ -4570,12 +4570,12 @@ odf_render_date (GnmOOExport *state, char const *args)
gsf_xml_out_start_element (state->xml, TEXT "date");
if (style_name)
- gsf_xml_out_add_cstr_unchecked
+ gsf_xml_out_add_cstr_unchecked
(state->xml, STYLE "data-style-name", style_name);
- gsf_xml_out_end_element (state->xml);
+ gsf_xml_out_end_element (state->xml);
}
-static void
+static void
odf_render_date_to_xl (GnmOOExport *state, char const *args)
{
if (args == NULL)
@@ -4583,7 +4583,7 @@ odf_render_date_to_xl (GnmOOExport *state, char const *args)
(void)xl_find_format_xl (state, args, 0);
}
-static void
+static void
odf_render_time (GnmOOExport *state, char const *args)
{
const char *style_name;
@@ -4594,11 +4594,11 @@ odf_render_time (GnmOOExport *state, char const *args)
gsf_xml_out_start_element (state->xml, TEXT "time");
if (style_name)
- gsf_xml_out_add_cstr_unchecked
+ gsf_xml_out_add_cstr_unchecked
(state->xml, STYLE "data-style-name", style_name);
- gsf_xml_out_end_element (state->xml);
+ gsf_xml_out_end_element (state->xml);
}
-static void
+static void
odf_render_time_to_xl (GnmOOExport *state, char const *args)
{
if (args == NULL)
@@ -4606,30 +4606,30 @@ odf_render_time_to_xl (GnmOOExport *state, char const *args)
(void)xl_find_format_xl (state, args, 0);
}
-static void
+static void
odf_render_file (GnmOOExport *state, G_GNUC_UNUSED char const *args)
{
gsf_xml_out_start_element (state->xml, TEXT "file-name");
gsf_xml_out_add_cstr_unchecked (state->xml, TEXT "display", "name-and-extension");
- gsf_xml_out_end_element (state->xml);
+ gsf_xml_out_end_element (state->xml);
}
-static void
+static void
odf_render_path (GnmOOExport *state, G_GNUC_UNUSED char const *args)
{
gsf_xml_out_start_element (state->xml, TEXT "file-name");
gsf_xml_out_add_cstr_unchecked (state->xml, TEXT "display", "path");
- gsf_xml_out_end_element (state->xml);
+ gsf_xml_out_end_element (state->xml);
}
-static void
+static void
odf_render_cell (GnmOOExport *state, char const *args)
{
GnmExprTop const *texpr = NULL;
GnmParsePos pp;
char *formula, *full_formula;
GnmConventions *convs;
-
+
if (args) {
convs = gnm_xml_io_conventions ();
parse_pos_init_sheet (&pp, state->sheet);
@@ -4653,7 +4653,7 @@ odf_render_cell (GnmOOExport *state, char const *args)
g_free (full_formula);
}
- gsf_xml_out_end_element (state->xml);
+ gsf_xml_out_end_element (state->xml);
}
typedef struct {
@@ -4691,7 +4691,7 @@ static render_ops_t odf_render_ops_to_xl [] = {
* to the opcode and then a number format code
*/
static void
-odf_render_opcode (GnmOOExport *state, char /* non-const */ *opcode,
+odf_render_opcode (GnmOOExport *state, char /* non-const */ *opcode,
render_ops_t *render_ops)
{
char *args;
@@ -4707,7 +4707,7 @@ odf_render_opcode (GnmOOExport *state, char /* non-const */ *opcode,
for (i = 0; render_ops [i].name; i++) {
if (render_ops [i].name_trans == NULL) {
- render_ops [i].name_trans
+ render_ops [i].name_trans
= g_utf8_casefold (_(render_ops [i].name), -1);
}
@@ -4761,21 +4761,21 @@ odf_master_styles_to_xl_styles (GnmOOExport *state)
if (sheet->print_info->page_setup == NULL)
print_info_load_defaults (sheet->print_info);
-
+
if (sheet->print_info->header != NULL) {
- odf_hf_region_to_xl_styles
+ odf_hf_region_to_xl_styles
(state, sheet->print_info->header->left_format);
- odf_hf_region_to_xl_styles
+ odf_hf_region_to_xl_styles
(state, sheet->print_info->header->middle_format);
- odf_hf_region_to_xl_styles
+ odf_hf_region_to_xl_styles
(state, sheet->print_info->header->right_format);
}
if (sheet->print_info->footer != NULL) {
- odf_hf_region_to_xl_styles
+ odf_hf_region_to_xl_styles
(state, sheet->print_info->footer->left_format);
- odf_hf_region_to_xl_styles
+ odf_hf_region_to_xl_styles
(state, sheet->print_info->footer->middle_format);
- odf_hf_region_to_xl_styles
+ odf_hf_region_to_xl_styles
(state, sheet->print_info->footer->right_format);
}
}
@@ -4795,7 +4795,7 @@ odf_write_hf_region (GnmOOExport *state, char const *format, char const *id)
g_object_get (G_OBJECT (state->xml), "pretty-print", &pp, NULL);
g_object_set (G_OBJECT (state->xml), "pretty-print", FALSE, NULL);
gsf_xml_out_start_element (state->xml, TEXT "p");
-
+
text = g_string_new (NULL);
for (p = format; *p; p = g_utf8_next_char(p)) {
if (*p == '&' && p[1] == '[') {
@@ -4809,7 +4809,7 @@ odf_write_hf_region (GnmOOExport *state, char const *format, char const *id)
if (*p == ']') {
char *operation = g_strndup (start, p - start);
if (text->len > 0) {
- gsf_xml_out_simple_element
+ gsf_xml_out_simple_element
(state->xml, TEXT "span", text->str);
g_string_truncate (text, 0);
}
@@ -4861,7 +4861,7 @@ static void
odf_write_office_styles (GnmOOExport *state)
{
gsf_xml_out_start_element (state->xml, OFFICE "styles");
-
+
g_hash_table_foreach (state->xl_styles, (GHFunc) odf_write_this_xl_style, state);
g_hash_table_foreach (state->xl_styles_neg, (GHFunc) odf_write_this_xl_style_neg, state);
g_hash_table_foreach (state->xl_styles_zero, (GHFunc) odf_write_this_xl_style_zero, state);
@@ -4955,7 +4955,7 @@ odf_write_page_layout (GnmOOExport *state, PrintInformation *pi,
GtkPageOrientation orient = gtk_page_setup_get_orientation (gps);
gboolean landscape = !(orient == GTK_PAGE_ORIENTATION_PORTRAIT ||
orient == GTK_PAGE_ORIENTATION_REVERSE_PORTRAIT);
- GString *gstr = g_string_new ("charts drawings objects");
+ GString *gstr = g_string_new ("charts drawings objects");
gsf_xml_out_start_element (state->xml, STYLE "page-layout");
gsf_xml_out_add_cstr_unchecked (state->xml, STYLE "name", name);
@@ -4976,16 +4976,16 @@ odf_write_page_layout (GnmOOExport *state, PrintInformation *pi,
odf_add_pt (state->xml, FOSTYLE "page-height",
gtk_page_setup_get_paper_height (gps, GTK_UNIT_POINTS));
i = (pi->center_horizontally ? 1 : 0) | (pi->center_vertically ? 2 : 0);
- gsf_xml_out_add_cstr_unchecked (state->xml, STYLE "table-centering",
+ gsf_xml_out_add_cstr_unchecked (state->xml, STYLE "table-centering",
centre_type [i]);
- gsf_xml_out_add_cstr_unchecked
- (state->xml, STYLE "print-page-order",
+ gsf_xml_out_add_cstr_unchecked
+ (state->xml, STYLE "print-page-order",
pi->print_across_then_down ? "ltr" : "ttb");
- gsf_xml_out_add_cstr_unchecked
- (state->xml, STYLE "writing-mode",
+ gsf_xml_out_add_cstr_unchecked
+ (state->xml, STYLE "writing-mode",
sheet->text_is_rtl ? "rl-tb" : "lr-tb");
- gsf_xml_out_add_cstr_unchecked
- (state->xml, STYLE "print-orientation",
+ gsf_xml_out_add_cstr_unchecked
+ (state->xml, STYLE "print-orientation",
landscape ? "landscape" : "portrait");
if (pi->print_grid_lines)
@@ -4994,9 +4994,9 @@ odf_write_page_layout (GnmOOExport *state, PrintInformation *pi,
g_string_append (gstr, " headers");
if (pi->comment_placement != PRINT_COMMENTS_NONE)
g_string_append (gstr, " annotations");
- gsf_xml_out_add_cstr_unchecked
+ gsf_xml_out_add_cstr_unchecked
(state->xml, STYLE "print", gstr->str);
-
+
if (state->with_extension) {
g_string_truncate (gstr, 0);
if (pi->comment_placement == PRINT_COMMENTS_AT_END)
@@ -5021,12 +5021,12 @@ odf_write_page_layout (GnmOOExport *state, PrintInformation *pi,
case PRINT_ERRORS_AS_DISPLAYED:
break;
}
- gsf_xml_out_add_cstr_unchecked
+ gsf_xml_out_add_cstr_unchecked
(state->xml, GNMSTYLE "style-print", gstr->str);
}
g_string_free (gstr, TRUE);
-
+
gsf_xml_out_end_element (state->xml); /* </style:page-layout-properties> */
odf_write_hf_style (state, pi, STYLE "header-style", TRUE);
@@ -5066,12 +5066,12 @@ odf_write_master_styles (GnmOOExport *state)
gsf_xml_out_start_element (state->xml, STYLE "master-page");
gsf_xml_out_add_cstr_unchecked (state->xml, STYLE "name", mp_name);
gsf_xml_out_add_cstr (state->xml, STYLE "display-name", sheet->name_unquoted);
- gsf_xml_out_add_cstr_unchecked (state->xml, STYLE "page-layout-name",
+ gsf_xml_out_add_cstr_unchecked (state->xml, STYLE "page-layout-name",
name);
odf_write_hf (state, sheet->print_info, STYLE "header", TRUE);
odf_write_hf (state, sheet->print_info, STYLE "footer", FALSE);
-
+
gsf_xml_out_end_element (state->xml); /* </master-page> */
g_free (mp_name);
g_free (name);
@@ -5686,7 +5686,7 @@ odf_write_regression_curve (GnmOOExport *state, GogObjectRole const *role, GogOb
(l == regressions) ? CHART "regression-curve"
: GNMSTYLE "regression-curve");
gsf_xml_out_add_cstr (state->xml, CHART "style-name", str);
-
+
if (state->with_extension) {
/* Upper and lower bounds */
bd = gog_dataset_get_dim (GOG_DATASET (regression), 0);
@@ -5725,7 +5725,7 @@ odf_write_regression_curve (GnmOOExport *state, GogObjectRole const *role, GogOb
odf_write_gog_position (state, equation);
gsf_xml_out_end_element (state->xml); /* </chart:equation> */
}
-
+
gsf_xml_out_end_element (state->xml); /* </chart:regression-curve> */
g_free (str);
}
@@ -5762,7 +5762,7 @@ odf_write_standard_series (GnmOOExport *state, GSList const *series)
(GOG_OBJECT (series->data), "Regression curve");
if (role != NULL)
odf_write_regression_curve (state, role, GOG_OBJECT (series->data), &pp);
-
+
role = gog_object_find_role_by_name
(GOG_OBJECT (series->data), "Trend line");
if (role != NULL)
@@ -5972,8 +5972,8 @@ odf_write_min_max_series (GnmOOExport *state, GSList const *orig_series)
static void
-odf_write_interpolation_attribute (GnmOOExport *state,
- G_GNUC_UNUSED GOStyle const *style,
+odf_write_interpolation_attribute (GnmOOExport *state,
+ G_GNUC_UNUSED GOStyle const *style,
GogObject const *series)
{
gchar *interpolation = NULL;
@@ -6141,7 +6141,7 @@ odf_get_marker (GOMarkerShape m)
}
static void
-odf_write_axis_style (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
+odf_write_axis_style (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
GogObject const *axis)
{
char const *type = NULL;
@@ -6190,7 +6190,7 @@ odf_write_generic_axis_style (GnmOOExport *state, char const *style_label)
}
static void
-odf_write_circle_axes_styles (GnmOOExport *state,
+odf_write_circle_axes_styles (GnmOOExport *state,
G_GNUC_UNUSED GogObject const *chart,
G_GNUC_UNUSED GogObject const *plot,
gchar **x_style,
@@ -6208,7 +6208,7 @@ odf_write_circle_axes_styles (GnmOOExport *state,
}
static void
-odf_write_radar_axes_styles (G_GNUC_UNUSED GnmOOExport *state,
+odf_write_radar_axes_styles (G_GNUC_UNUSED GnmOOExport *state,
GogObject const *chart,
G_GNUC_UNUSED GogObject const *plot,
gchar **x_style,
@@ -6230,7 +6230,7 @@ odf_write_radar_axes_styles (G_GNUC_UNUSED GnmOOExport *state,
}
static void
-odf_write_standard_axes_styles (G_GNUC_UNUSED GnmOOExport *state,
+odf_write_standard_axes_styles (G_GNUC_UNUSED GnmOOExport *state,
GogObject const *chart,
G_GNUC_UNUSED GogObject const *plot,
gchar **x_style,
@@ -6609,7 +6609,7 @@ odf_write_gog_style_text (GnmOOExport *state, GOStyle const *style)
}
}
if (mask & PANGO_FONT_MASK_WEIGHT)
- odf_add_font_weight (state,
+ odf_add_font_weight (state,
pango_font_description_get_weight (desc));
if ((mask & PANGO_FONT_MASK_STRETCH) && state->with_extension)
@@ -6748,12 +6748,12 @@ odf_write_axis_categories (GnmOOExport *state, GSList const *series)
}
static void
-odf_write_axis_full (GnmOOExport *state,
- GogObject const *chart,
+odf_write_axis_full (GnmOOExport *state,
+ GogObject const *chart,
char const *axis_role,
char const *style_label,
- char const *dimension,
- G_GNUC_UNUSED odf_chart_type_t gtype,
+ char const *dimension,
+ G_GNUC_UNUSED odf_chart_type_t gtype,
GSList const *series,
gboolean include_cats)
{
@@ -6773,41 +6773,41 @@ odf_write_axis_full (GnmOOExport *state,
odf_write_axis_categories (state, series);
gsf_xml_out_end_element (state->xml); /* </chart:axis> */
}
-
+
}
static void
-odf_write_axis (GnmOOExport *state,
- GogObject const *chart,
+odf_write_axis (GnmOOExport *state,
+ GogObject const *chart,
char const *axis_role,
char const *style_label,
- char const *dimension,
- odf_chart_type_t gtype,
+ char const *dimension,
+ odf_chart_type_t gtype,
GSList const *series)
{
- odf_write_axis_full (state, chart, axis_role, style_label,
+ odf_write_axis_full (state, chart, axis_role, style_label,
dimension, gtype, series, TRUE);
}
static void
-odf_write_axis_no_cats (GnmOOExport *state,
- GogObject const *chart,
+odf_write_axis_no_cats (GnmOOExport *state,
+ GogObject const *chart,
char const *axis_role,
char const *style_label,
- char const *dimension,
- odf_chart_type_t gtype,
+ char const *dimension,
+ odf_chart_type_t gtype,
GSList const *series)
{
- odf_write_axis_full (state, chart, axis_role, style_label,
+ odf_write_axis_full (state, chart, axis_role, style_label,
dimension, gtype, series, FALSE);
}
static void
-odf_write_generic_axis (GnmOOExport *state,
+odf_write_generic_axis (GnmOOExport *state,
G_GNUC_UNUSED GogObject const *chart,
G_GNUC_UNUSED char const *axis_role,
char const *style_label,
- char const *dimension,
+ char const *dimension,
G_GNUC_UNUSED odf_chart_type_t gtype,
GSList const *series)
{
@@ -6973,7 +6973,7 @@ odf_write_plot (GnmOOExport *state, SheetObject *so, GogObject const *chart, Gog
gboolean b;
g_object_get (G_OBJECT (plot), "horizontal", &b, NULL);
if (b)
- plot_type = "GogBarPlot";
+ plot_type = "GogBarPlot";
}
}
@@ -6993,7 +6993,7 @@ odf_write_plot (GnmOOExport *state, SheetObject *so, GogObject const *chart, Gog
if (this_plot->odf_write_axes_styles != NULL)
this_plot->odf_write_axes_styles (state, chart, plot,
&x_style, &y_style, &z_style,
- this_plot->x_axis_name, this_plot->y_axis_name,
+ this_plot->x_axis_name, this_plot->y_axis_name,
this_plot->z_axis_name);
odf_start_style (state->xml, "plotstyle", "chart");
@@ -7265,7 +7265,7 @@ odf_write_images (SheetObjectImage *image, char const *name, GnmOOExport *state)
}
static void
-odf_write_drop (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
+odf_write_drop (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
GogObject const *obj)
{
GogObjectRole const *h_role = gog_object_find_role_by_name
@@ -7276,7 +7276,7 @@ odf_write_drop (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
}
static void
-odf_write_lin_reg (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
+odf_write_lin_reg (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
GogObject const *obj)
{
gsf_xml_out_add_cstr (state->xml, CHART "regression-type", "linear");
@@ -7290,7 +7290,7 @@ odf_write_lin_reg (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
}
static void
-odf_write_polynom_reg (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
+odf_write_polynom_reg (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
GogObject const *obj)
{
if (state->with_extension) {
@@ -7306,28 +7306,28 @@ odf_write_polynom_reg (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
}
static void
-odf_write_exp_reg (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
+odf_write_exp_reg (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
G_GNUC_UNUSED GogObject const *obj)
{
gsf_xml_out_add_cstr (state->xml, CHART "regression-type", "exponential");
}
static void
-odf_write_power_reg (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
+odf_write_power_reg (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
G_GNUC_UNUSED GogObject const *obj)
{
gsf_xml_out_add_cstr (state->xml, CHART "regression-type", "power");
}
static void
-odf_write_log_reg (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
+odf_write_log_reg (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
G_GNUC_UNUSED GogObject const *obj)
{
gsf_xml_out_add_cstr (state->xml, CHART "regression-type", "logarithmic");
}
static void
-odf_write_log_fit_reg (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
+odf_write_log_fit_reg (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
G_GNUC_UNUSED GogObject const *obj)
{
if (state->with_extension)
@@ -7336,7 +7336,7 @@ odf_write_log_fit_reg (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
}
static void
-odf_write_movig_avg_reg (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
+odf_write_movig_avg_reg (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
G_GNUC_UNUSED GogObject const *obj)
{
if (state->with_extension)
@@ -7345,7 +7345,7 @@ odf_write_movig_avg_reg (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
}
static void
-odf_write_exp_smooth_reg (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
+odf_write_exp_smooth_reg (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
G_GNUC_UNUSED GogObject const *obj)
{
if (state->with_extension)
@@ -7354,7 +7354,7 @@ odf_write_exp_smooth_reg (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style
}
static void
-odf_write_pie_point (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
+odf_write_pie_point (GnmOOExport *state, G_GNUC_UNUSED GOStyle const *style,
GogObject const *obj)
{
GObjectClass *klass = G_OBJECT_GET_CLASS (obj);
@@ -7556,7 +7556,7 @@ odf_write_graphs (SheetObject *graph, char const *name, GnmOOExport *state)
static void
openoffice_file_save_real (G_GNUC_UNUSED GOFileSaver const *fs, GOIOContext *ioc,
- WorkbookView const *wbv, GsfOutput *output,
+ WorkbookView const *wbv, GsfOutput *output,
gboolean with_extension)
{
static struct {
diff --git a/src/application.c b/src/application.c
index 90e4567..579a477 100644
--- a/src/application.c
+++ b/src/application.c
@@ -477,7 +477,7 @@ gnm_app_create_opener_filter (GList *openers)
GtkFileFilter *filter = gtk_file_filter_new ();
gboolean for_history = (openers == NULL);
-
+
if (openers == NULL)
openers = go_get_file_openers ();
diff --git a/src/collect.c b/src/collect.c
index 545eb04..22fd562 100644
--- a/src/collect.c
+++ b/src/collect.c
@@ -195,7 +195,7 @@ get_single_floats_cache_entry (GnmValue const *value, CollectFlags flags)
}
static PairsFloatsCacheEntry *
-get_pairs_floats_cache_entry (GnmValue const *vx, GnmValue const *vy,
+get_pairs_floats_cache_entry (GnmValue const *vx, GnmValue const *vy,
CollectFlags flags)
{
PairsFloatsCacheEntry key;
@@ -235,7 +235,7 @@ get_or_fake_cache_entry (GnmValue const *key, CollectFlags flags,
}
static PairsFloatsCacheEntry *
-get_or_fake_pairs_cache_entry (GnmValue const *key_x, GnmValue const *key_y,
+get_or_fake_pairs_cache_entry (GnmValue const *key_x, GnmValue const *key_y,
CollectFlags flags,
GnmEvalPos const *ep)
{
@@ -285,7 +285,7 @@ get_single_cache_key (GnmExpr const *e, GnmEvalPos const *ep)
return v;
} else
return NULL;
-
+
}
/* ------------------------------------------------------------------------- */
@@ -692,7 +692,7 @@ collect_float_pairs_ce (GnmValue const *vx, GnmValue const *vy,
&n0, &missing0, &ce->error);
if (ce->error)
goto err;
-
+
ce->data_y = collect_floats_value_with_info (vy, ep, flags,
&n1, &missing1, &ce->error);
@@ -711,7 +711,7 @@ collect_float_pairs_ce (GnmValue const *vx, GnmValue const *vy,
gnm_strip_missing (ce->data_y, &n1, missing0);
}
ce->n = n0;
-
+
err:
if (ce->n <= 0) {
g_free (ce->data_x);
@@ -778,7 +778,7 @@ collect_float_pairs (GnmValue const *vx, GnmValue const *vy,
g_hash_table_replace (pairs_floats_cache, ce, ce);
total_cache_size += 1 + ce->n;
}
- }
+ }
if (free_keys) {
value_release (key_x);
@@ -821,8 +821,8 @@ collect_float_pairs (GnmValue const *vx, GnmValue const *vy,
ce->data_x = NULL;
ce->data_y = NULL;
pairs_floats_cache_entry_free (ce);
- }
- return NULL;
+ }
+ return NULL;
}
}
diff --git a/src/commands.c b/src/commands.c
index 449c895..1ff0fde 100644
--- a/src/commands.c
+++ b/src/commands.c
@@ -1449,7 +1449,7 @@ cmd_insert_cols (WorkbookControl *wbc,
{
char *mesg;
GnmRange r;
-
+
range_init_full_sheet (&r, sheet);
r.start.row = r.end.row - count + 1;
diff --git a/src/compilation.h b/src/compilation.h
index 89a01f4..ff8089c 100644
--- a/src/compilation.h
+++ b/src/compilation.h
@@ -1,7 +1,7 @@
#ifndef GNUMERIC_GTK_COMPILATION_H
#define GNUMERIC_GTK_COMPILATION_H
-#if defined(__GNUC__)
+#if defined(__GNUC__)
#define GCC_VERSION (__GNUC__ * 100 + __GNUC_MINOR__ )
#if (GCC_VERSION >= 402)
#if (GCC_VERSION >= 406)
diff --git a/src/dialogs/dialog-analysis-tools.c b/src/dialogs/dialog-analysis-tools.c
index 6d2a8a7..6c23863 100644
--- a/src/dialogs/dialog-analysis-tools.c
+++ b/src/dialogs/dialog-analysis-tools.c
@@ -527,7 +527,7 @@ tool_load_selection (GenericToolState *state, gboolean allow_multiple)
gtk_widget_show (state->dialog);
gnm_expr_entry_grab_focus (GNM_EXPR_ENTRY (state->input_entry),
TRUE);
-
+
}
diff --git a/src/dialogs/dialog-cell-format-cond.c b/src/dialogs/dialog-cell-format-cond.c
index a6c88fa..5352add 100644
--- a/src/dialogs/dialog-cell-format-cond.c
+++ b/src/dialogs/dialog-cell-format-cond.c
@@ -146,11 +146,11 @@ c_fmt_dialog_set_sensitive (CFormatState *state)
GtkTreeIter iter;
gboolean not_empty, selected;
- not_empty = gtk_tree_model_get_iter_first
+ not_empty = gtk_tree_model_get_iter_first
(GTK_TREE_MODEL (state->model), &iter);
- selected = gtk_tree_selection_get_selected
+ selected = gtk_tree_selection_get_selected
(state->selection, NULL, NULL);
-
+
gtk_widget_set_sensitive (GTK_WIDGET (state->clear), not_empty);
gtk_widget_set_sensitive (GTK_WIDGET (state->remove),
@@ -176,7 +176,7 @@ c_fmt_dialog_set_sensitive (CFormatState *state)
if (texpr)
gnm_expr_top_unref (texpr);
}
-
+
gtk_widget_set_sensitive (state->editor.add_button, ok);
gtk_widget_set_sensitive (state->editor.replace_button, ok && selected);
gtk_widget_set_sensitive (state->editor.copy_button, selected && state->homogeneous);
@@ -213,21 +213,21 @@ cb_c_fmt_dialog_chooser_type_changed (G_GNUC_UNUSED GtkComboBox *widget, CFormat
}
static void
-cb_c_fmt_dialog_chooser_entry_changed (G_GNUC_UNUSED GnmExprEntry *widget, G_GNUC_UNUSED GdkEvent *event,
+cb_c_fmt_dialog_chooser_entry_changed (G_GNUC_UNUSED GnmExprEntry *widget, G_GNUC_UNUSED GdkEvent *event,
CFormatState *state)
{
c_fmt_dialog_set_sensitive (state);
}
-void
+void
dialog_cell_format_style_added (gpointer closure, GnmStyle *style)
{
CFormatState *state = closure;
-
+
if (state->editor.style)
gnm_style_unref (state->editor.style);
state->editor.style = style;
- gtk_label_set_text (GTK_LABEL (state->editor.style_label),
+ gtk_label_set_text (GTK_LABEL (state->editor.style_label),
style ? _("(defined)") : _("undefined"));
c_fmt_dialog_set_sensitive (state);
}
@@ -237,7 +237,7 @@ c_fmt_dialog_set_component (CFormatState *state, GnmStyle *overlay, gchar const
GnmStyleElement elem, gboolean uncheck)
{
GtkWidget *w = go_gtk_builder_get_widget (state->gui, name);
-
+
if (gnm_style_is_element_set (overlay, elem))
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w), TRUE);
else if (uncheck)
@@ -250,7 +250,7 @@ cb_c_fmt_dialog_chooser_check_page (CFormatState *state, gchar const *name,
gint page)
{
GtkWidget *w = go_gtk_builder_get_widget (state->gui, name);
-
+
if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (w)))
return (1 << page);
else
@@ -261,25 +261,25 @@ static void
cb_c_fmt_dialog_edit_style_button (G_GNUC_UNUSED GtkWidget *btn, CFormatState *state)
{
int pages = 0;
- pages |= cb_c_fmt_dialog_chooser_check_page
+ pages |= cb_c_fmt_dialog_chooser_check_page
(state, "check-background", FD_BACKGROUND);
- pages |= cb_c_fmt_dialog_chooser_check_page
+ pages |= cb_c_fmt_dialog_chooser_check_page
(state, "check-number", FD_NUMBER);
- pages |= cb_c_fmt_dialog_chooser_check_page
+ pages |= cb_c_fmt_dialog_chooser_check_page
(state, "check-align", FD_ALIGNMENT);
- pages |= cb_c_fmt_dialog_chooser_check_page
+ pages |= cb_c_fmt_dialog_chooser_check_page
(state, "check-font", FD_FONT);
- pages |= cb_c_fmt_dialog_chooser_check_page
+ pages |= cb_c_fmt_dialog_chooser_check_page
(state, "check-border", FD_BORDER);
- pages |= cb_c_fmt_dialog_chooser_check_page
+ pages |= cb_c_fmt_dialog_chooser_check_page
(state, "check-protection", FD_PROTECTION);
- pages |= cb_c_fmt_dialog_chooser_check_page
+ pages |= cb_c_fmt_dialog_chooser_check_page
(state, "check-validation", FD_VALIDATION);
if (state->editor.style != NULL)
gnm_style_ref (state->editor.style);
- dialog_cell_format_select_style (state->wbcg, pages,
- GTK_WINDOW (state->dialog),
+ dialog_cell_format_select_style (state->wbcg, pages,
+ GTK_WINDOW (state->dialog),
state->editor.style, state);
}
@@ -295,76 +295,76 @@ c_fmt_dialog_get_condition (CFormatState *state)
cond->overlay = gnm_style_new ();
if (state->editor.style) {
- if (cb_c_fmt_dialog_chooser_check_page
+ if (cb_c_fmt_dialog_chooser_check_page
(state, "check-background", FD_BACKGROUND)) {
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_COLOR_BACK);
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_COLOR_PATTERN);
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_PATTERN);
}
- if (cb_c_fmt_dialog_chooser_check_page
+ if (cb_c_fmt_dialog_chooser_check_page
(state, "check-number", FD_NUMBER)) {
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_FORMAT);
}
- if (cb_c_fmt_dialog_chooser_check_page
+ if (cb_c_fmt_dialog_chooser_check_page
(state, "check-align", FD_ALIGNMENT)) {
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_ALIGN_V);
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_ALIGN_H);
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_INDENT);
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_ROTATION);
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_TEXT_DIR);
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_WRAP_TEXT);
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_SHRINK_TO_FIT);
}
- if (cb_c_fmt_dialog_chooser_check_page
+ if (cb_c_fmt_dialog_chooser_check_page
(state, "check-font", FD_FONT)) {
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_FONT_COLOR);
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_FONT_NAME);
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_FONT_BOLD);
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_FONT_ITALIC);
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_FONT_UNDERLINE);
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_FONT_STRIKETHROUGH);
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_FONT_SCRIPT);
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_FONT_SIZE);
}
- if (cb_c_fmt_dialog_chooser_check_page
+ if (cb_c_fmt_dialog_chooser_check_page
(state, "check-border", FD_BORDER)) {
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_BORDER_TOP);
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_BORDER_BOTTOM);
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_BORDER_LEFT);
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_BORDER_RIGHT);
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_BORDER_REV_DIAGONAL);
- gnm_style_merge_element (cond->overlay, state->editor.style,
+ gnm_style_merge_element (cond->overlay, state->editor.style,
MSTYLE_BORDER_DIAGONAL);
}
- if (cb_c_fmt_dialog_chooser_check_page
+ if (cb_c_fmt_dialog_chooser_check_page
(state, "check-protection", FD_PROTECTION)) {
}
- if (cb_c_fmt_dialog_chooser_check_page
+ if (cb_c_fmt_dialog_chooser_check_page
(state, "check-validation", FD_VALIDATION)) {
}
@@ -416,7 +416,7 @@ cb_c_fmt_dialog_copy_button (GtkWidget *btn, CFormatState *state)
GtkTreeIter iter;
sc = gnm_style_get_conditions (state->style);
if (sc != NULL && gtk_tree_selection_get_selected (state->selection, NULL, &iter)) {
- GtkTreePath *path = gtk_tree_model_get_path
+ GtkTreePath *path = gtk_tree_model_get_path
(GTK_TREE_MODEL (state->model), &iter);
gint *pind = gtk_tree_path_get_indices (path);
GArray const *conds = gnm_style_conditions_details (sc);
@@ -427,7 +427,7 @@ cb_c_fmt_dialog_copy_button (GtkWidget *btn, CFormatState *state)
GnmParsePos pp;
GnmStyle *style;
/* Set the condition op */
- if (gtk_tree_model_get_iter_first
+ if (gtk_tree_model_get_iter_first
(GTK_TREE_MODEL (state->editor.typestore), &iter)) {
do {
guint op;
@@ -436,11 +436,11 @@ cb_c_fmt_dialog_copy_button (GtkWidget *btn, CFormatState *state)
1, &op,
-1);
if (op == gsc->op) {
- gtk_combo_box_set_active_iter
+ gtk_combo_box_set_active_iter
(GTK_COMBO_BOX (state->editor.combo), &iter);
break;
}
- } while (gtk_tree_model_iter_next
+ } while (gtk_tree_model_iter_next
(GTK_TREE_MODEL (state->editor.typestore), &iter));
}
/* Set the expressions */
@@ -461,8 +461,8 @@ cb_c_fmt_dialog_copy_button (GtkWidget *btn, CFormatState *state)
"");
/* Set the style */
if (state->style && state->style->cond_styles)
- style = gnm_style_dup
- (g_ptr_array_index (state->style->cond_styles,
+ style = gnm_style_dup
+ (g_ptr_array_index (state->style->cond_styles,
ind));
else {
style = gnm_style_new_default ();
@@ -525,7 +525,7 @@ cb_c_fmt_dialog_copy_button (GtkWidget *btn, CFormatState *state)
}
}
-static void
+static void
c_fmt_dialog_chooser_load_combo (CFormatState *state)
{
static struct {
@@ -584,13 +584,13 @@ c_fmt_dialog_condition_setter (SheetView *sv, GnmRange const *range, CFormatStat
GnmSheetRange *sr = g_new (GnmSheetRange, 1);
sr->range = *range;
sr->sheet = sv->sheet;
- state->action.redo = go_undo_combine
+ state->action.redo = go_undo_combine
(state->action.redo,
sheet_apply_style_undo (sr, state->action.new_style));
sr = g_new (GnmSheetRange, 1);
sr->range = *range;
sr->sheet = sv->sheet;
- state->action.undo = go_undo_combine
+ state->action.undo = go_undo_combine
(sheet_apply_style_undo (sr, state->action.old_style),
state->action.undo);
state->action.size++;
@@ -617,9 +617,9 @@ c_fmt_dialog_condition_setter_tiled (SheetView *sv, GnmRange const *range, CForm
state->action.old_style = gnm_style_new ();
if (gnm_style_is_element_set (sr->style, MSTYLE_CONDITIONS) &&
NULL != (old_cond = gnm_style_get_conditions (sr->style)))
- gnm_style_set_conditions (state->action.old_style,
+ gnm_style_set_conditions (state->action.old_style,
g_object_ref (G_OBJECT (old_cond)));
- else
+ else
gnm_style_set_conditions (state->action.old_style, NULL);
c_fmt_dialog_condition_setter (state->sv, &r, state);
gnm_style_unref (state->action.old_style);
@@ -641,15 +641,15 @@ c_fmt_dialog_set_conditions (CFormatState *state, char const *cmd_label)
if (state->homogeneous) {
state->action.old_style = gnm_style_new ();
old_cond = gnm_style_get_conditions (state->style);
- gnm_style_set_conditions (state->action.old_style,
+ gnm_style_set_conditions (state->action.old_style,
old_cond ? g_object_ref (G_OBJECT (old_cond)) : NULL);
-
- sv_selection_foreach (state->sv,
- (GnmSelectionFunc)c_fmt_dialog_condition_setter,
+
+ sv_selection_foreach (state->sv,
+ (GnmSelectionFunc)c_fmt_dialog_condition_setter,
state);
} else {
- sv_selection_foreach (state->sv,
- (GnmSelectionFunc)c_fmt_dialog_condition_setter_tiled,
+ sv_selection_foreach (state->sv,
+ (GnmSelectionFunc)c_fmt_dialog_condition_setter_tiled,
state);
}
cmd_generic_with_size (WORKBOOK_CONTROL (state->wbcg), cmd_label,
@@ -675,7 +675,7 @@ c_fmt_dialog_apply_add_choice (CFormatState *state, GnmStyleCond *cond, gboolean
if (!add) {
GtkTreeIter iter;
if (gtk_tree_selection_get_selected (state->selection, NULL, &iter)) {
- GtkTreePath *path = gtk_tree_model_get_path
+ GtkTreePath *path = gtk_tree_model_get_path
(GTK_TREE_MODEL (state->model), &iter);
gint *ind = gtk_tree_path_get_indices (path);
if (ind) {
@@ -696,7 +696,7 @@ c_fmt_dialog_apply_add_choice (CFormatState *state, GnmStyleCond *cond, gboolean
state->action.new_style = NULL;
c_fmt_dialog_load (state);
- }
+ }
}
static void
@@ -705,7 +705,7 @@ cb_c_fmt_dialog_clear_clicked (G_GNUC_UNUSED GtkButton *button, CFormatState *st
state->action.new_style = gnm_style_new ();
gnm_style_set_conditions (state->action.new_style, NULL);
state->action.existing_conds_only = TRUE;
-
+
c_fmt_dialog_set_conditions (state, _("Clear conditional formatting"));
gnm_style_unref (state->action.new_style);
@@ -722,22 +722,22 @@ cb_c_fmt_dialog_remove_clicked (GtkButton *button, CFormatState *state)
else {
GtkTreeIter iter;
if (gtk_tree_selection_get_selected (state->selection, NULL, &iter)) {
- GtkTreePath *path = gtk_tree_model_get_path
+ GtkTreePath *path = gtk_tree_model_get_path
(GTK_TREE_MODEL (state->model), &iter);
gint *ind = gtk_tree_path_get_indices (path);
if (ind) {
GnmStyleConditions *sc;
- sc = gnm_style_conditions_dup
+ sc = gnm_style_conditions_dup
(gnm_style_get_conditions (state->style));
if (sc != NULL) {
gnm_style_conditions_delete (sc, *ind);
state->action.new_style = gnm_style_new ();
- gnm_style_set_conditions
+ gnm_style_set_conditions
(state->action.new_style, sc);
state->action.existing_conds_only = TRUE;
-
- c_fmt_dialog_set_conditions
- (state,
+
+ c_fmt_dialog_set_conditions
+ (state,
_("Remove condition from conditional "
"formatting"));
@@ -764,12 +764,12 @@ cb_c_fmt_dialog_expand_clicked (G_GNUC_UNUSED GtkButton *button, CFormatState *s
-1);
if (sc != NULL) {
state->action.new_style = gnm_style_new ();
- gnm_style_set_conditions
+ gnm_style_set_conditions
(state->action.new_style, sc);
state->action.existing_conds_only = FALSE;
-
- c_fmt_dialog_set_conditions
- (state,
+
+ c_fmt_dialog_set_conditions
+ (state,
_("Expand conditional formatting"));
gnm_style_unref (state->action.new_style);
@@ -820,7 +820,7 @@ c_fmt_dialog_conditions_page_load_cond (CFormatState *state, GnmStyleCond const
gtk_tree_store_set (state->model, &iter1, CONDITIONS_RANGE, NULL,
CONDITIONS_COND,
_("If the cell content is between these "
- "two values, a special style is used."),
+ "two values, a special style is used."),
CONDITIONS_REFERENCE, NULL, -1);
c_fmt_dialog_conditions_page_load_cond_double_f (state, cond, &iter1);
break;
@@ -828,7 +828,7 @@ c_fmt_dialog_conditions_page_load_cond (CFormatState *state, GnmStyleCond const
gtk_tree_store_set (state->model, &iter1, CONDITIONS_RANGE, NULL,
CONDITIONS_COND,
_("If the cell content is not between these"
- " two values, a special style is used."),
+ " two values, a special style is used."),
CONDITIONS_REFERENCE, NULL, -1);
c_fmt_dialog_conditions_page_load_cond_double_f (state, cond, &iter1);
break;
@@ -836,7 +836,7 @@ c_fmt_dialog_conditions_page_load_cond (CFormatState *state, GnmStyleCond const
gtk_tree_store_set (state->model, &iter1, CONDITIONS_RANGE, NULL,
CONDITIONS_COND,
_("If the cell content is equal to this value"
- ", a special style is used."),
+ ", a special style is used."),
CONDITIONS_REFERENCE, NULL, -1);
c_fmt_dialog_conditions_page_load_cond_single_f (state, cond->texpr[0], &iter1);
break;
@@ -844,7 +844,7 @@ c_fmt_dialog_conditions_page_load_cond (CFormatState *state, GnmStyleCond const
gtk_tree_store_set (state->model, &iter1, CONDITIONS_RANGE, NULL,
CONDITIONS_COND,
_("If the cell content is not equal to this value"
- ", a special style is used."),
+ ", a special style is used."),
CONDITIONS_REFERENCE, NULL, -1);
c_fmt_dialog_conditions_page_load_cond_single_f (state, cond->texpr[0], &iter1);
break;
@@ -859,7 +859,7 @@ c_fmt_dialog_conditions_page_load_cond (CFormatState *state, GnmStyleCond const
gtk_tree_store_set (state->model, &iter1, CONDITIONS_RANGE, NULL,
CONDITIONS_COND,
_("If the cell content is < this value, a "
- "special style is used."),
+ "special style is used."),
CONDITIONS_REFERENCE, NULL, -1);
c_fmt_dialog_conditions_page_load_cond_single_f (state, cond->texpr[0], &iter1);
break;
@@ -867,7 +867,7 @@ c_fmt_dialog_conditions_page_load_cond (CFormatState *state, GnmStyleCond const
gtk_tree_store_set (state->model, &iter1, CONDITIONS_RANGE, NULL,
CONDITIONS_COND,
_("If the cell content is \xe2\x89\xa7 this "
- "value, a special style is used."),
+ "value, a special style is used."),
CONDITIONS_REFERENCE, NULL, -1);
c_fmt_dialog_conditions_page_load_cond_single_f (state, cond->texpr[0], &iter1);
@@ -876,7 +876,7 @@ c_fmt_dialog_conditions_page_load_cond (CFormatState *state, GnmStyleCond const
gtk_tree_store_set (state->model, &iter1, CONDITIONS_RANGE, NULL,
CONDITIONS_COND,
_("If the cell content is \xe2\x89\xa6 this "
- "value, a special style is used."),
+ "value, a special style is used."),
CONDITIONS_REFERENCE, NULL, -1);
c_fmt_dialog_conditions_page_load_cond_single_f (state, cond->texpr[0], &iter1);
break;
@@ -884,7 +884,7 @@ c_fmt_dialog_conditions_page_load_cond (CFormatState *state, GnmStyleCond const
case GNM_STYLE_COND_CUSTOM:
gtk_tree_store_set (state->model, &iter1, CONDITIONS_RANGE, NULL,
CONDITIONS_COND,
- _("If this formula evaluates to TRUE, a special style is used."),
+ _("If this formula evaluates to TRUE, a special style is used."),
CONDITIONS_REFERENCE, NULL, -1);
c_fmt_dialog_conditions_page_load_cond_single_f (state, cond->texpr[0], &iter1);
break;
@@ -892,7 +892,7 @@ c_fmt_dialog_conditions_page_load_cond (CFormatState *state, GnmStyleCond const
gtk_tree_store_set (state->model, &iter1, CONDITIONS_RANGE, NULL,
CONDITIONS_COND,
_("If the cell content contains this string"
- ", a special style is used."),
+ ", a special style is used."),
CONDITIONS_REFERENCE, NULL, -1);
c_fmt_dialog_conditions_page_load_cond_single_f (state, cond->texpr[0], &iter1);
break;
@@ -900,7 +900,7 @@ c_fmt_dialog_conditions_page_load_cond (CFormatState *state, GnmStyleCond const
gtk_tree_store_set (state->model, &iter1, CONDITIONS_RANGE, NULL,
CONDITIONS_COND,
_("If the cell content does not contain this string"
- ", a special style is used."),
+ ", a special style is used."),
CONDITIONS_REFERENCE, NULL, -1);
c_fmt_dialog_conditions_page_load_cond_single_f (state, cond->texpr[0], &iter1);
break;
@@ -908,7 +908,7 @@ c_fmt_dialog_conditions_page_load_cond (CFormatState *state, GnmStyleCond const
gtk_tree_store_set (state->model, &iter1, CONDITIONS_RANGE, NULL,
CONDITIONS_COND,
_("If the cell content begins with this string"
- ", a special style is used."),
+ ", a special style is used."),
CONDITIONS_REFERENCE, NULL, -1);
c_fmt_dialog_conditions_page_load_cond_single_f (state, cond->texpr[0], &iter1);
break;
@@ -923,7 +923,7 @@ c_fmt_dialog_conditions_page_load_cond (CFormatState *state, GnmStyleCond const
gtk_tree_store_set (state->model, &iter1, CONDITIONS_RANGE, NULL,
CONDITIONS_COND,
_("If the cell content ends with this string"
- ", a special style is used."),
+ ", a special style is used."),
CONDITIONS_REFERENCE, NULL, -1);
c_fmt_dialog_conditions_page_load_cond_single_f (state, cond->texpr[0], &iter1);
break;
@@ -931,7 +931,7 @@ c_fmt_dialog_conditions_page_load_cond (CFormatState *state, GnmStyleCond const
gtk_tree_store_set (state->model, &iter1, CONDITIONS_RANGE, NULL,
CONDITIONS_COND,
_("If the cell content does not end "
- "with this string, a special style is used."),
+ "with this string, a special style is used."),
CONDITIONS_REFERENCE, NULL, -1);
c_fmt_dialog_conditions_page_load_cond_single_f (state, cond->texpr[0], &iter1);
break;
@@ -945,27 +945,27 @@ c_fmt_dialog_conditions_page_load_cond (CFormatState *state, GnmStyleCond const
gtk_tree_store_set (state->model, &iter1, CONDITIONS_RANGE, NULL,
CONDITIONS_COND,
_("If the cell does not contain an error value"
- ", a special style is used."),
+ ", a special style is used."),
CONDITIONS_REFERENCE, NULL, -1);
break;
case GNM_STYLE_COND_CONTAINS_BLANKS:
gtk_tree_store_set (state->model, &iter1, CONDITIONS_RANGE, NULL,
CONDITIONS_COND,
_("If the cell content "
- "contains blanks, a special style is used."),
+ "contains blanks, a special style is used."),
CONDITIONS_REFERENCE, NULL, -1);
break;
case GNM_STYLE_COND_NOT_CONTAINS_BLANKS:
gtk_tree_store_set (state->model, &iter1, CONDITIONS_RANGE, NULL,
CONDITIONS_COND,
_("If the cell content does not contain blanks"
- ", a special style is used."),
+ ", a special style is used."),
CONDITIONS_REFERENCE, NULL, -1);
break;
default:
gtk_tree_store_set (state->model, &iter1, CONDITIONS_RANGE, NULL,
CONDITIONS_COND,
- _("This is an unknown condition type."),
+ _("This is an unknown condition type."),
CONDITIONS_REFERENCE, NULL, -1);
return;
}
@@ -988,7 +988,7 @@ c_fmt_dialog_conditions_page_load_conditions (GnmStyle *style, char const *range
iter = &iter1;
gtk_tree_store_append (state->model, iter, NULL);
gtk_tree_store_set (state->model, iter, CONDITIONS_RANGE, range,
- CONDITIONS_COND, NULL,
+ CONDITIONS_COND, NULL,
CONDITIONS_REFERENCE, sc, -1);
}
for (i = 0 ; i < conds->len ; i++)
@@ -1081,7 +1081,7 @@ c_fmt_dialog_load (CFormatState *state)
(void) sv_selection_foreach (state->sv,
c_fmt_dialog_condition_collector, state);
}
- gtk_tree_view_column_queue_resize
+ gtk_tree_view_column_queue_resize
(gtk_tree_view_get_column (state->treeview, CONDITIONS_RANGE));
c_fmt_dialog_set_sensitive (state);
}
@@ -1125,7 +1125,7 @@ c_fmt_dialog_init_editor_page (CFormatState *state)
state->editor.combo = go_gtk_builder_get_widget (state->gui, "condition-combo");
table = GTK_TABLE (go_gtk_builder_get_widget (state->gui, "condition-table"));
state->editor.expr_x = GTK_WIDGET (gnm_expr_entry_new (state->wbcg, TRUE));
- gtk_table_attach (table, state->editor.expr_x, 1, 2, 2, 3,
+ gtk_table_attach (table, state->editor.expr_x, 1, 2, 2, 3,
GTK_EXPAND | GTK_FILL, GTK_SHRINK | GTK_FILL, 0, 0);
gtk_widget_show(state->editor.expr_x);
gnm_expr_entry_set_flags (GNM_EXPR_ENTRY (state->editor.expr_x),
@@ -1133,17 +1133,17 @@ c_fmt_dialog_init_editor_page (CFormatState *state)
GNM_EE_MASK);
state->editor.expr_y = GTK_WIDGET (gnm_expr_entry_new (state->wbcg, TRUE));
- gtk_table_attach (table, state->editor.expr_y, 1, 2, 3, 4,
+ gtk_table_attach (table, state->editor.expr_y, 1, 2, 3, 4,
GTK_EXPAND | GTK_FILL, GTK_SHRINK | GTK_FILL, 0, 0);
gtk_widget_show(state->editor.expr_y);
gnm_expr_entry_set_flags (GNM_EXPR_ENTRY (state->editor.expr_y),
GNM_EE_CONSTANT_ALLOWED,
GNM_EE_MASK);
- state->editor.typestore = GTK_LIST_STORE (gtk_combo_box_get_model
+ state->editor.typestore = GTK_LIST_STORE (gtk_combo_box_get_model
(GTK_COMBO_BOX (state->editor.combo)));
c_fmt_dialog_chooser_load_combo (state);
-
+
state->editor.style_label = go_gtk_builder_get_widget (state->gui, "style-label");
gtk_label_set_text (GTK_LABEL (state->editor.style_label), _("(undefined)"));
@@ -1170,7 +1170,7 @@ c_fmt_dialog_init_editor_page (CFormatState *state)
g_signal_connect (G_OBJECT (gnm_expr_entry_get_entry (GNM_EXPR_ENTRY (state->editor.expr_y))),
"focus-out-event",
G_CALLBACK (cb_c_fmt_dialog_chooser_entry_changed), state);
-
+
}
static void
@@ -1197,7 +1197,7 @@ c_fmt_dialog_init_conditions_page (CFormatState *state)
G_TYPE_STRING,
G_TYPE_STRING,
G_TYPE_OBJECT);
- state->treeview = GTK_TREE_VIEW (go_gtk_builder_get_widget
+ state->treeview = GTK_TREE_VIEW (go_gtk_builder_get_widget
(state->gui, "conditions_treeview"));
gtk_tree_view_set_fixed_height_mode (state->treeview, FALSE);
gtk_tree_view_set_model (state->treeview, GTK_TREE_MODEL (state->model));
@@ -1222,8 +1222,8 @@ c_fmt_dialog_init_conditions_page (CFormatState *state)
hl = GTK_LABEL (go_gtk_builder_get_widget (state->gui, "header-label"));
gtk_label_set_ellipsize (hl, PANGO_ELLIPSIZE_END);
str = g_string_new (_("Editing conditional formatting: "));
- sv_selection_foreach (state->sv,
- (GnmSelectionFunc)cb_c_format_dialog_range,
+ sv_selection_foreach (state->sv,
+ (GnmSelectionFunc)cb_c_format_dialog_range,
str);
g_string_truncate (str, str->len -2);
gtk_label_set_text(hl, str->str);
diff --git a/src/dialogs/dialog-cell-format.c b/src/dialogs/dialog-cell-format.c
index 17a1867..dfbedd5 100644
--- a/src/dialogs/dialog-cell-format.c
+++ b/src/dialogs/dialog-cell-format.c
@@ -212,7 +212,7 @@ typedef struct _FormatState {
} input_msg;
struct {
gboolean is_selector;
- GtkWindow *w;
+ GtkWindow *w;
gpointer closure;
} style_selector;
@@ -2024,14 +2024,14 @@ cb_fmt_dialog_dialog_buttons (GtkWidget *btn, FormatState *state)
for (i = GNM_STYLE_BORDER_TOP; i <= GNM_STYLE_BORDER_DIAG; i++) {
GnmBorder *b = border_get_mstyle (state, i);
if (b)
- gnm_style_set_border
- (state->result,
- MSTYLE_BORDER_TOP +
+ gnm_style_set_border
+ (state->result,
+ MSTYLE_BORDER_TOP +
(int)(i - GNM_STYLE_BORDER_TOP),
b);
}
gnm_style_merge (style, state->result);
- dialog_cell_format_style_added
+ dialog_cell_format_style_added
(state->style_selector.closure,
style);
gnm_style_unref (state->result);
@@ -2530,7 +2530,7 @@ dialog_cell_format (WBCGtk *wbcg, FormatDialogPosition_t pageno)
*/
void
-dialog_cell_format_select_style (WBCGtk *wbcg, gint pages,
+dialog_cell_format_select_style (WBCGtk *wbcg, gint pages,
GtkWindow *w,
GnmStyle *style, gpointer closure)
{
@@ -2558,7 +2558,7 @@ dialog_cell_format_select_style (WBCGtk *wbcg, gint pages,
fmt_dialog_impl (state, FD_BACKGROUND);
for (i = 0; i <= FD_LAST; i++) {
- GtkWidget *widget = gtk_notebook_get_nth_page
+ GtkWidget *widget = gtk_notebook_get_nth_page
(state->notebook, i);
if (widget != NULL && !((1<<i) & pages))
gtk_widget_hide (widget);
@@ -2566,7 +2566,7 @@ dialog_cell_format_select_style (WBCGtk *wbcg, gint pages,
gtk_widget_hide (state->apply_button);
- go_gtk_window_set_transient (GTK_WINDOW (w),
+ go_gtk_window_set_transient (GTK_WINDOW (w),
GTK_WINDOW (state->dialog));
gtk_window_set_modal (GTK_WINDOW (state->dialog), TRUE);
gtk_widget_show (GTK_WIDGET (state->dialog));
diff --git a/src/dialogs/dialog-doc-metadata.c b/src/dialogs/dialog-doc-metadata.c
index 2c19b30..4a1eff2 100644
--- a/src/dialogs/dialog-doc-metadata.c
+++ b/src/dialogs/dialog-doc-metadata.c
@@ -148,7 +148,7 @@ typedef struct {
} DialogDocMetaData;
-static gchar *dialog_doc_metadata_get_prop_val (DialogDocMetaData *state, char const *prop_name,
+static gchar *dialog_doc_metadata_get_prop_val (DialogDocMetaData *state, char const *prop_name,
GValue *prop_value);
static gboolean cb_dialog_doc_metadata_ppt_changed (G_GNUC_UNUSED GtkEntry *entry,
@@ -224,15 +224,15 @@ dialog_doc_metadata_get_value_type_from_name (gchar const *name, GType def)
g_hash_table_insert (dialog_doc_metadata_name_to_type,
(gpointer)map_vector[i],
GINT_TO_POINTER (GSF_DOCPROP_VECTOR_TYPE));
-
+
i = G_N_ELEMENTS (map_timestamps);
while (i-- > 0)
g_hash_table_insert (dialog_doc_metadata_name_to_type,
(gpointer)map_timestamps[i],
GINT_TO_POINTER (GSF_TIMESTAMP_TYPE));
-
+
}
-
+
res = g_hash_table_lookup (dialog_doc_metadata_name_to_type, name);
if (res != NULL)
@@ -329,12 +329,12 @@ dialog_doc_metadata_transform_str_to_float (const GValue *string_value,
g_return_if_fail (G_VALUE_HOLDS_STRING (string_value));
g_return_if_fail (G_VALUE_HOLDS_FLOAT (float_value));
-
+
str = g_value_get_string (string_value);
conversion = format_match_number (str, NULL, NULL);
if (conversion) {
x = value_get_as_float (conversion);
- value_release (conversion);
+ value_release (conversion);
} else
x = 0.;
@@ -351,7 +351,7 @@ dialog_doc_metadata_transform_str_to_boolean (const GValue *string_value,
g_return_if_fail (G_VALUE_HOLDS_STRING (string_value));
g_return_if_fail (G_VALUE_HOLDS_BOOLEAN (b_value));
-
+
str = g_value_get_string (string_value);
conversion = format_match_number (str, NULL, NULL);
if (conversion) {
@@ -418,10 +418,10 @@ time2str (time_t t)
char buffer[4000];
gsize len;
char const *format = "%c";
-
+
if (t == -1)
return NULL;
-
+
len = strftime (buffer, sizeof (buffer), format, localtime (&t));
if (len == 0)
return NULL;
@@ -516,13 +516,13 @@ gnm_docprop_vector_as_string (GsfDocPropVector *vector)
num_values = gva->n_values;
rstring = g_string_sized_new (num_values * 8);
-
+
for (i = 0; i < num_values; i++) {
char *str;
GValue *v;
-
+
v = g_value_array_get_nth (gva, i);
-
+
if (G_VALUE_TYPE(v) == G_TYPE_STRING)
str = g_strescape (g_value_get_string (v), "");
else {
@@ -771,7 +771,7 @@ dialog_doc_metadata_add_prop (DialogDocMetaData *state,
const gchar *link,
GType val_type)
{
- gboolean editable = (val_type != G_TYPE_INVALID)
+ gboolean editable = (val_type != G_TYPE_INVALID)
&& (val_type != GSF_DOCPROP_VECTOR_TYPE);
if (value == NULL)
value = "";
@@ -859,7 +859,7 @@ dialog_doc_metadata_set_gsf_prop (DialogDocMetaData *state,
if (value != NULL && *value == 0)
value = NULL;
if ((value == NULL) && (link == NULL)) {
- if ((existing_prop == NULL) ||
+ if ((existing_prop == NULL) ||
((existing_value == NULL) && (existing_link == NULL)))
return G_TYPE_INVALID;
else {
@@ -881,7 +881,7 @@ dialog_doc_metadata_set_gsf_prop (DialogDocMetaData *state,
link_changed = TRUE;
else
link_changed = (0 != strcmp (link, existing_link));
-
+
if (existing_value == NULL)
value_changed = (value != NULL);
else if (G_VALUE_HOLDS_STRING (existing_value) && (type == 0 || type == G_TYPE_STRING)) {
@@ -956,7 +956,7 @@ dialog_doc_metadata_set_prop (DialogDocMetaData *state,
g_return_if_fail (state->metadata != NULL);
- val_type = dialog_doc_metadata_set_gsf_prop (state, prop_name, prop_value,
+ val_type = dialog_doc_metadata_set_gsf_prop (state, prop_name, prop_value,
link_value, type);
/* Due to changes in type, prop_value may have changed */
@@ -985,13 +985,13 @@ dialog_doc_metadata_set_prop (DialogDocMetaData *state,
value);
if (strcmp (prop_name, g_value_get_string (value)) == 0) {
- if (updated_prop != NULL) {
+ if (updated_prop != NULL) {
/* Set new value */
gtk_tree_store_set (state->properties_store,
&tree_iter,
1, new_prop_value,
-1);
-
+
if (link_value != NULL)
gtk_tree_store_set (state->properties_store,
&tree_iter,
@@ -1187,21 +1187,21 @@ dialog_doc_metadata_update_keywords_changed (DialogDocMetaData *state)
(GTK_TREE_MODEL (state->key_store), &iter)) {
do {
GValue *value = g_new0 (GValue, 1);
- gtk_tree_model_get_value
+ gtk_tree_model_get_value
(GTK_TREE_MODEL (state->key_store), &iter,
0, value);
gsf_docprop_vector_append (vector, value);
g_value_unset (value);
g_free (value);
- } while (gtk_tree_model_iter_next
+ } while (gtk_tree_model_iter_next
(GTK_TREE_MODEL (state->key_store), &iter));
}
g_value_set_object (&val, vector);
g_object_unref (vector);
- dialog_doc_metadata_set_prop
- (state, GSF_META_NAME_KEYWORDS,
- dialog_doc_metadata_get_prop_val (state, GSF_META_NAME_KEYWORDS, &val),
+ dialog_doc_metadata_set_prop
+ (state, GSF_META_NAME_KEYWORDS,
+ dialog_doc_metadata_get_prop_val (state, GSF_META_NAME_KEYWORDS, &val),
NULL, GSF_DOCPROP_VECTOR_TYPE);
g_value_unset (&val);
@@ -1211,8 +1211,8 @@ static void
cb_dialog_doc_metadata_keywords_sel_changed (GtkTreeSelection *treeselection,
DialogDocMetaData *state)
{
- gtk_widget_set_sensitive
- (GTK_WIDGET (state->key_remove_button),
+ gtk_widget_set_sensitive
+ (GTK_WIDGET (state->key_remove_button),
gtk_tree_selection_get_selected (treeselection, NULL, NULL));
}
@@ -1230,8 +1230,8 @@ dialog_doc_metadata_update_keyword_list (DialogDocMetaData *state, GsfDocProp *p
if (array != NULL) {
for (i = 0; i < array->n_values; i++) {
GValue *val = g_value_array_get_nth (array, i);
- gtk_list_store_insert_with_values
- (state->key_store, NULL, G_MAXINT,
+ gtk_list_store_insert_with_values
+ (state->key_store, NULL, G_MAXINT,
0, g_value_get_string (val), -1);
}
}
@@ -1241,22 +1241,22 @@ dialog_doc_metadata_update_keyword_list (DialogDocMetaData *state, GsfDocProp *p
cb_dialog_doc_metadata_keywords_sel_changed (sel, state);
}
-static void
+static void
cb_dialog_doc_metadata_keywords_add_clicked (GtkWidget *w,
DialogDocMetaData *state)
{
- gtk_list_store_insert_with_values (state->key_store, NULL, G_MAXINT,
+ gtk_list_store_insert_with_values (state->key_store, NULL, G_MAXINT,
0, "<?>", -1);
dialog_doc_metadata_update_keywords_changed (state);
}
-static void
+static void
cb_dialog_doc_metadata_keywords_remove_clicked (GtkWidget *w,
DialogDocMetaData *state)
{
GtkTreeIter iter;
GtkTreeSelection *sel = gtk_tree_view_get_selection (state->key_tree_view);
-
+
if (gtk_tree_selection_get_selected (sel, NULL, &iter)) {
gtk_list_store_remove (state->key_store, &iter);
dialog_doc_metadata_update_keywords_changed (state);
@@ -1291,7 +1291,7 @@ dialog_doc_metadata_init_keywords_page (DialogDocMetaData *state)
GtkTreeViewColumn *column;
GtkCellRenderer *renderer;
GtkTreeSelection *sel;
-
+
g_return_if_fail (state->metadata != NULL);
renderer = gtk_cell_renderer_text_new ();
@@ -1310,7 +1310,7 @@ dialog_doc_metadata_init_keywords_page (DialogDocMetaData *state)
"changed",
G_CALLBACK (cb_dialog_doc_metadata_keywords_sel_changed),
state);
-
+
g_signal_connect (G_OBJECT (state->key_add_button),
"clicked",
G_CALLBACK (cb_dialog_doc_metadata_keywords_add_clicked),
@@ -1338,12 +1338,12 @@ cb_dialog_doc_metadata_value_edited (GtkCellRendererText *renderer,
DialogDocMetaData *state)
{
GtkTreeIter iter;
- if (gtk_tree_model_get_iter_from_string
+ if (gtk_tree_model_get_iter_from_string
(GTK_TREE_MODEL (state->properties_store), &iter, path)) {
gchar *prop_name;
gchar *link_value;
GType type;
-
+
gtk_tree_model_get (GTK_TREE_MODEL (state->properties_store),
&iter,
0, &prop_name,
@@ -1377,11 +1377,11 @@ cb_dialog_doc_metadata_add_clicked (GtkWidget *w,
if (gtk_combo_box_get_active_iter (state->ppt_type, &filter_iter)) {
GtkTreeIter child_iter;
- gtk_tree_model_filter_convert_iter_to_child_iter
+ gtk_tree_model_filter_convert_iter_to_child_iter
(state->type_store_filter, &child_iter, &filter_iter);
- gtk_tree_model_get (GTK_TREE_MODEL (state->type_store), &child_iter,
+ gtk_tree_model_get (GTK_TREE_MODEL (state->type_store), &child_iter,
1, &t, -1);
- } else
+ } else
t = dialog_doc_metadata_get_value_type_from_name (name_trimmed, G_TYPE_STRING);
dialog_doc_metadata_set_prop (state, name_trimmed, value, NULL, t);
@@ -1548,7 +1548,7 @@ cb_dialog_doc_metadata_tree_prop_selected (GtkTreeSelection *selection,
gboolean selected;
gchar const *text = "";
- g_return_if_fail (state->metadata != NULL);
+ g_return_if_fail (state->metadata != NULL);
selected = gtk_tree_selection_get_selected (selection, NULL, &iter);
@@ -1641,13 +1641,13 @@ dialog_doc_metadata_populate_tree_view (gchar *name,
link_value = (char *) gsf_doc_prop_get_link (prop);
- dialog_doc_metadata_add_prop
+ dialog_doc_metadata_add_prop
(state,
gsf_doc_prop_get_name (prop),
str_value == NULL ? "" : str_value,
link_value == NULL ? "" : link_value,
dialog_doc_metadata_get_value_type (value));
-
+
dialog_doc_metadata_update_prop (state, gsf_doc_prop_get_name (prop), str_value, prop);
g_free (str_value);
@@ -1670,7 +1670,7 @@ dialog_doc_metadata_show_this_type (GtkTreeModel *model,
gpointer data)
{
GType t, type = GPOINTER_TO_INT (data);
-
+
gtk_tree_model_get (model, iter, 1, &t, -1);
gtk_list_store_set (GTK_LIST_STORE (model), iter, 2, t == type, -1);
return FALSE;
@@ -1701,8 +1701,8 @@ cb_dialog_doc_metadata_ppt_changed (G_GNUC_UNUSED GtkEntry *entry,
if (enable) {
prop = gsf_doc_meta_data_lookup (state->metadata, name_trimmed);
if (prop != NULL) {
- str = g_strdup_printf
- (_("A document property with the name \'%s\' already exists."),
+ str = g_strdup_printf
+ (_("A document property with the name \'%s\' already exists."),
name_trimmed);
enable = FALSE;
}
@@ -1715,7 +1715,7 @@ cb_dialog_doc_metadata_ppt_changed (G_GNUC_UNUSED GtkEntry *entry,
}
static void
-cb_dialog_doc_metadata_ppt_type_changed (G_GNUC_UNUSED GtkComboBox *widget,
+cb_dialog_doc_metadata_ppt_type_changed (G_GNUC_UNUSED GtkComboBox *widget,
DialogDocMetaData *state)
{
cb_dialog_doc_metadata_ppt_changed (NULL, NULL, state);
@@ -1741,7 +1741,7 @@ cb_dialog_doc_metadata_ppt_name_changed (G_GNUC_UNUSED GtkEntry *entry,
GType t = dialog_doc_metadata_get_value_type_from_name (name_trimmed, G_TYPE_INVALID);
if (t == GSF_DOCPROP_VECTOR_TYPE) {
- str = g_strdup_printf
+ str = g_strdup_printf
(_("Use the keywords tab to create this property."));
enable = FALSE;
}
@@ -1774,7 +1774,7 @@ cb_dialog_doc_metadata_ppt_name_changed (G_GNUC_UNUSED GtkEntry *entry,
}
}
g_free (name_trimmed);
-
+
if (enable)
return cb_dialog_doc_metadata_ppt_changed (NULL, NULL, state);
else {
@@ -1825,8 +1825,8 @@ dialog_doc_metadata_init_properties_page (DialogDocMetaData *state)
cell = gtk_cell_renderer_text_new();
gtk_cell_layout_pack_start(GTK_CELL_LAYOUT(state->ppt_type), cell, TRUE);
gtk_cell_layout_set_attributes(GTK_CELL_LAYOUT(state->ppt_type), cell, "text", 0, NULL);
-
- for (i = 0; i < G_N_ELEMENTS (ppt_types); i++)
+
+ for (i = 0; i < G_N_ELEMENTS (ppt_types); i++)
gtk_list_store_insert_with_values (state->type_store, NULL, G_MAXINT,
0, _(ppt_types[i].type_name),
1, ppt_types[i].type,
@@ -1850,7 +1850,7 @@ dialog_doc_metadata_init_properties_page (DialogDocMetaData *state)
gtk_tree_view_set_model (state->properties,
GTK_TREE_MODEL (state->properties_store));
- gtk_tree_sortable_set_sort_column_id (GTK_TREE_SORTABLE (state->properties_store),
+ gtk_tree_sortable_set_sort_column_id (GTK_TREE_SORTABLE (state->properties_store),
0, GTK_SORT_ASCENDING);
g_object_unref (state->properties_store);
diff --git a/src/dialogs/dialog-function-select.c b/src/dialogs/dialog-function-select.c
index 80259bd..ea24753 100644
--- a/src/dialogs/dialog-function-select.c
+++ b/src/dialogs/dialog-function-select.c
@@ -656,7 +656,7 @@ make_expr_example (Sheet *sheet, const char *text, gboolean localized)
(texpr, &ep, GNM_EXPR_EVAL_PERMIT_NON_SCALAR);
GOFormat const *format = auto_style_format_suggest (texpr, &ep);
char *vtxt = format_value (format, val, -1,
- workbook_date_conv
+ workbook_date_conv
(sheet->workbook));
go_format_unref (format);
diff --git a/src/dialogs/dialog-goto-cell.c b/src/dialogs/dialog-goto-cell.c
index d65afa5..c039254 100644
--- a/src/dialogs/dialog-goto-cell.c
+++ b/src/dialogs/dialog-goto-cell.c
@@ -113,11 +113,11 @@ dialog_goto_get_val (GotoState *state)
if (val == NULL) {
GnmParsePos pp;
- GnmNamedExpr *nexpr = expr_name_lookup
+ GnmNamedExpr *nexpr = expr_name_lookup
(parse_pos_init_sheet (&pp, sheet), text);
if (nexpr != NULL && !expr_name_is_placeholder (nexpr)) {
val = gnm_expr_top_get_range (nexpr->texpr);
- }
+ }
}
return val;
}
@@ -135,7 +135,7 @@ cb_dialog_goto_go_clicked (G_GNUC_UNUSED GtkWidget *button,
if (val == NULL)
return;
-
+
val->v_range.cell.b.row = val->v_range.cell.a.row + (rows - 1);
val->v_range.cell.b.col = val->v_range.cell.a.col + (cols - 1);
eval_pos_init_sheet (&ep, sheet);
@@ -167,7 +167,7 @@ cb_dialog_goto_update_sensitivity (G_GNUC_UNUSED GtkWidget *dummy,
cols = ssz->max_cols;
rows = ssz->max_rows;
- if (val->v_range.cell.a.sheet != NULL &&
+ if (val->v_range.cell.a.sheet != NULL &&
val->v_range.cell.b.sheet != NULL &&
val->v_range.cell.a.sheet != val->v_range.cell.b.sheet) {
ssz = gnm_sheet_get_size (sheet);
@@ -178,7 +178,7 @@ cb_dialog_goto_update_sensitivity (G_GNUC_UNUSED GtkWidget *dummy,
}
cols -= val->v_range.cell.a.col;
rows -= val->v_range.cell.a.row;
-
+
if (cols < 1) cols = 1;
if (rows < 1) rows = 1;
@@ -186,7 +186,7 @@ cb_dialog_goto_update_sensitivity (G_GNUC_UNUSED GtkWidget *dummy,
gtk_spin_button_set_range (state->spin_rows, 1, rows);
gtk_widget_set_sensitive (state->go_button, TRUE);
-
+
value_release (val);
} else
gtk_widget_set_sensitive (state->go_button, FALSE);
@@ -309,7 +309,7 @@ cb_sheet_added (Workbook *wb, GotoState *state)
static void
dialog_goto_load_selection (GotoState *state)
{
- SheetView *sv = wb_control_cur_sheet_view
+ SheetView *sv = wb_control_cur_sheet_view
(WORKBOOK_CONTROL (state->wbcg));
GnmRange const *first = selection_first_range (sv, NULL, NULL);
@@ -320,13 +320,13 @@ dialog_goto_load_selection (GotoState *state)
GString *str = g_string_new (NULL);
GnmParsePos pp;
GnmRangeRef rr;
-
+
out.accum = str;
out.pp = parse_pos_init_sheet (&pp, sv->sheet);
out.convs = sheet_get_conventions (sv->sheet);
- gnm_cellref_init (&rr.a, NULL, first->start.col,
+ gnm_cellref_init (&rr.a, NULL, first->start.col,
first->start.row, TRUE);
- gnm_cellref_init (&rr.b, NULL, first->start.col,
+ gnm_cellref_init (&rr.b, NULL, first->start.col,
first->start.row, TRUE);
rangeref_as_string (&out, &rr);
gtk_entry_set_text (state->goto_text, str->str);
@@ -365,9 +365,9 @@ dialog_goto_init (GotoState *state)
"changed",
G_CALLBACK (cb_dialog_goto_update_sensitivity), state);
- state->spin_rows = GTK_SPIN_BUTTON
+ state->spin_rows = GTK_SPIN_BUTTON
(go_gtk_builder_get_widget (state->gui, "spin-rows"));
- state->spin_cols = GTK_SPIN_BUTTON
+ state->spin_cols = GTK_SPIN_BUTTON
(go_gtk_builder_get_widget (state->gui, "spin-columns"));
/* Set-up treeview */
diff --git a/src/dialogs/dialog-printer-setup.c b/src/dialogs/dialog-printer-setup.c
index 4ca33df..a97d52a 100644
--- a/src/dialogs/dialog-printer-setup.c
+++ b/src/dialogs/dialog-printer-setup.c
@@ -157,13 +157,13 @@ struct _PrinterSetupState {
HFPreviewInfo *pi_footer;
/* Error Display */
- struct {
+ struct {
GtkListStore *store;
GtkWidget *combo;
} error_display;
/* Comment Display */
- struct {
+ struct {
GtkListStore *store;
GtkWidget *combo;
} comment_display;
@@ -740,7 +740,7 @@ margin_spin_configure (UnitInfo *target, PrinterSetupState *state,
}
static void
-cb_unit_selector_changed (G_GNUC_UNUSED GtkComboBox *widget,
+cb_unit_selector_changed (G_GNUC_UNUSED GtkComboBox *widget,
PrinterSetupState *state)
{
GtkTreeIter iter;
@@ -759,7 +759,7 @@ cb_unit_selector_changed (G_GNUC_UNUSED GtkComboBox *widget,
static gint
unit_sort_func (GtkTreeModel *model,
- GtkTreeIter *a, GtkTreeIter *b,
+ GtkTreeIter *a, GtkTreeIter *b,
G_GNUC_UNUSED gpointer user_data)
{
char *str_a;
@@ -1191,12 +1191,12 @@ static void
hf_insert_date_cb (GtkWidget *widget, HFCustomizeState *hf_state)
{
- hf_insert_hf_tag (hf_state, HF_FIELD_DATE,
+ hf_insert_hf_tag (hf_state, HF_FIELD_DATE,
g_object_get_data (G_OBJECT (widget), "options"));
}
static void
-hf_insert_custom_date_cb (G_GNUC_UNUSED GtkWidget *widget,
+hf_insert_custom_date_cb (G_GNUC_UNUSED GtkWidget *widget,
HFCustomizeState *hf_state)
{
char *format;
@@ -1211,12 +1211,12 @@ hf_insert_custom_date_cb (G_GNUC_UNUSED GtkWidget *widget,
static void
hf_insert_time_cb (GtkWidget *widget, HFCustomizeState *hf_state)
{
- hf_insert_hf_tag (hf_state, HF_FIELD_TIME,
+ hf_insert_hf_tag (hf_state, HF_FIELD_TIME,
g_object_get_data (G_OBJECT (widget), "options"));
}
static void
-hf_insert_custom_time_cb (G_GNUC_UNUSED GtkWidget *widget,
+hf_insert_custom_time_cb (G_GNUC_UNUSED GtkWidget *widget,
HFCustomizeState *hf_state)
{
char *format;
@@ -2193,7 +2193,7 @@ do_setup_error_display (PrinterSetupState *state)
{N_("Print as dashes"), PRINT_ERRORS_AS_DASHES},
{N_("Print as #N/A"), PRINT_ERRORS_AS_NA}
};
-
+
gint i;
GtkCellRenderer *cell;
gint item = PRINT_ERRORS_AS_DISPLAYED;
@@ -2210,7 +2210,7 @@ do_setup_error_display (PrinterSetupState *state)
}
cell = gtk_cell_renderer_text_new();
gtk_cell_layout_pack_start(GTK_CELL_LAYOUT(state->error_display.combo), cell, TRUE);
- gtk_cell_layout_set_attributes(GTK_CELL_LAYOUT(state->error_display.combo),
+ gtk_cell_layout_set_attributes(GTK_CELL_LAYOUT(state->error_display.combo),
cell, "text", 0, NULL);
if (gtk_tree_model_iter_nth_child
(GTK_TREE_MODEL (state->error_display.store), &iter, NULL, item))
@@ -2228,7 +2228,7 @@ do_setup_comment_display (PrinterSetupState *state)
{N_("Print in place"), PRINT_COMMENTS_IN_PLACE},
{N_("Print at end"), PRINT_COMMENTS_AT_END}
};
-
+
gint i;
GtkCellRenderer *cell;
gint item = PRINT_COMMENTS_NONE;
@@ -2319,12 +2319,12 @@ do_setup_page_info (PrinterSetupState *state)
GtkWidget *order;
state->error_display.combo = go_gtk_builder_get_widget (state->gui, "error-box");
- state->error_display.store = GTK_LIST_STORE (gtk_combo_box_get_model
+ state->error_display.store = GTK_LIST_STORE (gtk_combo_box_get_model
(GTK_COMBO_BOX (state->error_display.combo)));
do_setup_error_display (state);
state->comment_display.combo = go_gtk_builder_get_widget (state->gui, "comments-box");
- state->comment_display.store = GTK_LIST_STORE (gtk_combo_box_get_model
+ state->comment_display.store = GTK_LIST_STORE (gtk_combo_box_get_model
(GTK_COMBO_BOX (state->comment_display.combo)));
do_setup_comment_display (state);
@@ -2979,11 +2979,11 @@ do_fetch_page_info (PrinterSetupState *state)
pi->repeat_left = g_strdup (gnm_expr_entry_get_text (state->left_entry));
if (gtk_combo_box_get_active_iter (GTK_COMBO_BOX (state->error_display.combo), &iter))
- gtk_tree_model_get (GTK_TREE_MODEL (state->error_display.store), &iter,
+ gtk_tree_model_get (GTK_TREE_MODEL (state->error_display.store), &iter,
1, &(pi->error_display),
-1);
if (gtk_combo_box_get_active_iter (GTK_COMBO_BOX (state->comment_display.combo), &iter))
- gtk_tree_model_get (GTK_TREE_MODEL (state->comment_display.store), &iter,
+ gtk_tree_model_get (GTK_TREE_MODEL (state->comment_display.store), &iter,
1, &(pi->comment_placement),
-1);
}
diff --git a/src/func.c b/src/func.c
index 1a9fb29..e456701 100644
--- a/src/func.c
+++ b/src/func.c
@@ -411,11 +411,11 @@ function_dump_defs (char const *filename, int dump_type)
function_def_count_args (fd, &min, &max);
if (max == G_MAXINT)
- fprintf (output_file,
- "@SYNTAX=%s," UNICODE_ELLIPSIS ")\n",
+ fprintf (output_file,
+ "@SYNTAX=%s," UNICODE_ELLIPSIS ")\n",
syntax->str);
else
- fprintf (output_file, "@SYNTAX=%s)\n",
+ fprintf (output_file, "@SYNTAX=%s)\n",
syntax->str);
if (arg_desc->len > 0)
diff --git a/src/gnm-format.c b/src/gnm-format.c
index 43b4346..1647941 100644
--- a/src/gnm-format.c
+++ b/src/gnm-format.c
@@ -144,7 +144,7 @@ format_value_common (PangoLayout *layout, GString *str,
format,
val, type, sval, NULL,
col_width, date_conv, unicode_minus);
-
+
g_free (sval_free);
switch (err) {
@@ -197,7 +197,7 @@ gnm_format_layout (PangoLayout *layout,
*
**/
GOFormatNumberError
-format_value_gstring (GString *str,
+format_value_gstring (GString *str,
GOFormat const *format,
GnmValue const *value,
int col_width,
@@ -218,7 +218,7 @@ format_value_gstring (GString *str,
go_string_append_gstring (str, tmp_str);
g_string_free (tmp_str, TRUE);
}
-
+
return err;
}
@@ -232,7 +232,7 @@ format_value_gstring (GString *str,
*
**/
GOFormatNumberError
-format_value_layout (PangoLayout *layout,
+format_value_layout (PangoLayout *layout,
GOFormat const *format,
GnmValue const *value,
int col_width,
diff --git a/src/gui-clipboard.c b/src/gui-clipboard.c
index e8ec344..b98ed08 100644
--- a/src/gui-clipboard.c
+++ b/src/gui-clipboard.c
@@ -954,8 +954,8 @@ x_clipboard_get_cb (GtkClipboard *gclipboard, GtkSelectionData *selection_data,
char *name;
char *text;
- redo = sheet_clear_region_undo
- (sr,
+ redo = sheet_clear_region_undo
+ (sr,
CLEAR_VALUES|CLEAR_COMMENTS|CLEAR_RECALC_DEPS);
undo = clipboard_copy_range_undo (sheet, a);
name = undo_range_name (sheet, a);
diff --git a/src/gui-file.c b/src/gui-file.c
index 6208ebf..d111f11 100644
--- a/src/gui-file.c
+++ b/src/gui-file.c
@@ -252,7 +252,7 @@ gui_file_open (WBCGtk *wbcg, file_open_t type, char const *default_format)
GSList *fsavers = NULL, *fl;
for (; mimes; mimes = mimes->next) {
- GOFileSaver *fs = go_file_saver_for_mime_type
+ GOFileSaver *fs = go_file_saver_for_mime_type
(mimes->data);
if (fs != NULL)
fsavers = g_slist_prepend (fsavers, fs);
@@ -262,24 +262,24 @@ gui_file_open (WBCGtk *wbcg, file_open_t type, char const *default_format)
for (fl = fsavers; fl; fl = fl->next) {
GOFileSaver *fs = GO_FILE_SAVER (fl->data);
if ((go_file_saver_get_save_scope (fs)
- != GO_FILE_SAVE_RANGE) &&
+ != GO_FILE_SAVE_RANGE) &&
(go_file_saver_get_format_level (fs)
== GO_FILE_FL_AUTO)) {
- openers = g_list_prepend
+ openers = g_list_prepend
(openers, fo);
break;
}
}
break;
- case FILE_OPEN_IMPORT:
+ case FILE_OPEN_IMPORT:
{
gboolean is_open = FALSE;
for (fl = fsavers; fl; fl = fl->next) {
- GOFileSaver *fs = GO_FILE_SAVER
+ GOFileSaver *fs = GO_FILE_SAVER
(fl->data);
- if ((go_file_saver_get_save_scope
+ if ((go_file_saver_get_save_scope
(fs)
- != GO_FILE_SAVE_RANGE) &&
+ != GO_FILE_SAVE_RANGE) &&
(go_file_saver_get_format_level
(fs)
== GO_FILE_FL_AUTO)) {
@@ -288,7 +288,7 @@ gui_file_open (WBCGtk *wbcg, file_open_t type, char const *default_format)
}
}
if (!(is_open))
- openers = g_list_prepend
+ openers = g_list_prepend
(openers, fo);
break;
}
@@ -301,7 +301,7 @@ gui_file_open (WBCGtk *wbcg, file_open_t type, char const *default_format)
}
opener_default = file_opener_find_by_id (openers, default_format);
-
+
if (opener_default != 0)
title = (go_file_opener_get_description
(g_list_nth_data (openers, opener_default)));
@@ -375,7 +375,7 @@ gui_file_open (WBCGtk *wbcg, file_open_t type, char const *default_format)
filter = gnm_app_create_opener_filter (openers);
if (default_format != NULL) {
- if (0 == strcmp (default_format,
+ if (0 == strcmp (default_format,
"Gnumeric_stf:stf_assistant"))
filter_name = _("Text Files");
}
@@ -506,7 +506,7 @@ gui_file_save_as (WBCGtk *wbcg, WorkbookView *wb_view, file_save_as_t type,
Workbook *wb;
WBCGtk *wbcg2;
#ifndef GNM_USE_HILDON
- char const *title = (type == FILE_SAVE_AS_SAVE) ? _("Save the current workbook as")
+ char const *title = (type == FILE_SAVE_AS_SAVE) ? _("Save the current workbook as")
: _("Export the current workbook or sheet to");
#endif
@@ -515,12 +515,12 @@ gui_file_save_as (WBCGtk *wbcg, WorkbookView *wb_view, file_save_as_t type,
wb = wb_view_get_workbook (wb_view);
wbcg2 = wbcg_find_for_workbook (wb, wbcg, NULL, NULL);
- for (l = go_get_file_savers (); l; l = l->next)
+ for (l = go_get_file_savers (); l; l = l->next)
switch (type) {
case FILE_SAVE_AS_SAVE:
if ((l->data == NULL) ||
((go_file_saver_get_save_scope (GO_FILE_SAVER (l->data))
- != GO_FILE_SAVE_RANGE) &&
+ != GO_FILE_SAVE_RANGE) &&
(go_file_saver_get_format_level (GO_FILE_SAVER (l->data))
== GO_FILE_FL_AUTO)))
savers = g_list_prepend (savers, l->data);
@@ -529,8 +529,8 @@ gui_file_save_as (WBCGtk *wbcg, WorkbookView *wb_view, file_save_as_t type,
default:
if ((l->data == NULL) ||
((go_file_saver_get_save_scope (GO_FILE_SAVER (l->data))
- != GO_FILE_SAVE_RANGE) &&
- (go_file_saver_get_format_level (GO_FILE_SAVER (l->data))
+ != GO_FILE_SAVE_RANGE) &&
+ (go_file_saver_get_format_level (GO_FILE_SAVER (l->data))
!= GO_FILE_FL_AUTO)))
savers = g_list_prepend (savers, l->data);
break;
@@ -614,7 +614,7 @@ gui_file_save_as (WBCGtk *wbcg, WorkbookView *wb_view, file_save_as_t type,
} else {
fs = workbook_get_file_exporter (wb);
if (!fs || g_list_find (savers, fs) == NULL)
- fs = go_file_saver_for_id (default_format ? default_format
+ fs = go_file_saver_for_id (default_format ? default_format
: "Gnumeric_html:latex_table");
}
@@ -712,7 +712,7 @@ gui_file_save (WBCGtk *wbcg, WorkbookView *wb_view)
}
if (wb->file_format_level < GO_FILE_FL_AUTO)
- return gui_file_save_as (wbcg, wb_view,
+ return gui_file_save_as (wbcg, wb_view,
FILE_SAVE_AS_SAVE, NULL);
else {
gboolean ok;
diff --git a/src/gui-file.h b/src/gui-file.h
index 37f98be..d8c49bd 100644
--- a/src/gui-file.h
+++ b/src/gui-file.h
@@ -16,11 +16,11 @@ typedef enum {
FILE_OPEN_IMPORT,
} file_open_t;
-gboolean gui_file_save_as (WBCGtk *wbcg, WorkbookView *wbv,
- file_save_as_t type,
+gboolean gui_file_save_as (WBCGtk *wbcg, WorkbookView *wbv,
+ file_save_as_t type,
char const *default_format);
gboolean gui_file_save (WBCGtk *wbcg, WorkbookView *wbv);
-void gui_file_open (WBCGtk *wbcg, file_open_t type,
+void gui_file_open (WBCGtk *wbcg, file_open_t type,
char const *default_format);
void gui_wb_view_show (WBCGtk *wbcg, WorkbookView *wbv);
gboolean gui_file_read (WBCGtk *wbcg, char const *file_name,
diff --git a/src/gui-util.c b/src/gui-util.c
index 1c387c7..1c3f044 100644
--- a/src/gui-util.c
+++ b/src/gui-util.c
@@ -757,7 +757,7 @@ gnm_load_pango_byte_to_char (gchar const *str, gint byte)
{
if (byte >= (gint) strlen (str))
return g_utf8_strlen (str, -1);
- return g_utf8_pointer_to_offset (str,
+ return g_utf8_pointer_to_offset (str,
g_utf8_prev_char (str + byte + 1));
}
@@ -776,7 +776,7 @@ gnm_load_pango_attributes_into_buffer (PangoAttrList *markup, GtkTextBuffer *bu
GtkTextIter start, end;
gtk_text_buffer_get_start_iter (buffer, &start);
gtk_text_buffer_get_end_iter (buffer, &end);
- str = str_retrieved = gtk_text_buffer_get_slice
+ str = str_retrieved = gtk_text_buffer_get_slice
(buffer, &start, &end, TRUE);
}
@@ -799,12 +799,12 @@ gnm_load_pango_attributes_into_buffer (PangoAttrList *markup, GtkTextBuffer *bu
char const *name;
pango_attr_iterator_range (iter, &start, &end);
- start = gnm_load_pango_byte_to_char
+ start = gnm_load_pango_byte_to_char
(str, start);
end = gnm_load_pango_byte_to_char (str, end);
- gtk_text_buffer_get_iter_at_offset
+ gtk_text_buffer_get_iter_at_offset
(buffer, &start_iter, start);
- gtk_text_buffer_get_iter_at_offset
+ gtk_text_buffer_get_iter_at_offset
(buffer, &end_iter, end);
for (ptr = attr; ptr != NULL; ptr = ptr->next) {
@@ -929,12 +929,12 @@ gnm_load_pango_attributes_into_buffer (PangoAttrList *markup, GtkTextBuffer *bu
}
}
pango_attr_iterator_range (iter, &start, &end);
- start = gnm_load_pango_byte_to_char
+ start = gnm_load_pango_byte_to_char
(str, start);
end = gnm_load_pango_byte_to_char (str, end);
- gtk_text_buffer_get_iter_at_offset
+ gtk_text_buffer_get_iter_at_offset
(buffer, &start_iter, start);
- gtk_text_buffer_get_iter_at_offset
+ gtk_text_buffer_get_iter_at_offset
(buffer, &end_iter, end);
gtk_text_buffer_apply_tag (buffer, tag, &start_iter, &end_iter);
go_slist_free_custom (attr, (GFreeFunc)pango_attribute_destroy);
diff --git a/src/parser.y b/src/parser.y
index 90b1ef7..91b5c77 100644
--- a/src/parser.y
+++ b/src/parser.y
@@ -1188,7 +1188,7 @@ yylex (void)
state->ptr = end;
if (invalid_sheet == ref.a.sheet) {
yylval.expr = register_expr_allocation
- (gnm_expr_new_constant
+ (gnm_expr_new_constant
(value_new_error_REF (NULL)));
return CONSTANT;
}
diff --git a/src/print-cell.c b/src/print-cell.c
index b8caa65..578c798 100644
--- a/src/print-cell.c
+++ b/src/print-cell.c
@@ -93,8 +93,8 @@ print_cell_gtk (GnmCell const *cell,
if (pinfo->error_display == PRINT_ERRORS_AS_NA)
t_cell->value = value_new_error_NA (NULL);
else
- t_cell->value = value_new_error
- (NULL,
+ t_cell->value = value_new_error
+ (NULL,
/* U+2014 U+200A U+2014 */
"\342\200\224\342\200\212\342\200\224");
rv100 = gnm_rendered_value_new (t_cell,
@@ -186,7 +186,7 @@ print_rectangle_gtk (cairo_t *context,
static void
print_cell_background_gtk (cairo_t *context,
- GnmStyle const *style,
+ GnmStyle const *style,
G_GNUC_UNUSED int col, G_GNUC_UNUSED int row,
double x, double y, double w, double h)
{
diff --git a/src/print-info.c b/src/print-info.c
index 0d6eefd..ac7e29a 100644
--- a/src/print-info.c
+++ b/src/print-info.c
@@ -1513,7 +1513,7 @@ gnm_page_breaks_clean (GnmPageBreaks *breaks)
}
void
-print_info_set_printtofile_uri (PrintInformation *pi,
+print_info_set_printtofile_uri (PrintInformation *pi,
gchar const *uri)
{
g_free (pi->printtofile_uri);
@@ -1521,12 +1521,12 @@ print_info_set_printtofile_uri (PrintInformation *pi,
}
void
-print_info_set_printtofile_from_settings (PrintInformation *pi,
+print_info_set_printtofile_from_settings (PrintInformation *pi,
GtkPrintSettings* settings,
gchar const *default_uri)
{
- char const *uri = gtk_print_settings_get
- (settings,
+ char const *uri = gtk_print_settings_get
+ (settings,
GTK_PRINT_SETTINGS_OUTPUT_URI);
if (strcmp (uri, default_uri) == 0)
print_info_set_printtofile_uri (pi, NULL);
@@ -1535,7 +1535,7 @@ print_info_set_printtofile_from_settings (PrintInformation *pi,
}
void
-print_info_set_from_settings (PrintInformation *pi,
+print_info_set_from_settings (PrintInformation *pi,
GtkPrintSettings* settings)
{
pi->print_range = gtk_print_settings_get_int_with_default
@@ -1544,17 +1544,17 @@ print_info_set_from_settings (PrintInformation *pi,
PRINT_ACTIVE_SHEET);
}
-PrintRange
+PrintRange
print_info_get_printrange (PrintInformation *pi)
{
print_info_load_defaults (pi);
return pi->print_range;
}
-void
+void
print_info_set_printrange (PrintInformation *pi, PrintRange pr)
{
- if (pr >= PRINT_ACTIVE_SHEET
+ if (pr >= PRINT_ACTIVE_SHEET
&& pr <= PRINT_SHEET_SELECTION_IGNORE_PRINTAREA)
pi->print_range = pr;
else
diff --git a/src/print-info.h b/src/print-info.h
index b55db2b..0af4162 100644
--- a/src/print-info.h
+++ b/src/print-info.h
@@ -174,14 +174,14 @@ void print_info_set_edge_to_above_footer (PrintInformation *pi,
double e_f);
void print_info_set_edge_to_below_header (PrintInformation *pi,
double e_h);
-void print_info_set_printtofile_uri (PrintInformation *pi,
+void print_info_set_printtofile_uri (PrintInformation *pi,
gchar const *uri);
-void print_info_set_printtofile_from_settings
- (PrintInformation *pi,
+void print_info_set_printtofile_from_settings
+ (PrintInformation *pi,
GtkPrintSettings *settings,
gchar const *default_uri);
-void print_info_set_from_settings
- (PrintInformation *pi,
+void print_info_set_from_settings
+ (PrintInformation *pi,
GtkPrintSettings *settings);
char const *print_info_get_printtofile_uri (PrintInformation *pi);
PrintRange print_info_get_printrange (PrintInformation *pi);
diff --git a/src/print.c b/src/print.c
index 95d24fd..d3047dd 100644
--- a/src/print.c
+++ b/src/print.c
@@ -196,7 +196,7 @@ gnm_print_sheet_objects (cairo_t *cr,
}
static void
-print_page_cells (G_GNUC_UNUSED GtkPrintContext *context,
+print_page_cells (G_GNUC_UNUSED GtkPrintContext *context,
G_GNUC_UNUSED PrintingInstance * pi,
cairo_t *cr, Sheet const *sheet, GnmRange *range,
double base_x, double base_y)
@@ -240,7 +240,7 @@ print_header_gtk (GtkPrintContext *context, cairo_t *cr,
}
static void
-print_page_col_headers (GtkPrintContext *context,
+print_page_col_headers (GtkPrintContext *context,
G_GNUC_UNUSED PrintingInstance * pi,
cairo_t *cr, Sheet const *sheet, GnmRange *range,
double row_header_width, double col_header_height)
@@ -285,7 +285,7 @@ print_page_col_headers (GtkPrintContext *context,
}
static void
-print_page_row_headers (GtkPrintContext *context,
+print_page_row_headers (GtkPrintContext *context,
G_GNUC_UNUSED PrintingInstance * pi,
cairo_t *cr, Sheet const *sheet, GnmRange *range,
double row_header_width, double col_header_height)
@@ -354,7 +354,7 @@ ensure_decoration_layout (GtkPrintContext *context)
* the rectangle.
*/
static void
-print_hf_element (GtkPrintContext *context, cairo_t *cr,
+print_hf_element (GtkPrintContext *context, cairo_t *cr,
G_GNUC_UNUSED Sheet const *sheet,
char const *format,
PangoAlignment side, gdouble width, gboolean align_bottom,
@@ -1575,11 +1575,11 @@ gnm_print_uri_change_extension (char const *uri, GtkPrintSettings* settings)
if (ext == NULL) {
ext = "pdf";
- gtk_print_settings_set (settings,
+ gtk_print_settings_set (settings,
GTK_PRINT_SETTINGS_OUTPUT_FILE_FORMAT,
ext);
}
-
+
base = g_path_get_basename (uri);
used_ext = strrchr (base, '.');
if (used_ext == NULL)
@@ -1637,7 +1637,7 @@ gnm_print_sheet (WorkbookControl *wbc, Sheet *sheet,
gint dr = print_info_get_printrange (sheet->print_info);
if (dr < 0 || dr >= (gint)G_N_ELEMENTS (pr_translator))
default_range = PRINT_ACTIVE_SHEET;
- else
+ else
default_range = pr_translator[dr];
}
gtk_print_settings_set_int (settings,
@@ -1650,18 +1650,18 @@ gnm_print_sheet (WorkbookControl *wbc, Sheet *sheet,
/* We should be setting the output file name to somethig */
/* reasonable */
saved_uri = print_info_get_printtofile_uri (sheet->print_info);
- if (saved_uri != NULL &&
+ if (saved_uri != NULL &&
g_ascii_strncasecmp (doc->uri, "file:///", 8) == 0)
output_uri = gnm_print_uri_change_extension (saved_uri,
settings);
else
saved_uri = NULL;
- if (output_uri == NULL && doc->uri != NULL
+ if (output_uri == NULL && doc->uri != NULL
&& g_ascii_strncasecmp (doc->uri, "file:///", 8) == 0)
- output_uri = gnm_print_uri_change_extension (doc->uri,
+ output_uri = gnm_print_uri_change_extension (doc->uri,
settings);
if (output_uri != NULL) {
- gtk_print_settings_set (settings,
+ gtk_print_settings_set (settings,
GTK_PRINT_SETTINGS_OUTPUT_URI,
output_uri);
g_free (output_uri);
@@ -1726,24 +1726,24 @@ gnm_print_sheet (WorkbookControl *wbc, Sheet *sheet,
res = gtk_print_operation_run (print, action, parent, NULL);
switch (res) {
- case GTK_PRINT_OPERATION_RESULT_APPLY:
+ case GTK_PRINT_OPERATION_RESULT_APPLY:
if (action == GTK_PRINT_OPERATION_ACTION_PRINT_DIALOG) {
char const *printer;
settings = gtk_print_operation_get_print_settings (print);
gnm_conf_set_print_settings (settings);
gnm_insert_meta_date (doc, GSF_META_NAME_PRINT_DATE);
printer = gtk_print_settings_get_printer (settings);
- if (strcmp (printer, "Print to File") == 0 ||
+ if (strcmp (printer, "Print to File") == 0 ||
strcmp (printer, _("Print to File")) == 0) {
- gchar *wb_output_uri =
- gnm_print_uri_change_extension (doc->uri,
+ gchar *wb_output_uri =
+ gnm_print_uri_change_extension (doc->uri,
settings);
- print_info_set_printtofile_from_settings
+ print_info_set_printtofile_from_settings
(sheet->print_info, settings, wb_output_uri);
g_free (wb_output_uri);
}
}
- print_info_set_from_settings
+ print_info_set_from_settings
(sheet->print_info, settings);
break;
case GTK_PRINT_OPERATION_RESULT_CANCEL:
diff --git a/src/rendered-value.c b/src/rendered-value.c
index eaf5c3b..1579bd3 100644
--- a/src/rendered-value.c
+++ b/src/rendered-value.c
@@ -285,7 +285,7 @@ gnm_rendered_value_new (GnmCell const *cell,
}
/* Add foreground color. */
- attr = go_color_to_pango
+ attr = go_color_to_pango
((gnm_style_get_font_color (mstyle))->go_color, TRUE);
attr->start_index = 0;
attr->end_index = G_MAXUINT;
@@ -529,7 +529,7 @@ gnm_rendered_value_get_text (GnmRenderedValue const *rv)
static gboolean
colour_selector_cb (PangoAttribute *attribute, PangoColor *color)
{
- if (attribute->start_index == 0 &&
+ if (attribute->start_index == 0 &&
PANGO_ATTR_FOREGROUND == attribute->klass->type) {
*color = ((PangoAttrColor *)(attribute))->color;
return FALSE;
@@ -540,14 +540,14 @@ colour_selector_cb (PangoAttribute *attribute, PangoColor *color)
static GOColor
colour_from_layout (PangoLayout *layout)
{
- PangoAttrList *attrs = pango_layout_get_attributes (layout),
+ PangoAttrList *attrs = pango_layout_get_attributes (layout),
*fattrs;
PangoColor c;
if (go_pango_attr_list_is_empty (attrs))
return 0;
- fattrs = pango_attr_list_filter
+ fattrs = pango_attr_list_filter
(attrs, (PangoAttrFilterFunc)colour_selector_cb, &c);
if (fattrs == NULL)
@@ -557,7 +557,7 @@ colour_from_layout (PangoLayout *layout)
return GO_COLOR_FROM_RGBA (c.red, c.green, c.blue, 0xff);
}
-GOColor
+GOColor
gnm_rendered_value_get_color (GnmRenderedValue const * rv)
{
return colour_from_layout (rv->layout);
diff --git a/src/sheet-control-gui.c b/src/sheet-control-gui.c
index 072d832..ff30de9 100644
--- a/src/sheet-control-gui.c
+++ b/src/sheet-control-gui.c
@@ -2947,7 +2947,7 @@ scg_comment_display (SheetControlGUI *scg, GnmComment *cc,
if (comment_text != NULL) {
gtk_text_buffer_set_text (buffer, comment_text, -1);
- gnm_load_pango_attributes_into_buffer
+ gnm_load_pango_attributes_into_buffer
(comment_markup, buffer, comment_text);
g_free (comment_text);
}
diff --git a/src/stf.c b/src/stf.c
index e1a770c..ba0e65f 100644
--- a/src/stf.c
+++ b/src/stf.c
@@ -279,7 +279,7 @@ stf_read_workbook (GOFileOpener const *fo, gchar const *enc,
workbook_set_saveinfo
(book,
GO_FILE_FL_WRITE_ONLY,
- go_file_saver_for_id
+ go_file_saver_for_id
("Gnumeric_stf:stf_assistant"));
} else {
/* the user has cancelled */
@@ -486,7 +486,7 @@ stf_read_workbook_auto_csvtab (GOFileOpener const *fo, gchar const *enc,
workbook_set_saveinfo
(book,
GO_FILE_FL_WRITE_ONLY,
- go_file_saver_for_id
+ go_file_saver_for_id
("Gnumeric_stf:stf_assistant"));
} else {
workbook_sheet_delete (sheet);
diff --git a/src/style-conditions.c b/src/style-conditions.c
index 51e4898..a35165c 100644
--- a/src/style-conditions.c
+++ b/src/style-conditions.c
@@ -55,7 +55,7 @@ gnm_style_cond_is_valid (GnmStyleCond const *cond)
g_return_val_if_fail (cond != NULL, FALSE);
if (cond->overlay == NULL) return FALSE;
- if ((cond->texpr[0] != NULL) ^
+ if ((cond->texpr[0] != NULL) ^
(cond->op != GNM_STYLE_COND_CONTAINS_ERR &&
cond->op != GNM_STYLE_COND_NOT_CONTAINS_ERR &&
cond->op != GNM_STYLE_COND_CONTAINS_BLANKS &&
@@ -194,7 +194,7 @@ gnm_style_conditions_insert (GnmStyleConditions *sc,
g_array_insert_val (sc->conditions, pos, *cond);
}
-void
+void
gnm_style_conditions_delete (GnmStyleConditions *sc,
guint pos)
{
diff --git a/src/wbc-gtk-actions.c b/src/wbc-gtk-actions.c
index d0faf14..8ffd398 100644
--- a/src/wbc-gtk-actions.c
+++ b/src/wbc-gtk-actions.c
@@ -101,8 +101,8 @@ static GNM_ACTION_DEF (cb_file_new)
static GNM_ACTION_DEF (cb_file_open) { gui_file_open (wbcg, FILE_OPEN_OPEN, NULL); }
static GNM_ACTION_DEF (cb_file_save) { gui_file_save (wbcg, wb_control_view (WORKBOOK_CONTROL (wbcg))); }
-static GNM_ACTION_DEF (cb_file_save_as) { gui_file_save_as
- (wbcg, wb_control_view (WORKBOOK_CONTROL (wbcg)),
+static GNM_ACTION_DEF (cb_file_save_as) { gui_file_save_as
+ (wbcg, wb_control_view (WORKBOOK_CONTROL (wbcg)),
FILE_SAVE_AS_SAVE, NULL); }
#ifndef HAVE_MKDTEMP
@@ -978,9 +978,9 @@ static GNM_ACTION_DEF (cb_tools_random_generator_uncorrelated) { dialog_random_t
static GNM_ACTION_DEF (cb_tools_random_generator_correlated) { dialog_random_cor_tool (wbcg, wbcg_cur_sheet (wbcg)); }
static GNM_ACTION_DEF (cb_data_sort) { dialog_cell_sort (wbcg); }
static GNM_ACTION_DEF (cb_data_shuffle) { dialog_shuffle (wbcg); }
-static GNM_ACTION_DEF (cb_data_import_text) { gui_file_open
+static GNM_ACTION_DEF (cb_data_import_text) { gui_file_open
(wbcg, FILE_OPEN_IMPORT, "Gnumeric_stf:stf_assistant"); }
-static GNM_ACTION_DEF (cb_data_import_other) { gui_file_open
+static GNM_ACTION_DEF (cb_data_import_other) { gui_file_open
(wbcg, FILE_OPEN_IMPORT, NULL); }
static GNM_ACTION_DEF (cb_auto_filter) { cmd_autofilter_add_remove (WORKBOOK_CONTROL (wbcg)); }
@@ -993,14 +993,14 @@ static GNM_ACTION_DEF (cb_data_table) { dialog_data_table (wbcg); }
static GNM_ACTION_DEF (cb_data_slicer_create) { dialog_data_slicer (wbcg, TRUE); }
static GNM_ACTION_DEF (cb_data_slicer_refresh) { cmd_slicer_refresh (WORKBOOK_CONTROL (wbcg)); }
static GNM_ACTION_DEF (cb_data_slicer_edit) { dialog_data_slicer (wbcg, FALSE); }
-static GNM_ACTION_DEF (cb_data_export) { gui_file_save_as
- (wbcg, wb_control_view (WORKBOOK_CONTROL (wbcg)),
+static GNM_ACTION_DEF (cb_data_export) { gui_file_save_as
+ (wbcg, wb_control_view (WORKBOOK_CONTROL (wbcg)),
FILE_SAVE_AS_EXPORT, NULL); }
-static GNM_ACTION_DEF (cb_data_export_text) { gui_file_save_as
- (wbcg, wb_control_view (WORKBOOK_CONTROL (wbcg)),
+static GNM_ACTION_DEF (cb_data_export_text) { gui_file_save_as
+ (wbcg, wb_control_view (WORKBOOK_CONTROL (wbcg)),
FILE_SAVE_AS_EXPORT, "Gnumeric_stf:stf_assistant"); }
-static GNM_ACTION_DEF (cb_data_export_csv) { gui_file_save_as
- (wbcg, wb_control_view (WORKBOOK_CONTROL (wbcg)),
+static GNM_ACTION_DEF (cb_data_export_csv) { gui_file_save_as
+ (wbcg, wb_control_view (WORKBOOK_CONTROL (wbcg)),
FILE_SAVE_AS_EXPORT, "Gnumeric_stf:stf_csv"); }
static void
@@ -2315,7 +2315,7 @@ static GtkActionEntry const actions[] = {
{ "FormatCells", NULL, N_("_Format..."),
"<control>1", N_("Modify the formatting of the selected cells"),
G_CALLBACK (cb_format_cells) },
- { "FormatCellsCond", NULL, N_("_Conditional Formating..."), NULL,
+ { "FormatCellsCond", NULL, N_("_Conditional Formating..."), NULL,
N_("Modify the conditional formatting of the selected cells"),
G_CALLBACK (cb_format_cells_cond) },
{ "FormatCellsFitHeight", "Gnumeric_RowSize", N_("Auto Fit _Height"), NULL,
diff --git a/src/wbc-gtk.c b/src/wbc-gtk.c
index dedf8bf..07b4d80 100644
--- a/src/wbc-gtk.c
+++ b/src/wbc-gtk.c
@@ -4258,6 +4258,7 @@ cb_add_menus_toolbars (G_GNUC_UNUSED GtkUIManager *ui,
G_CALLBACK (cb_handlebox_button_press),
gtk);
+ g_object_set (G_OBJECT (w), "hexpand", TRUE, NULL);
gtk_container_add (GTK_CONTAINER (box), w);
gtk_widget_show_all (box);
if (!visible)
diff --git a/src/widgets/gnm-format-sel.c b/src/widgets/gnm-format-sel.c
index e3fdfda..71b55c1 100644
--- a/src/widgets/gnm-format-sel.c
+++ b/src/widgets/gnm-format-sel.c
@@ -39,7 +39,7 @@ cb_generate_preview (GOFormatSel *gfs, PangoAttrList **attrs)
if (go_format_is_general (fmt) && VALUE_FMT (v) != NULL)
fmt = VALUE_FMT (v);
- err = format_value_layout (layout, fmt, v, -1,
+ err = format_value_layout (layout, fmt, v, -1,
go_format_sel_get_dateconv (gfs));
if (err) {
str = NULL;
diff --git a/src/widgets/gnumeric-expr-entry.c b/src/widgets/gnumeric-expr-entry.c
index 4efda1e..cd484b7 100644
--- a/src/widgets/gnumeric-expr-entry.c
+++ b/src/widgets/gnumeric-expr-entry.c
@@ -287,7 +287,7 @@ cb_icon_clicked (GtkButton *icon,
gtk_window_get_size (GTK_WINDOW (toplevel), &width, &height);
g_object_set_data (G_OBJECT (entry), "old_window_width", GUINT_TO_POINTER (width));
g_object_set_data (G_OBJECT (entry), "old_window_height", GUINT_TO_POINTER (height));
- g_object_set_data (G_OBJECT (entry), "old_default",
+ g_object_set_data (G_OBJECT (entry), "old_default",
gtk_window_get_default_widget (GTK_WINDOW (toplevel)));
container_props = NULL;
@@ -944,7 +944,7 @@ gee_update_lexer_items (GnmExprEntry *gee)
if (!gee->feedback_disabled && !forced_text) {
gee->texpr = gnm_expr_parse_str
((str[0] == '=') ? str+1 : str,
- &gee->pp, GNM_EXPR_PARSE_DEFAULT
+ &gee->pp, GNM_EXPR_PARSE_DEFAULT
| GNM_EXPR_PARSE_UNKNOWN_NAMES_ARE_STRINGS,
sheet_get_conventions (sheet), NULL);
}
diff --git a/src/workbook-control.c b/src/workbook-control.c
index a0f65ce..acc848c 100644
--- a/src/workbook-control.c
+++ b/src/workbook-control.c
@@ -283,8 +283,8 @@ wb_control_parse_and_jump (WorkbookControl *wbc, char const *text)
if (target == NULL) {
GnmExprTop const *texpr;
- texpr = gnm_expr_parse_str
- (text, &pp, GNM_EXPR_PARSE_DEFAULT,
+ texpr = gnm_expr_parse_str
+ (text, &pp, GNM_EXPR_PARSE_DEFAULT,
gnm_conventions_xls_r1c1, NULL);
if (texpr != NULL) {
target = gnm_expr_top_get_range (texpr);
@@ -294,15 +294,15 @@ wb_control_parse_and_jump (WorkbookControl *wbc, char const *text)
if (target == NULL) {
GnmExprTop const *texpr;
- texpr = gnm_expr_parse_str
- (text, &pp, GNM_EXPR_PARSE_DEFAULT,
+ texpr = gnm_expr_parse_str
+ (text, &pp, GNM_EXPR_PARSE_DEFAULT,
gnm_conventions_default, NULL);
if (texpr != NULL) {
target = gnm_expr_top_get_range (texpr);
gnm_expr_top_unref (texpr);
}
}
-
+
if (target == NULL) {
/* Not an address; is it a name? */
GnmParsePos pp;
diff --git a/src/workbook-view.c b/src/workbook-view.c
index 3ee529c..8c5bb0c 100644
--- a/src/workbook-view.c
+++ b/src/workbook-view.c
@@ -546,11 +546,11 @@ wb_view_auto_expr_recalc (WorkbookView *wbv)
/* We need to shift the attribute list */
atl = pango_attr_list_ref (pango_layout_get_attributes (layout));
attrs = pango_attr_list_new ();
- pango_attr_list_splice
- (attrs, atl, old_len,
+ pango_attr_list_splice
+ (attrs, atl, old_len,
str->len - old_len);
pango_attr_list_unref (atl);
- } else
+ } else
g_string_append (str, "Internal ERROR!");
g_object_unref (layout);
g_object_unref (context);
diff --git a/src/workbook.c b/src/workbook.c
index c3c40da..d3f0101 100644
--- a/src/workbook.c
+++ b/src/workbook.c
@@ -426,7 +426,7 @@ workbook_set_saveinfo (Workbook *wb, GOFileFormatLevel level, GOFileSaver *fs)
g_object_weak_ref (G_OBJECT (fs),
(GWeakNotify) cb_saver_finalize, wb);
}
-
+
if (level == GO_FILE_FL_WRITE_ONLY)
return FALSE;
wb->file_format_level = level;
diff --git a/src/xml-sax-read.c b/src/xml-sax-read.c
index 24327e6..8076032 100644
--- a/src/xml-sax-read.c
+++ b/src/xml-sax-read.c
@@ -2777,7 +2777,7 @@ xml_sax_print_to_uri (GsfXMLIn *xin, G_GNUC_UNUSED GsfXMLBlob *blob)
xml_sax_must_have_sheet (state);
- print_info_set_printtofile_uri (state->sheet->print_info,
+ print_info_set_printtofile_uri (state->sheet->print_info,
xin->content->str);
}
diff --git a/src/xml-sax-write.c b/src/xml-sax-write.c
index 4a1e9f6..f0a6a73 100644
--- a/src/xml-sax-write.c
+++ b/src/xml-sax-write.c
@@ -403,13 +403,13 @@ xml_write_print_info (GnmOutputXML *state, PrintInformation *pi)
paper_name = print_info_get_paper (pi);
if (paper_name)
- gsf_xml_out_simple_element (state->output, GNM "paper",
+ gsf_xml_out_simple_element (state->output, GNM "paper",
paper_name);
g_free (paper_name);
-
+
uri = print_info_get_printtofile_uri (pi);
if (uri)
- gsf_xml_out_simple_element (state->output, GNM "print-to-uri",
+ gsf_xml_out_simple_element (state->output, GNM "print-to-uri",
uri);
if (NULL != pi->page_breaks.v)
@@ -419,36 +419,36 @@ xml_write_print_info (GnmOutputXML *state, PrintInformation *pi)
switch (pi->comment_placement) {
case PRINT_COMMENTS_IN_PLACE:
- gsf_xml_out_simple_element (state->output, GNM "comments",
+ gsf_xml_out_simple_element (state->output, GNM "comments",
"in_place");
break;
case PRINT_COMMENTS_AT_END:
- gsf_xml_out_simple_element (state->output, GNM "comments",
+ gsf_xml_out_simple_element (state->output, GNM "comments",
"at_end");
break;
case PRINT_COMMENTS_NONE:
default:
- gsf_xml_out_simple_element (state->output, GNM "comments",
+ gsf_xml_out_simple_element (state->output, GNM "comments",
"none");
break;
}
switch (pi->error_display) {
case PRINT_ERRORS_AS_BLANK:
- gsf_xml_out_simple_element (state->output, GNM "errors",
+ gsf_xml_out_simple_element (state->output, GNM "errors",
"as_blank");
break;
case PRINT_ERRORS_AS_DASHES:
- gsf_xml_out_simple_element (state->output, GNM "errors",
+ gsf_xml_out_simple_element (state->output, GNM "errors",
"as_dashes");
break;
case PRINT_ERRORS_AS_NA:
- gsf_xml_out_simple_element (state->output, GNM "errors",
+ gsf_xml_out_simple_element (state->output, GNM "errors",
"as_na");
break;
case PRINT_ERRORS_AS_DISPLAYED:
default:
- gsf_xml_out_simple_element (state->output, GNM "errors",
+ gsf_xml_out_simple_element (state->output, GNM "errors",
"as_displayed");
break;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]