StatechartView.h
Go to the documentation of this file.
1/*
2* This file is part of ArmarX.
3*
4* ArmarX is free software; you can redistribute it and/or modify
5* it under the terms of the GNU General Public License version 2 as
6* published by the Free Software Foundation.
7*
8* ArmarX is distributed in the hope that it will be useful, but
9* WITHOUT ANY WARRANTY; without even the implied warranty of
10* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11* GNU General Public License for more details.
12*
13* You should have received a copy of the GNU General Public License
14* along with this program. If not, see <http://www.gnu.org/licenses/>.
15*
16* @package ArmarX::
17* @author Mirko Waechter ( mirko.waechter at kit dot edu)
18* @date 2014
19* @copyright http://www.gnu.org/licenses/gpl-2.0.txt
20* GNU General Public License
21*/
22
23#pragma once
24
25
26#include <QGraphicsScene>
27#include <QWidget>
28
31
32#include "../StateScene.h"
33#include "../model/State.h"
35#include "GraphicsViewZoom.h"
36
37namespace Ui
38{
39 class StatechartView;
40}
41
42namespace armarx
43{
44
45 class StatechartView : public QWidget
46 {
47 Q_OBJECT
48
49 public:
52 bool enableLayouting = true,
53 QWidget* parent = 0);
54 ~StatechartView() override;
55
58
60 getScene() const
61 {
62 return stateScene;
63 }
64
65 QGraphicsView* getGraphicsView() const;
67
69 signals:
71 public slots:
73 void setOriginalZoom();
75 void viewAll();
76 void onItemChange();
77 void showSubSubstates(bool show = true);
78
79 private:
80 // QList<statechartmodel::StatePtr> stateClasses;
81 ::Ui::StatechartView* ui;
82 StateScene* stateScene;
83 Graphics_view_zoom* zoomer;
84 // LayoutController layoutController;
85 LayoutThread layoutThread;
86 // QWidget interface
87 public:
88 QSize sizeHint() const override;
89 };
90} // namespace armarx
QSize sizeHint() const override
QGraphicsView * getGraphicsView() const
void showSubSubstates(bool show=true)
statechartmodel::StateInstancePtr getStateInstance() const
Graphics_view_zoom * getGraphicsViewZoomer() const
LayoutController & getLayoutController()
static statechartmodel::StatePtr CreateTestStates()
StatechartView(statechartmodel::StatePtr state=statechartmodel::StatePtr(new statechartmodel::State()), bool enableLayouting=true, QWidget *parent=0)
void setState(statechartmodel::StatePtr state)
void selectedStateChanged(statechartmodel::StateInstancePtr selectedStateInstance)
StateScene * getScene() const
ArmarX Headers.
std::shared_ptr< State > StatePtr
Definition State.h:48
std::shared_ptr< StateInstance > StateInstancePtr
This file offers overloads of toIce() and fromIce() functions for STL container types.