~ubuntu-branches/ubuntu/feisty/gnumeric/feisty-updates

« back to all changes in this revision

Viewing changes to src/stf.c

  • Committer: Bazaar Package Importer
  • Author(s): Gauvain Pocentek
  • Date: 2006-11-14 14:02:03 UTC
  • mfrom: (1.1.5 upstream)
  • Revision ID: james.westby@ubuntu.com-20061114140203-iv3j2aii3vch6isl
Tags: 1.7.2-1ubuntu1
* Merge with debian experimental:
  - debian/control, debian/*-gtk-*, debian/rules,
    debian/shlibs.local: Xubuntu changes for
    gtk/gnome multibuild.
  - run intltool-update in po*
  - Build Depend on intltool

Show diffs side-by-side

added added

removed removed

Lines of Context:
21
21
 */
22
22
 
23
23
#include <gnumeric-config.h>
24
 
#include <glib/gi18n.h>
 
24
#include <glib/gi18n-lib.h>
25
25
#include "gnumeric.h"
26
26
#include "stf.h"
27
27
 
224
224
}
225
225
 
226
226
static GnmValue *
227
 
cb_get_content (Sheet *sheet, int col, int row,
228
 
                GnmCell *cell, GsfOutput *buf)
 
227
cb_get_content (GnmCellIter const *iter, GsfOutput *buf)
229
228
{
230
 
        if (cell != NULL) {
 
229
        GnmCell *cell;
 
230
 
 
231
        if (NULL != (cell = iter->cell)) {
231
232
                char *tmp;
232
 
                if (cell_has_expr (cell)) {
233
 
                        GnmParsePos pp;
 
233
                if (cell_has_expr (cell))
234
234
                        tmp = gnm_expr_top_as_string (cell->base.texpr,
235
 
                                parse_pos_init_cell (&pp, cell),
236
 
                                gnm_expr_conventions_default);
237
 
                } else if (VALUE_FMT (cell->value) != NULL)
 
235
                                &iter->pp, iter->pp.sheet->convs);
 
236
                else if (VALUE_FMT (cell->value) != NULL)
238
237
                        tmp = format_value (NULL, cell->value, NULL, -1,
239
 
                                workbook_date_conv (sheet->workbook));
 
238
                                workbook_date_conv (iter->pp.wb));
240
239
                else
241
240
                        tmp = value_get_as_string (cell->value);
242
241
 
273
272
                return;
274
273
        if (range_width (src) > 1) {
275
274
                go_cmd_context_error (cc, g_error_new (go_error_invalid (), 0,
276
 
                        _("Only 1 one column of <b>input</b> data can be parsed at a time, not %d"),
277
 
                        range_width (src)));
 
275
                        _("Only one column of <b>input</b> data can be parsed at a time")));
278
276
                return;
279
277
        }
280
278
 
451
449
        if (pl == FILE_PROBE_CONTENT) {
452
450
                guint8 const *header;
453
451
                gsf_off_t i;
454
 
                const char *enc = NULL;
 
452
                char const *enc = NULL;
455
453
                char *header_utf8;
456
 
                const char *p;
 
454
                char const *p;
457
455
                int try;
458
456
                gboolean ok = TRUE;
459
457