#3757 Wip: Add draggers to text annotation points when text is selected

This commit is contained in:
Jacob Støren
2018-11-29 15:51:32 +01:00
parent c60e6b8140
commit c2206abca5
5 changed files with 255 additions and 0 deletions

View File

@@ -22,6 +22,7 @@
#include "RimGridView.h"
#include "RimProject.h"
#include "RimAnnotationCollection.h"
#include "AnnotationCommands/RicTextAnnotation3dEditor.h"
CAF_PDM_SOURCE_INIT(RimTextAnnotation, "RimTextAnnotation");
@@ -33,6 +34,8 @@ CAF_PDM_SOURCE_INIT(RimTextAnnotation, "RimTextAnnotation");
RimTextAnnotation::RimTextAnnotation()
{
CAF_PDM_InitObject("TextAnnotation", ":/TextAnnotation16x16.png", "", "");
this->setUi3dEditorTypeName(RicTextAnnotation3dEditor::uiEditorTypeName());
CAF_PDM_InitField(&m_anchorPointXyd, "AnchorPointXyd", Vec3d::ZERO, "Anchor Point", "", "", "");
CAF_PDM_InitField(&m_labelPointXyd, "LabelPointXyd", Vec3d::ZERO, "Label Point", "", "", "");

View File

@@ -66,6 +66,8 @@ protected:
virtual caf::PdmFieldHandle* objectToggleField() override;
private:
friend class RicTextAnnotation3dEditor;
caf::PdmField<Vec3d> m_anchorPointXyd;
caf::PdmField<Vec3d> m_labelPointXyd;
caf::PdmField<QString> m_text;