User:Jcc242

Stuff
http://stevelosh.com/blog/2013/09/teach-dont-tell/

Acceptable and unacceptable input values or types, and their meanings Return values or types, and their meanings Error and exception conditions values or types, that can occur, and their meanings Side effects Preconditions, which subclasses may weaken (but not strengthen) Postconditions, which subclasses may strengthen (but not weaken) Invariants, which subclasses may strengthen (but not weaken) (more rarely) Performance guarantees, e.g. for time or space used

ToDo
Creating your own class for Drawing Workbench. This is a rundown for the ViewTemplate.

App/FeatureViewTemplate.cp/.h
FeatureViewTemplate ~FeatureViewTemplate execute

Gui/QGraphicsViewTemplate.cpp/.h
public: explicit QGraphicsItemViewTemplate(const QPoint &position, QGraphicsScene *scene); ~QGraphicsItemViewTemplate; setViewPartFeature

App/CMakeLists.txt
Simply add the App/FeatureViewTemplate.cpp/.h files to the CMakeLists.txt. Add these under the SET(Feature_SRCS ... ) section.

App/AppDrawing.cpp
Include App/FeatureViewTemplate.h and add your class to the list of classes.

Gui/Command.cpp
This is where the stuff happens when your button is clicked (the button is added to the toolbar in Workbench.cpp, see below). You only need to include your App/FeatureViewTemplate.h file. At the bottom make sure to add your command to the list in the CreateDrawingCommands method.

The activated is the main loop where all the work will be done to do whatever you want.

Gui/CanvasView.cpp/.h
The actual QGraphicsScene object. Adds objects to the scene. Needs to have a way to add QGraphicsSvgItem to it.

Added addViewTemplate(Drawing::FeatureViewTemplate *template);

Gui/CMakeLists.txt
Add the Gui/QGraphicsViewTemplate.cpp/.h to the CMakeLists.txt.

Gui/Workbench.cpp/.h
Adds icons to workbench toolbars and stuff.

Gui/DrawingView.cpp/.h
Add stuff to identify and add template to the scene? In particular, see attachPageObject

ViewProviderView.cpp/.h (or ViewProviderPage?)
Not sure if I need this yet.