Graphics Editor
 All Classes Namespaces Files Functions Variables Pages
Public Member Functions | List of all members
editor::CanvasController Class Reference

#include <controller.h>

Collaboration diagram for editor::CanvasController:

Public Member Functions

 CanvasController (GraphicDocument &model_, MainView &view_)
 
void import_document (const std::string &path)
 
void export_document (const std::string &path)
 
void add_primitive (std::shared_ptr< figures::CanvasPrimitive > &primitive)
 
void remove_primitive (std::shared_ptr< figures::CanvasPrimitive > &primitive)
 

Constructor & Destructor Documentation

editor::CanvasController::CanvasController ( editor::GraphicDocument model_,
editor::MainView view_ 
)

Construct controller with model and view

Member Function Documentation

void editor::CanvasController::add_primitive ( std::shared_ptr< figures::CanvasPrimitive > &  primitive)

Add figure and redraw canvas

void editor::CanvasController::export_document ( const std::string &  path)

Save document to file

void editor::CanvasController::import_document ( const std::string &  path)

Load document from file and draw

void editor::CanvasController::remove_primitive ( std::shared_ptr< figures::CanvasPrimitive > &  primitive)

Remove figure and redraw canvas


The documentation for this class was generated from the following files: