FLImaging 6.5.8.1
GUIPropertyItemViewImageFigure.h
1#pragma once
2
11#include "GUIPropertyItemFigure.h"
12
14namespace FLImaging
15{
17 namespace GUI
18 {
19 class CGUIViewImage;
20 class CGUIPropertyItemViewImageList;
21 class CGUIManagerContextMenuPropertyItemViewImageFigure;
22
31 {
32 public:
40
48
59 CGUIPropertyItemViewImageFigure(CGUIPropertyItemViewImageList* pPIIVL);
60
68
81 virtual bool SetViewImageList(CGUIPropertyItemViewImageList* pPIIVL);
82
93 CGUIPropertyItemViewImageList* GetViewImageList();
94
103 virtual CMFCPropertyGridProperty* CreateGridProperty() override;
104
116
136 virtual const CResult MakeValidFigure(Base::CFLString<wchar_t> strValue, Base::CFLString<wchar_t>& strValidFigure, bool bMsgBox = false);
137
148 virtual void SetInstantApplyMode(bool bSet, bool bFixMode) override;
149
158 virtual void SetMagnetToImageBoundaryMode(bool bSet);
159
168 virtual bool IsMagnetToImageBoundaryMode() const;
169
178 virtual void SetMagnetAngleMode(bool bSet);
179
188 virtual bool IsMagnetAngleMode() const;
189
202 virtual const CResult LoadFigureGBR(const wchar_t* pWcsPath = nullptr);
203
216 virtual const CResult LoadFigureDXF(const wchar_t* pWcsPath = nullptr);
217
230 virtual const CResult SaveFigure(const wchar_t* pWcsFileNameWithPath = nullptr) const;
231
242 virtual void ShowFigure(bool bShow, bool bCreate = true);
243
252 virtual bool IsFigureVisible() const;
253
262 virtual void SetViewImage(const CGUIViewImage* pViewImage);
263
287
299 void SetAvailableContextMenu(EAvailablePropertyItemViewImageFigureContextMenu eAvailableMenu = EAvailablePropertyItemViewImageFigureContextMenu_Default);
300
313
314 protected:
315 UINT GetContextMenuFlag(EAvailablePropertyItemViewImageFigureContextMenu eMenu) const;
316 UINT GetContextMenuFlag(EAvailablePropertyItemViewImageFigureContextMenu eMenu, UINT uAssignFlag) const;
317
318 bool MakeDifferentTemplateType(Foundation::EFigureTemplateType eType, bool bMsgBox = true);
319
320 protected:
321 bool m_bEnableMagnetToImageBoundaryMode;
322 bool m_bEnableMagnetAngleMode;
323 CGUIManagerContextMenuPropertyItemViewImageFigure* m_pMgrContextMenu;
325
326 friend class CGUIViewImage;
327 friend class CGUIPropertyGridPropertyViewImageList;
328 friend class CGUIPropertyGridPropertyViewImageFigure;
329 friend class CGUIManagerViewImageObject;
330 friend class CGUIManagerContextMenuPropertyItemViewImageFigure;
331 };
332 }
333}
Template type string class.
Definition INIUtilities.h:20
FLImaging module execution result object.
Definition ResultsDef.h:1514
A class of Figure property.
Definition GUIPropertyItemFigure.h:470
A class of Figure property.
Definition GUIPropertyItemViewImageFigure.h:31
virtual bool IsFigureVisible() const
Returns whether the object is visible or hidden in the image view.
virtual const CResult LoadFigureDXF(const wchar_t *pWcsPath=nullptr)
Loads a file with the .dxf extension.
virtual const CResult MakeValidFigure(Base::CFLString< wchar_t > strValue, Base::CFLString< wchar_t > &strValidFigure, bool bMsgBox=false)
Convert and return the value of the parameter's Figure string to the Figure String available on the o...
virtual bool IsMagnetToImageBoundaryMode() const
true if set to Magnet To Image Boundary mode, false if not set.
virtual ~CGUIPropertyItemViewImageFigure()
Default destructor.
virtual const CResult UpdateFigureObjectOnViewImage()
virtual CMFCPropertyGridProperty * CreateGridProperty() override
Gets grid properties.
virtual void ShowFigure(bool bShow, bool bCreate=true)
virtual CGUIViewImage * GetSelectedViewImage() const
Gets the selected image view from the linked image view list.
virtual const CResult LoadFigureGBR(const wchar_t *pWcsPath=nullptr)
Loads a file with the .gbr extension.
EAvailablePropertyItemViewImageFigureContextMenu GetAvailableContextMenu() const
Returns the available context menu.
virtual void SetInstantApplyMode(bool bSet, bool bFixMode) override
Specifies the Instant Apply mode in Figure. Default false. If the Instant Apply mode is set to true,...
CGUIPropertyItemViewImageFigure(CGUIPropertyItemViewImageList *pPIIVL)
Constructor.
void SetAvailableContextMenu(EAvailablePropertyItemViewImageFigureContextMenu eAvailableMenu=EAvailablePropertyItemViewImageFigureContextMenu_Default)
Sets the available context menu.
virtual const CResult SaveFigure(const wchar_t *pWcsFileNameWithPath=nullptr) const
Save the value of the Figure Property as a .fig file. If nullptr, open filedialog on the GUI to speci...
CGUIPropertyItemViewImageList * GetViewImageList()
Gets the image view list pointer to which the figure will be specified.
virtual void SetViewImage(const CGUIViewImage *pViewImage)
Sets the image view.
virtual void SetMagnetToImageBoundaryMode(bool bSet)
Specifies whether to set the Magnet To Image Boundary mode in Figure. Default true....
virtual bool IsMagnetAngleMode() const
true if set to Magnet Angle mode, false if not set.
virtual bool SetViewImageList(CGUIPropertyItemViewImageList *pPIIVL)
Sets the list of image views to which the figure will be specified.
CGUIPropertyItemViewImageFigure(const CGUIPropertyItemViewImageFigure &rhs)
Copy constructor.
virtual void SetMagnetAngleMode(bool bSet)
Specifies whether to set the Magnet Angle mode in Figure. Default true. If the Magnet Angle mode is s...
A class of image view.
Definition GUIViewImage.h:319
EFigureTemplateType
Template type of figure.
Definition DefinitionsFigure.h:302
EAvailablePropertyItemViewImageFigureContextMenu
Available context menu for CGUIPropertyItemViewImageFigure
Definition GUIDefinitions.h:3811