VR-Forces 4.8 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
planListBoxItem.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 2016 MAK Technologies, Inc.
3 ** All rights reserved.
4 *******************************************************************************/
5 
8 
9 #pragma once
10 
12 
13 #include <vrfplan/stmtIndex.h>
14 #include <vlutil/vlString.h>
15 
16 #include <QtGui/QImage>
17 #include <QtWidgets/QTreeWidget>
18 
19 namespace makVrf
20 {
21  class DtPlanTreeWidget;
22 
24  {
25  public:
26  DtPlanListBoxItem(DtSimBlock*, const QString & text = QString::null, int step = -1);
27  DtPlanListBoxItem(DtSimBlock*, const DtPlanListBoxItem* parentItem, const DtStmtIndex& index,
28  const QString& indent, int step = -1);
29  virtual ~DtPlanListBoxItem();
30 
31  virtual void setStatementIndex(const DtStmtIndex index);
32  virtual const DtStmtIndex& statementIndex() const;
33 
34  virtual void setIndent(const QString& indent);
35  virtual const QString& indent() const;
36 
37  virtual void setBlockIndex(int index);
38  virtual int blockIndex() const;
39 
40  virtual void setPlanText(const QString&);
41 
42  DtSimBlock* parentBlock() const { return myParentBlock; };
43  DtSimBlock* blockHeader() const { return myBlockHeader; };
44  DtSimStatement* parentStatement() const;
45 
47  DtSimStatement* blockStatement() const;
48  DtSimStatement* parentBlockStatement() const;
49  DtSimStatement* statement() const;
50 
52  virtual QString planItemText() const;
53 
54  QTreeWidgetItem* prev();
55 
58  virtual void setCurrent(bool);
59  bool current() const;
60 
62  virtual QVariant data(int col, int role) const;
63  virtual QString stringRep() const;
64 
65  virtual void setDraggingOver(bool);
66  bool draggingOver() const { return myDraggingOver; };
67 
68  bool isLastStatementInBlock() const;
69  bool isFirstStatementInBlock() const;
70 
71  virtual bool within(DtSimBlock*) const;
72  virtual bool within(DtSimStatement*) const;
73 
74  protected:
76  QString myIndent;
78  bool myCurrent;
80  int myStep;
85  };
86 
87  inline bool DtPlanListBoxItem::current() const
88  {
89  return myCurrent;
90  }
91 }
bool myDraggingOver
Definition: planListBoxItem.h:79
#define DT_DLL_VRFGUICOREQT
Definition: vrfGuiCoreQt.h:26
class DtStmtIndex:
Definition: stmtIndex.h:24
This class will support the listing of plan items and the dragging/dropping thereof.
Definition: planTreeWidget.h:52
bool myCurrent
Definition: planListBoxItem.h:78
DtPlanTreeWidget * myPlanTreeWidget
Definition: planListBoxItem.h:83
int myStep
Definition: planListBoxItem.h:80
QString myIndent
Definition: planListBoxItem.h:76
class DtSimBlock:
Definition: simBlock.h:29
Definition: planListBoxItem.h:23
bool draggingOver() const
Definition: planListBoxItem.h:66
bool current() const
Definition: planListBoxItem.h:87
class DtSimStatement:
Definition: simStatement.h:41
DtSimBlock * myBlockHeader
Definition: planListBoxItem.h:82
DtSimBlock * myParentBlock
Definition: planListBoxItem.h:81
DtSimBlock * blockHeader() const
Definition: planListBoxItem.h:43
int myBlockIndex
Definition: planListBoxItem.h:77
DtStmtIndex myStatementIndex
Definition: planListBoxItem.h:75
DtSimBlock * parentBlock() const
Definition: planListBoxItem.h:42
const DtPlanListBoxItem * myParentItem
Definition: planListBoxItem.h:84

Document ID: Generated on Thu Aug 27 10:56:05 EDT 2020 from SVN revision 217100
Copyright © 2005-2020 MAK Technologies. All Rights Reserved (www.mak.com)