summaryrefslogtreecommitdiff
path: root/src/sheet/grid.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/sheet/grid.h')
-rw-r--r--src/sheet/grid.h40
1 files changed, 21 insertions, 19 deletions
diff --git a/src/sheet/grid.h b/src/sheet/grid.h
index 88bba3f..868b7cb 100644
--- a/src/sheet/grid.h
+++ b/src/sheet/grid.h
@@ -26,8 +26,8 @@
*
* You should have received a copy of the GNU General Public
* License along with this program; if not, write to the
- * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
- * Boston, MA 02111-1307, USA.
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*/
#ifndef __GRID_H
@@ -36,34 +36,36 @@
#include <glib.h>
#include <gtk/gtk.h>
#include <goocanvas.h>
+#include "coords.h"
-#define TYPE_GRID (grid_get_type())
-#define GRID(obj) (G_TYPE_CHECK_INSTANCE_CAST (obj, grid_get_type (), Grid))
-#define GRID_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST (klass, grid_get_type (), GridClass))
-#define IS_GRID(obj) (G_TYPE_CHECK_INSTANCE_TYPE (obj, grid_get_type ()))
+#define TYPE_GRID (grid_get_type ())
+#define GRID(obj) (G_TYPE_CHECK_INSTANCE_CAST (obj, grid_get_type (), Grid))
+#define GRID_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST (klass, grid_get_type (), GridClass))
+#define IS_GRID(obj) (G_TYPE_CHECK_INSTANCE_TYPE (obj, grid_get_type ()))
typedef struct _Grid Grid;
typedef struct _GridClass GridClass;
typedef struct _GridPriv GridPriv;
-
-struct _Grid {
+struct _Grid
+{
GooCanvasGroup canvas_group;
- gdouble width;
- gdouble height;
- gdouble x;
- gdouble y;
- GridPriv * priv;
+ gdouble width;
+ gdouble height;
+ gdouble x;
+ gdouble y;
+ GridPriv *priv;
};
-struct _GridClass {
- GooCanvasGroupClass parent_class;
+struct _GridClass
+{
+ GooCanvasGroupClass parent_class;
};
-Grid *grid_create (GooCanvasItem *root, gdouble width, gdouble height);
+Grid *grid_new (GooCanvasItem *root, gdouble width, gdouble height);
GType grid_get_type (void);
-void snap_to_grid (Grid *grid, double *x, double *y);
-void grid_show (Grid *grid, gboolean snap);
-void grid_snap (Grid *grid, gboolean snap);
+gboolean snap_to_grid (Grid *grid, double *x, double *y);
+void grid_show (Grid *grid, gboolean snap);
+void grid_snap (Grid *grid, gboolean snap);
#endif