diff options
author | Alex Merry <alex.merry@cs.ox.ac.uk> | 2012-12-04 18:55:25 +0000 |
---|---|---|
committer | Alex Merry <dev@randomguy3.me.uk> | 2012-12-06 12:08:03 +0000 |
commit | f23a2d9daa1eb62b2afac8997f1d76eb881628f7 (patch) | |
tree | 378c1cc752b7aa1fd52f35da23bce7de855bef5d /tikzit/src/gtk/Window.h | |
parent | 134de8169993f23f2c3a733a7bf96622965e7d7d (diff) |
Refactor GraphInputHandler into Tools
Diffstat (limited to 'tikzit/src/gtk/Window.h')
-rw-r--r-- | tikzit/src/gtk/Window.h | 25 |
1 files changed, 14 insertions, 11 deletions
diff --git a/tikzit/src/gtk/Window.h b/tikzit/src/gtk/Window.h index 6aa710a..089cc49 100644 --- a/tikzit/src/gtk/Window.h +++ b/tikzit/src/gtk/Window.h @@ -17,10 +17,8 @@ #import "TZFoundation.h" #import <gtk/gtk.h> -#import "WidgetSurface.h" -@class GraphRenderer; -@class GraphInputHandler; +@class GraphEditorPanel; @class Menu; @class PropertyPane; @class Preambles; @@ -30,6 +28,7 @@ @class StyleManager; @class StylesPane; @class TikzDocument; +@protocol Tool; /** * Manages a document window @@ -44,10 +43,7 @@ // Classes that manage parts of the window Menu *menu; - GraphRenderer *renderer; - GraphInputHandler *inputHandler; - - WidgetSurface *surface; + GraphEditorPanel *graphPanel; // state variables BOOL suppressTikzUpdates; @@ -97,6 +93,15 @@ - (void) saveActiveDocumentAsShape; /** + * Close the window. + * + * May terminate the application if this is the last window. + * + * Will ask for user confirmation if the document is not saved. + */ +- (void) close; + +/** * Cut the current selection to the clipboard. */ - (void) cut; @@ -110,10 +115,6 @@ - (void) paste; /** - * The graph input handler - */ -- (GraphInputHandler*) graphInputHandler; -/** * The GTK+ window that this class manages. */ - (GtkWindow*) gtkWindow; @@ -149,6 +150,8 @@ */ - (void) presentGError:(GError*)error withMessage:(NSString*)message; +- (void) setActiveTool:(id<Tool>)tool; + - (void) zoomIn; - (void) zoomOut; - (void) zoomReset; |