FLImaging 7.4.28.2
GUIPropertyItemFigure.h
1#pragma once
9
10#include "GUIPropertyItemBase.h"
11#include "DefinitionsGUI.h"
12
13#include <future>
14#include <deque>
15
17namespace FLImaging
18{
20 namespace GUI
21 {
24
33 {
44
55
66
77
88
99
110
121
132
143
154
165
176
187
198
209
220
231
240
249
258
267
276
285
294
302
310
311
322
333
344
355
366
377
385
393 };
394
396 {
397 return static_cast<EAvailableFigureDeclType>(static_cast<int64_t>(a) | static_cast<int64_t>(b));
398 }
399
401 {
402 return static_cast<EAvailableFigureDeclType>(static_cast<int64_t>(a) & static_cast<int64_t>(b));
403 }
404
406 {
407 return a = a | b;
408 }
409
411 {
412 return a = a & b;
413 }
414
416 {
417 return static_cast<EAvailableFigureDeclType>(~static_cast<int64_t>(a));
418 }
419
420 inline bool operator!(EAvailableFigureDeclType a)
421 {
422 return static_cast<bool>(!static_cast<int64_t>(a));
423 }
424
433 {
441
449
457
465
473
481
489 };
490
492 {
493 return static_cast<EAvailableFigureTemplateType>(static_cast<int64_t>(a) | static_cast<int64_t>(b));
494 }
495
497 {
498 return static_cast<EAvailableFigureTemplateType>(static_cast<int64_t>(a) & static_cast<int64_t>(b));
499 }
500
502 {
503 return a = a | b;
504 }
505
507 {
508 return a = a & b;
509 }
510
512 {
513 return static_cast<EAvailableFigureTemplateType>(~static_cast<int64_t>(a));
514 }
515
516 inline bool operator!(EAvailableFigureTemplateType a)
517 {
518 return static_cast<bool>(!static_cast<int64_t>(a));
519 }
520
529 {
537
545
547 // Not supported yet
548
556
564
573
581
589
597
605
613 };
614
616 {
617 return static_cast<EAvailableFigureTransformType>(static_cast<int64_t>(a) | static_cast<int64_t>(b));
618 }
619
621 {
622 return static_cast<EAvailableFigureTransformType>(static_cast<int64_t>(a) & static_cast<int64_t>(b));
623 }
624
626 {
627 return a = a | b;
628 }
629
631 {
632 return a = a & b;
633 }
634
636 {
637 return static_cast<EAvailableFigureTransformType>(~static_cast<int64_t>(a));
638 }
639
640 inline bool operator!(EAvailableFigureTransformType a)
641 {
642 return static_cast<bool>(!static_cast<int64_t>(a));
643 }
644
653 {
654 public:
662
670
682
690
704
716
728
741 virtual bool SetAvailableFigureDeclType(EAvailableFigureDeclType eAvailableFigureDeclType);
742
754
767 virtual bool SetAvailableFigureTemplateType(EAvailableFigureTemplateType eAvailableFigureTemplateType);
768
780
793 virtual bool SetAvailableFigureTransformType(EAvailableFigureTransformType eAvailableFigureTransformType);
794
806
819 virtual bool IsValidValue(Base::CFLString<wchar_t> flstrValue) const;
820
833 virtual bool IsValidValue(const FLImaging::Foundation::CFLFigure* pFlf) const;
834
852
865 virtual bool IsValidValue(FLImaging::Foundation::EFigureDeclType eFigureDeclType) const;
866
879 virtual bool IsValidValue(FLImaging::Foundation::EFigureTemplateType eFigureTemplateType) const;
880
900 virtual const CResult MakeValidFigure(Base::CFLString<wchar_t> strValue, Base::CFLString<wchar_t>& strValidFigure, bool bMsgBox = false);
901
915
927
942 virtual bool SetRealtimeEventCallback(CPropertyCallback* pCallback, bool bAutoDestroy = true);
943
955
970 virtual bool SetShowCallback(CPropertyCallback* pCallback, bool bAutoDestroy = true);
971
983
998 virtual bool SetConfirmCallback(CPropertyCallback* pCallback, bool bAutoDestroy = true);
999
1011
1026 virtual bool SetCancelCallback(CPropertyCallback* pCallback, bool bAutoDestroy = true);
1027
1039
1054 virtual bool SetDeleteCallback(CPropertyCallback* pCallback, bool bAutoDestroy = true);
1055
1067
1078 virtual void SetInstantApplyMode(bool bSet, bool bFixMode);
1079
1088 virtual bool IsInstantApplyMode() const;
1089
1098 virtual bool IsInstantApplyModeFixed() const;
1099
1112 virtual const CResult LoadFigure(const wchar_t* pWcsPath = nullptr);
1113
1126 virtual const CResult SaveFigure(const wchar_t* pWcsFileNameWithPath = nullptr) const;
1127
1136 virtual void SetFigureAutoHideMode(bool bAutoHide);
1137
1146 virtual bool GetFigureAutoHideMode() const;
1147
1158 virtual void ShowFigure(bool bShow, bool bCreate = true);
1159
1168 virtual bool IsFigureVisible() const;
1169
1178 virtual void SetView(const CGUIViewImageBase* pView);
1179
1203
1213 virtual void ShowUnavailableContextMenu(bool bShow = false);
1214
1225
1235 virtual void EnableValueEdit(bool bEnable);
1236
1246 virtual bool IsValueEditEnabled() const;
1247
1248 virtual bool SetOrigValue(const Base::CFLString<wchar_t>& strValue) override;
1249 virtual bool SetValue(Base::CFLString<wchar_t> strValue, bool bInvokeCallback = true) override;
1250 virtual void Enable(bool bEnable) override;
1251
1252 protected:
1253 void InternalSetInstantApplyMode(bool bSet, bool bFixMode);
1254 virtual bool GetValidFigureType(Base::CFLString<wchar_t>& strValue);
1255 virtual const CResult CreateFigure(const Foundation::CFLFigure* pFlf, Foundation::EFigureTemplateType eTemplateType, Foundation::CFLFigure** ppFlfOut) const;
1256 Foundation::CFLFigure* GetValidFigure(const Foundation::CFLFigure* pFlf) const;
1257 const CResult InitializeThread();
1258 bool IsThreadInitialized();
1259 static void RunThread(CGUIPropertyItemFigure* pFigureProperty, std::future<void>** pContext);
1260
1261 public:
1262 const CResult TerminateThread();
1263
1264 enum ECallbackType
1265 {
1266 ECallbackType_None = 0,
1267 ECallbackType_Confirm,
1268 ECallbackType_Delete,
1269 ECallbackType_Cancel,
1270 ECallbackType_RealtimeEvent,
1271 ECallbackType_Show,
1272 };
1273
1274 protected:
1275 Base::CFLString<wchar_t> m_strLastOKValue;
1277 EAvailableFigureDeclType m_eAvailableFigureDeclType;
1278 EAvailableFigureTemplateType m_eAvailableFigureTemplateType;
1279 EAvailableFigureTransformType m_eAvailableFigureTransformType;
1280
1281 CPropertyCallback* m_pRealtimeCallback;
1282 bool m_bRealtimeCallbackAutoDestroy;
1283
1284 CPropertyCallback* m_pShowCallback;
1285 bool m_bShowCallbackAutoDestroy;
1286
1287 CPropertyCallback* m_pConfirmCallback;
1288 bool m_bConfirmCallbackAutoDestroy;
1289
1290 CPropertyCallback* m_pCancelCallback;
1291 bool m_bCancelCallbackAutoDestroy;
1292
1293 CPropertyCallback* m_pDeleteCallback;
1294 bool m_bDeleteCallbackAutoDestroy;
1295
1296 std::deque<Base::CFLString<wchar_t>>& m_deqProcedureParameterString;
1297 std::future<void>* m_pProcedureThread;
1298
1299 volatile bool m_bThreadRunning;
1300 volatile bool m_bThreadInitialized;
1301 volatile bool m_bThreadTerminated;
1302
1303 CGUIViewImageBase* m_pView;
1304
1305 bool m_bEnableValueEdit;
1306 bool m_bEnableInstantApplyMode;
1307 bool m_bFixInstantApplyMode;
1308 bool m_bFigureAutoHideMode;
1309 bool m_bShowUnavailableContextMenu;
1310
1311 friend class CGUIViewImage;
1312 friend class CGUIView3DToolManagerROI;
1313 };
1314 }
1315}
Template type 의 문자열 클래스
Definition FLString.h:34
FLImaging 모듈의 수행 결과 객체
Definition ResultsDef.h:1676
도형을 표현하는 클래스의 기저 클래스
Definition FLFigure.h:27
virtual bool SetAvailableFigureTransformType(EAvailableFigureTransformType eAvailableFigureTransformType)
이용 가능한 Figure 변형 타입을 지정합니다.
virtual const CResult SaveFigure(const wchar_t *pWcsFileNameWithPath=nullptr) const
Figure Property 의 값을 .fig 파일로 저장합니다. 만약 nullptr 일 경우 GUI 상에서 file dialog 를 열어 파일 경로를 지정합니다.
virtual bool IsValidValue(Base::CFLString< wchar_t > flstrValue) const
매개변수의 문자열이 해당 객체에서 이용 가능한 Figure 인지 여부를 나타냅니다.
virtual ~CGUIPropertyItemFigure()
기본 소멸자
virtual bool SetOrigValue(const Base::CFLString< wchar_t > &strValue) override
this의 원래 값을 설정합니다.
virtual EAvailableFigureDeclType GetAvailableFigureDeclType() const
이용 가능한 Figure 의 형태를 얻어 옵니다.
virtual CPropertyCallback * GetShowCallback() const
Figure 를 Show 하여 View 에 띄웠을 때 실행되는 함수 콜백 포인터를 얻어 옵니다.
virtual EAvailableFigureTemplateType GetAvailableFigureTemplateType() const
이용 가능한 Figure 변수 자료형을 얻어 옵니다.
virtual bool SetAvailableFigureTemplateType(EAvailableFigureTemplateType eAvailableFigureTemplateType)
이용 가능한 Figure 의 변수 자료형을 지정합니다.
virtual bool SetLastOKValue(Base::CFLString< wchar_t > strValue)
가장 최근에 OK 로 확정한 Figure 값을 지정합니다.
virtual bool IsValidValue(FLImaging::Foundation::EFigureDeclType eFigureDeclType, FLImaging::Foundation::EFigureTemplateType eFigureTemplateType) const
매개변수의 EFigureDeclType, EFigureTemplateType 값이 해당 객체에서 이용 가능한 Figure 인지 여부를 나타냅니다.
virtual const CResult MakeValidFigure(Base::CFLString< wchar_t > strValue, Base::CFLString< wchar_t > &strValidFigure, bool bMsgBox=false)
매개변수의 Figure String 값을 해당 객체에서 이용 가능한 Figure Figure String 으로 변환하여 반환합니다. 예를 들어 Template Type 을 Int T...
virtual bool IsUnavailableContextMenuVisible() const
비활성화된 컨텍스트 메뉴의 숨김 또는 보이기 처리 여부를 반환합니다.
CGUIPropertyItemFigure(const CGUIPropertyItemFigure &rhs)
복사 생성자
virtual CPropertyCallback * GetDeleteCallback() const
Figure 가 삭제될 때 실행되는 함수 콜백 포인터를 얻어 옵니다.
virtual bool IsValidValue(FLImaging::Foundation::EFigureTemplateType eFigureTemplateType) const
매개변수의 EFigureTemplateType 값이 해당 객체에서 이용 가능한 Figure인지 여부를 나타냅니다.
virtual bool IsValueEditEnabled() const
현재 값(Value) 필드가 편집 가능한 상태인지 여부를 반환합니다.
virtual CGUIViewImageBase * GetSelectedView() const
연결된 뷰 리스트에서 선택된 뷰를 얻어 옵니다.
virtual bool SetConfirmCallback(CPropertyCallback *pCallback, bool bAutoDestroy=true)
Figure 변경 사항을 확정할 때 실행되는 함수 콜백을 지정합니다.
virtual CPropertyCallback * GetConfirmCallback() const
Figure 변경 사항을 확정할 때 실행되는 함수 콜백 포인터를 얻어 옵니다.
virtual bool IsInstantApplyModeFixed() const
뷰에서 Instant Apply Mode 속성 변경을 허용할 경우 true, 허용하지 않을 경우 false 입니다.
virtual bool IsInstantApplyMode() const
Instant Apply 모드로 설정한 경우 true, 설정하지 않은 경우 false 입니다.
virtual void SetInstantApplyMode(bool bSet, bool bFixMode)
Figure 의 Instant Apply 모드를 지정합니다. 기본값 false 입니다. Instant Apply 모드가 true 로 지정된 경우, OK 메뉴를 누르지 않아도 뷰 위에...
virtual bool SetDeleteCallback(CPropertyCallback *pCallback, bool bAutoDestroy=true)
Figure 가 삭제될 때 실행되는 함수 콜백을 지정합니다.
virtual bool SetShowCallback(CPropertyCallback *pCallback, bool bAutoDestroy=true)
Figure 를 Show 하여 View 에 띄웠을 때 실행되는 함수 콜백을 지정합니다.
virtual Base::CFLString< wchar_t > GetLastOKValue() const
가장 최근에 OK 로 확정한 Figure 값을 얻어 옵니다.
virtual void SetView(const CGUIViewImageBase *pView)
뷰를 설정합니다.
virtual void ShowFigure(bool bShow, bool bCreate=true)
virtual bool GetFigureAutoHideMode() const
부모 프로퍼티 창이 kill focus 상태가 되었을 때 뷰 위에 띄워진 Figure 객체에 대한 자동 숨김 처리 여부를 반환합니다. 기본 설정값은 true 입니다.
virtual CPropertyCallback * GetCancelCallback() const
Figure 변경 사항을 취소할 때 실행되는 함수 콜백 포인터를 얻어 옵니다.
virtual bool SetRealtimeEventCallback(CPropertyCallback *pCallback, bool bAutoDestroy=true)
Figure 의 이동, 회전 등의 변화가 일어날 때마다 실행되는 함수 콜백을 지정합니다.
CGUIPropertyItemViewListBase * GetViewList()
Figure 가 지정될 뷰 리스트 포인터를 얻어 옵니다.
virtual void SetFigureAutoHideMode(bool bAutoHide)
부모 프로퍼티 창이 kill focus 상태가 되었을 때 뷰 위에 띄워진 Figure 객체에 대한 자동 숨김 처리 여부를 지정합니다. 기본 설정값은 true 입니다.
virtual bool SetViewList(CGUIPropertyItemViewListBase *pPIIVL)
Figure 가 지정될 뷰 리스트를 설정합니다.
virtual void Enable(bool bEnable) override
객체를 활성화 또는 비활성화합니다.
virtual EAvailableFigureTransformType GetAvailableFigureTransformType() const
이용 가능한 Figure 변형 타입을 얻어 옵니다.
virtual const CResult UpdateFigureObjectOnView()
virtual bool IsFigureVisible() const
Figure 객체가 뷰에서 보이는 상태인지, 숨겨진 상태인지 여부를 반환합니다.
virtual CPropertyCallback * GetRealtimeEventCallback() const
Figure 의 이동, 회전 등의 변화가 일어날 때마다 실행되는 함수 콜백 포인터를 얻어 옵니다.
CGUIPropertyItemFigure(CGUIPropertyItemViewListBase *pPIIVL)
생성자
virtual bool IsValidValue(FLImaging::Foundation::EFigureDeclType eFigureDeclType) const
매개변수의 EFigureDeclType 값이 해당 객체에서 이용 가능한 Figure인지 여부를 나타냅니다.
virtual bool IsValidValue(const FLImaging::Foundation::CFLFigure *pFlf) const
매개변수의 CFLFigure 객체가 해당 객체에서 이용 가능한 Figure 인지 여부를 나타냅니다.
virtual bool SetValue(Base::CFLString< wchar_t > strValue, bool bInvokeCallback=true) override
this에 값을 설정합니다.
virtual void EnableValueEdit(bool bEnable)
항목의 활성화(Enable)나 읽기 전용 상태(ReadOnly)와는 별개로, 값(Value) 필드의 편집 가능 여부만을 설정합니다.
virtual const CResult LoadFigure(const wchar_t *pWcsPath=nullptr)
.fig 확장자를 가진 파일을 불러옵니다.
virtual bool SetCancelCallback(CPropertyCallback *pCallback, bool bAutoDestroy=true)
Figure 변경 사항을 취소할 때 실행되는 함수 콜백을 지정합니다.
virtual void ShowUnavailableContextMenu(bool bShow=false)
비활성화된 컨텍스트 메뉴의 숨김 또는 보이기 처리 여부를 설정합니다. SetAvailableView3DContextMenu()` 등으로 할 수 있습니다.
virtual bool SetAvailableFigureDeclType(EAvailableFigureDeclType eAvailableFigureDeclType)
이용 가능한 Figure 의 형태를 지정합니다.
뷰 리스트 프로퍼티 아이템 베이스 클래스
Definition GUIPropertyItemViewListBase.h:28
뷰의 기반 클래스
Definition GUIViewImageBase.h:44
이미지 뷰 클래스
Definition GUIViewImage.h:319
EFigureDeclType
도형의 타입
Definition DefinitionsFigure.h:33
EFigureTemplateType
도형의 변수 자료형
Definition DefinitionsFigure.h:390
Definition D2DObject.h:12
EAvailableFigureDeclType
사용 가능한 Figure의 형태를 설정합니다. CGUIPropertyItemFigure::SetAvailableFigureDeclType() 함수를 통해 설정할 수 있습니다.
Definition GUIPropertyItemFigure.h:33
@ EAvailableFigureDeclType_ComplexRegion
다각형
Definition GUIPropertyItemFigure.h:153
@ EAvailableFigureDeclType_PointArray
점 배열
Definition GUIPropertyItemFigure.h:208
@ EAvailableFigureDeclType_Circle_Segment
Circle Segment
Definition GUIPropertyItemFigure.h:257
@ EAvailableFigureDeclType_QuadrilateralSolid3
비정형 육면체
Definition GUIPropertyItemFigure.h:376
@ EAvailableFigureDeclType_Ellipse_Sector
Ellipse Sector
Definition GUIPropertyItemFigure.h:275
@ EAvailableFigureDeclType_Default_3D
EAvailableFigureDeclType_Default_3D 는 모든 3D 객체와 Rect 를 포함합니다.
Definition GUIPropertyItemFigure.h:392
@ EAvailableFigureDeclType_Point3
3차원 점
Definition GUIPropertyItemFigure.h:321
@ EAvailableFigureDeclType_Triangle3
3차원 삼각형
Definition GUIPropertyItemFigure.h:343
@ EAvailableFigureDeclType_Doughnut
도넛
Definition GUIPropertyItemFigure.h:175
@ EAvailableFigureDeclType_Circle
Definition GUIPropertyItemFigure.h:87
@ EAvailableFigureDeclType_BezierQuarticCurve
베지에 4차 곡선
Definition GUIPropertyItemFigure.h:142
@ EAvailableFigureDeclType_BezierCubicCurve
베지에 3차 곡선
Definition GUIPropertyItemFigure.h:131
@ EAvailableFigureDeclType_Array
도형 배열
Definition GUIPropertyItemFigure.h:164
@ EAvailableFigureDeclType_Ellipse_Segment
Ellipse Segment
Definition GUIPropertyItemFigure.h:284
@ EAvailableFigureDeclType_Quad3
3차원 사각형
Definition GUIPropertyItemFigure.h:354
@ EAvailableFigureDeclType_Ellipse
타원
Definition GUIPropertyItemFigure.h:98
@ EAvailableFigureDeclType_Quad
사각형
Definition GUIPropertyItemFigure.h:76
@ EAvailableFigureDeclType_Text
특정 좌표에서 문자열을 나타내는 도형
Definition GUIPropertyItemFigure.h:230
@ EAvailableFigureDeclType_Circle_Arc
Circle Arc
Definition GUIPropertyItemFigure.h:239
@ EAvailableFigureDeclType_All
All 값은 모든 Figure DeclType이 유효합니다.
Definition GUIPropertyItemFigure.h:301
@ EAvailableFigureDeclType_Doughnut_Sector
Doughnut Sector
Definition GUIPropertyItemFigure.h:293
@ EAvailableFigureDeclType_Rect
직사각형
Definition GUIPropertyItemFigure.h:65
@ EAvailableFigureDeclType_Circle_Sector
Circle Sector
Definition GUIPropertyItemFigure.h:248
@ EAvailableFigureDeclType_CubicSpline
큐빅 곡선
Definition GUIPropertyItemFigure.h:109
@ EAvailableFigureDeclType_Triangle
2차원 삼각형
Definition GUIPropertyItemFigure.h:219
@ EAvailableFigureDeclType_TriangularSolid3
비정형 오면체
Definition GUIPropertyItemFigure.h:365
@ EAvailableFigureDeclType_All_3D
EAvailableFigureDeclType_All_3D 는 모든 3D 객체와 Rect 를 포함합니다.
Definition GUIPropertyItemFigure.h:384
@ EAvailableFigureDeclType_BezierQuadraticCurve
베지에 2차 곡선
Definition GUIPropertyItemFigure.h:120
@ EAvailableFigureDeclType_Region
영역
Definition GUIPropertyItemFigure.h:186
@ EAvailableFigureDeclType_Line
직선
Definition GUIPropertyItemFigure.h:54
@ EAvailableFigureDeclType_Ellipse_Arc
Ellipse Arc
Definition GUIPropertyItemFigure.h:266
@ EAvailableFigureDeclType_RoundRect
둥근 직사각형
Definition GUIPropertyItemFigure.h:197
@ EAvailableFigureDeclType_Default
EAvailableFigureDeclType_Default 는 3D 객체와 Text 를 제외한 모든 Figure DeclType 입니다.
Definition GUIPropertyItemFigure.h:309
@ EAvailableFigureDeclType_Frustum3
절두체
Definition GUIPropertyItemFigure.h:332
@ EAvailableFigureDeclType_Point
Definition GUIPropertyItemFigure.h:43
EAvailableFigureTemplateType
사용 가능한 Figure의 자료형을 설정합니다. CGUIPropertyItemFigure::SetAvailableFigureTemplateType() 함수를 통해 설정할 수 있습니다...
Definition GUIPropertyItemFigure.h:433
@ EAvailableFigureTemplateType_Mixed
Mixed
Definition GUIPropertyItemFigure.h:472
@ EAvailableFigureTemplateType_Default
Default
Definition GUIPropertyItemFigure.h:488
@ EAvailableFigureTemplateType_All
모든 Template Type
Definition GUIPropertyItemFigure.h:480
@ EAvailableFigureTemplateType_Float
Float
Definition GUIPropertyItemFigure.h:456
@ EAvailableFigureTemplateType_Double
Double
Definition GUIPropertyItemFigure.h:464
@ EAvailableFigureTemplateType_Int64
Int64
Definition GUIPropertyItemFigure.h:448
@ EAvailableFigureTemplateType_Int32
Int32
Definition GUIPropertyItemFigure.h:440
std::function< void(CGUIPropertyItemBase *, Base::CFLString< wchar_t > &, const Base::CFLString< wchar_t > &)> CPropertyCallback
SetValue() 내부에서 호출되는 값 변경 콜백입니다.
Definition GUIPropertyItemBase.h:192
EAvailableFigureTransformType
사용 가능한 Figure의 변형 타입을 설정합니다. CGUIPropertyItemFigure::SetAvailableFigureTransformType() 함수를 통해 설정할 수 있...
Definition GUIPropertyItemFigure.h:529
@ EAvailableFigureTransformType_Inflate
확대 (현재 지원하지 않음)
Definition GUIPropertyItemFigure.h:555
@ EAvailableFigureTransformType_Warp
Warp 기능
Definition GUIPropertyItemFigure.h:596
@ EAvailableFigureTransformType_Extend
늘이기 (현재 지원하지 않음)
Definition GUIPropertyItemFigure.h:563
@ EAvailableFigureTransformType_All
모든 변형 타입
Definition GUIPropertyItemFigure.h:604
@ EAvailableFigureTransformType_Reduce
Region 및 PointArray 를 근사화하여 점 개수 줄이기 연산
Definition GUIPropertyItemFigure.h:580
@ EAvailableFigureTransformType_Split
Rect를 쪼개서 FigureArray로 만드는 기능
Definition GUIPropertyItemFigure.h:588
@ EAvailableFigureTransformType_None
아무 변형도 허용하지 않음
Definition GUIPropertyItemFigure.h:536
@ EAvailableFigureTransformType_Default
기본값
Definition GUIPropertyItemFigure.h:612
@ EAvailableFigureTransformType_Rotate
회전
Definition GUIPropertyItemFigure.h:544
@ EAvailableFigureTransformType_Scale
크기 변형 (현재 지원하지 않음)
Definition GUIPropertyItemFigure.h:571