Graphics Editor
 All Classes Namespaces Files Functions Variables Pages
controller.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <string>
4 #include "model.h"
5 #include "view.h"
6 
7 namespace editor {
9  public:
13  CanvasController(GraphicDocument& model_, MainView& view_);
14 
18  void import_document(const std::string& path);
19 
23  void export_document(const std::string& path);
24 
28  void add_primitive(std::shared_ptr<figures::CanvasPrimitive>& primitive);
29 
33  void remove_primitive(std::shared_ptr<figures::CanvasPrimitive>& primitive);
34 
35  private:
36  GraphicDocument& model;
37  MainView view;
38  };
39 }
CanvasController(GraphicDocument &model_, MainView &view_)
Definition: controller.cpp:4
Definition: view.h:6
void remove_primitive(std::shared_ptr< figures::CanvasPrimitive > &primitive)
Definition: controller.cpp:23
void add_primitive(std::shared_ptr< figures::CanvasPrimitive > &primitive)
Definition: controller.cpp:18
Definition: controller.h:8
void export_document(const std::string &path)
Definition: controller.cpp:14
void import_document(const std::string &path)
Definition: controller.cpp:9
Definition: model.h:9