]> git.donarmstrong.com Git - xournal.git/blobdiff - src/xournal.h
Add a hand tool (+ other misc updates)
[xournal.git] / src / xournal.h
index 236ff33578c30a9c015ff350e8e89ee9aaadf4d6..6ed265a2759a19ce5bd0fde5693ebdefa89fa884 100644 (file)
@@ -12,7 +12,7 @@
 #define PIXEL_MOTION_THRESHOLD 0.3
 #define MAX_AXES 12
 #define EPSILON 1E-7
-#define MAX_ZOOM 20
+#define MAX_ZOOM 20.0
 #define DEFAULT_ZOOM 1.3333333333
 #define MIN_ZOOM 0.2
 
@@ -97,6 +97,7 @@ extern guint predef_bgcolors_rgba[COLOR_MAX];
 #define TOOL_SELECTREGION 4
 #define TOOL_SELECTRECT   5
 #define TOOL_VERTSPACE    6
+#define TOOL_HAND         7
 #define NUM_STROKE_TOOLS  3
 #define NUM_BUTTONS       3
 
@@ -142,6 +143,7 @@ typedef struct Item {
 #define ITEM_DELETE_PAGE 14
 #define ITEM_REPAINTSEL 15
 #define ITEM_MOVESEL_VERT 16
+#define ITEM_HAND 17
 
 typedef struct Layer {
   GList *items; // the items on the layer, from bottom to top
@@ -200,6 +202,7 @@ typedef struct UIData {
   gboolean use_xinput; // use input devices instead of core pointer
   gboolean allow_xinput; // allow use of xinput ?
   int screen_width, screen_height; // initial screen size, for XInput events
+  double hand_refpt[2];
   char *filename;
   gboolean view_continuous, fullscreen;
   gboolean in_update_page_stuff; // semaphore to avoid scrollbar retroaction