GETENV: check for proper UTF-8.
[gnumeric.git] / src / gnm-sheet-slicer.h
blobe73ab7889ec96c54e8d62e5614901b0af85816dc
1 /* vim: set sw=8: -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
2 /*
3 * gnm-sheet-slicer.h : Gnumeric specific display for goffice's DataSlicers
5 * Copyright (C) 2008 Jody Goldberg (jody@gnome.org)
7 * This program is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License as
9 * published by the Free Software Foundation; either version 2 of the
10 * License, or (at your option) version 3.
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
19 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301
20 * USA
22 #ifndef GNM_SHEET_SLICER_H
23 #define GNM_SHEET_SLICER_H
25 #include <gnumeric.h>
26 #include "goffice-data.h"
27 #include <glib-object.h>
29 G_BEGIN_DECLS
31 #define GNM_SHEET_SLICER_TYPE (gnm_sheet_slicer_get_type ())
32 #define GNM_SHEET_SLICER(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), GNM_SHEET_SLICER_TYPE, GnmSheetSlicer))
33 #define GNM_IS_SHEET_SLICER(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), GNM_SHEET_SLICER_TYPE))
35 GType gnm_sheet_slicer_get_type (void);
37 typedef enum {
38 GSS_LAYOUT_XL_OUTLINE = 0,
39 GSS_LAYOUT_XL_COMPACT = 1,
40 GSS_LAYOUT_XL_TABULAR = 2,
41 GSS_LAYOUT_MAX
42 } GnmSheetSlicerLayout;
44 void gnm_sheet_slicer_set_sheet (GnmSheetSlicer *gss, Sheet *sheet);
45 void gnm_sheet_slicer_clear_sheet (GnmSheetSlicer *gss);
46 GnmRange const *gnm_sheet_slicer_get_range (GnmSheetSlicer const *src);
47 void gnm_sheet_slicer_set_range (GnmSheetSlicer *gss, GnmRange const *r);
48 GnmSheetSlicerLayout
49 gnm_sheet_slicer_get_layout (GnmSheetSlicer const *src);
50 void gnm_sheet_slicer_set_layout (GnmSheetSlicer *gss, GnmSheetSlicerLayout l);
52 #ifndef GOFFICE_NAMESPACE_DISABLE
53 GODataSlicerField *gnm_sheet_slicer_field_header_at_pos (GnmSheetSlicer const *gss, GnmCellPos const *pos);
54 #endif
56 void gnm_sheet_slicer_regenerate (GnmSheetSlicer *gss);
58 /* Convenience */
59 gboolean gnm_sheet_slicer_overlaps_range (GnmSheetSlicer const *gss, GnmRange const *r);
61 /* Scripting */
62 GType gnm_sheet_slicer_layout_get_type (void);
64 /* Sheet Utilities */
65 GnmSheetSlicer * gnm_sheet_slicers_at_pos (Sheet const *sheet, GnmCellPos const *pos);
67 G_END_DECLS
69 #endif /* GNM_SHEET_SLICER_H */