FRX SDK Documentation 2025 SP0
Loading...
Searching...
No Matches
prop.h
Go to the documentation of this file.
1#pragma once
2
3//
4// (C) Copyright 2005-2024 by Graebert GmbH.
5//
6// Permission to use, copy, modify, and distribute this software in
7// object code form for any purpose and without fee is hereby granted,
8// provided that the above copyright notice appears in all copies and
9// that both that copyright notice and the limited warranty and
10// restricted rights notice below appear in all supporting
11// documentation.
12//
13// GRAEBERT PROVIDES THIS PROGRAM "AS IS" AND WITH ALL FAULTS.
14// GRAEBERT SPECIFICALLY DISCLAIMS ANY IMPLIED WARRANTY OF
15// MERCHANTABILITY OR FITNESS FOR A PARTICULAR USE. GRAEBERT GMBH
16// DOES NOT WARRANT THAT THE OPERATION OF THE PROGRAM WILL BE
17// UNINTERRUPTED OR ERROR FREE.
18
19
20#ifdef _WIN64
21#include "include_x64/FxPiX_i.h"
22#else
23//#include "../_impl_include/include_x86/FxApplication_h_ac.h"
24#endif
25
26
27
28interface IAcPiCommandButton;
29#pragma pack (push, 8)
30#define PROPCAT_Nil -1
31#define PROPCAT_Misc -2
32#define PROPCAT_Font -3
33#define PROPCAT_Position -4
34#define PROPCAT_Appearance -5
35#define PROPCAT_Behavior -6
36#define PROPCAT_Data -7
37#define PROPCAT_List -8
38#define PROPCAT_Text -9
39#define PROPCAT_Scale -10
40#define PROPCAT_DDE -11
41#define PROPCAT_General -12
42#define PROPCAT_Mass -13
43#define PROPCAT_Pattern -14
44#define PROPCAT_DataPoints -15
45#define PROPCAT_Mesh -16
46#define PROPCAT_ImageAdjust -17
47#define PROPCAT_ControlPoints -18
48#define PROPCAT_PrimaryUnits -19
49#define PROPCAT_AltUnits -20
50#define PROPCAT_Fit -21
51#define PROPCAT_LinesArrows -22
52#define PROPCAT_Tolerances -23
53#define PROPCAT_Table -24
54#define PROPCAT_Geometry -25
55#define PROPCAT_Section -26
56#define PROPCAT_UnderlayAdjust -27
57#define PROPCAT_Solid_History -28
58#define PROPCAT_Fillet -29
59#define PROPCAT_Chamfer -30
60#define PROPCAT_3DVisualization -31
61#define PROPCAT_Table_Breaks -32
62#define PROPCAT_SURFACE_ASSOCIATIVITY -33
63#define PROPCAT_SURFACE_TRIM -34
64#define PROPCAT_ViewDefinition -35
65#define PROPCAT_Annotation -36
66#define PROPCAT_ReferenceData -37
67#define PROPCAT_Representation -38
68#define PROPCAT_PointcloudAdjust -39
69#define PROPCAT_GeomapImageAdjust -40
70
72{
73 UINT nDescID; //Alternate property name
74 DISPID dispid; //ID of the property
75 PROPCAT catid; //categoryID
76 UINT nCatNameID; //category Name
77 UINT nElementStrID; //expanded property name list (for pts, ex.)
78 UINT nPredefinedStrID; //IPerPropertyBrowsing enumeration strings
79 const ACHAR * predefinedValues; //IPerPropertyBrowsing enumeration values
80 unsigned short grouping; //expanded property name grouping
81 bool editable; //show property override
82 const CLSID* pclsidOther; //CLSID for Other.. combo item dlg (not used)
83 const CLSID* pclsidPropPage; //IPerPropertyBrowsing dialog CLSID
84 const IID* piidDispatch; //dispatch pointer for property
85 LPCOLESTR szEllipsesTxt; //IPerPropertyBrowsing display string
86};
87#define BEGIN_OPMPROP_MAP() \
88 static ACAD_OPMPROPMAP_ENTRY* GetOPMPropertyMap() \
89 { \
90 static ACAD_OPMPROPMAP_ENTRY pPropMap[] = \
91 {
92
93// DescriptionID, dispID, catagoryID, catagoryNameID, elements string list ID (semi-colon separator), predefined strings ID (semi-colon separator), predefined values, grouping, editable property, other, proppage
94#define OPMPROP_ENTRY(nDesID, dpid, ctid, ctNameID, elementsID, predefID, vals, grp, editable, other, clsid, ellipsesTxt) \
95 {nDesID, dpid, ctid, ctNameID, elementsID, predefID, vals, grp, editable, &other, &clsid, &IID_IDispatch, OLESTR(ellipsesTxt)},
96
97#define OPMPROP_CAT_ENTRY(nDesID, dpid, ctid, ctNameID) \
98 {nDesID, dpid, ctid, ctNameID, 0, 0, _ACRX_T(""), 0, 1, &IID_NULL, &IID_NULL, &IID_IDispatch, OLESTR("")},
99
100#define OPMPROP_DESC_ENTRY(nDesID, dpid) \
101 {nDesID, dpid, -2, 0, 0, 0, _ACRX_T(""), 0, 1, &IID_NULL, &IID_NULL, &IID_IDispatch, OLESTR("")},
102
103#define OPMPROP_PREDEFINED_ENTRY(nDesID, dpid, predefID, values, other) \
104 {nDesID, dpid, -2, 0, 0, predefID, values, 0, 1, &other, &IID_NULL, &IID_IDispatch, OLESTR("")},
105
106#define OPMPROP_ELEMENT_ENTRY(dpid, ctid, ctNameID, elementsID, grouping) \
107 {0, dpid, ctid, ctNameID, elementsID, 0, _ACRX_T(""), grouping, 1, &IID_NULL, &IID_NULL, &IID_IDispatch, OLESTR("")},
108
109#define OPMPROP_PAGE(nDesID, dpid, ctid, ctNameID, clsid) \
110 {nDesID, dpid, ctid, ctNameID, 0, 0, _ACRX_T(""), 0, 1, &IID_NULL, &clsid, &IID_IDispatch, OLESTR("")},
111
112#define END_OPMPROP_MAP() \
113 {0, 0, 0, 0, 0, 0, NULL, 0, 0, NULL, NULL, &IID_NULL, NULL} \
114 }; \
115 return pPropMap; \
116 }
117
119typedef int PROPCAT;
120
135
136// use this #define for the textcolor item in PROP_DISP_ENTRY in order to use the
137// default UI label color in the UI; any other value for textcolor is treated
138// as a COLORREF
139#ifndef PROP_TEXTCOLOR_DEFAULT
140#define PROP_TEXTCOLOR_DEFAULT 0x80000008
141#endif // PROP_TEXTCOLOR_DEFAULT
142
143#define BEGIN_PERPROPDISPLAY_MAP() \
144 static PER_PROP_DISP_ENTRY* GetPerPropDisplayArray() \
145 { \
146 static PER_PROP_DISP_ENTRY pPerPropDisplayArray[] = \
147 {
148
149#define PROP_DISP_ENTRY(dispid, progid, lpLeftIconRes, lpLeftIconType, \
150 lpEllipsisBmpRes, lpEllipsisBmpType, textcolor, \
151 bFullView, dwIntegralHeight, nWeight) \
152 {dispid, progid, lpLeftIconRes, lpLeftIconType, lpEllipsisBmpRes, \
153 lpEllipsisBmpType, textcolor, bFullView, \
154 dwIntegralHeight, nWeight}, \
155
156#define END_PERPROPDISPLAY_MAP() \
157 {-1, NULL, NULL, (UINT)PICTYPE_UNINITIALIZED, NULL, (UINT)PICTYPE_UNINITIALIZED, PROP_TEXTCOLOR_DEFAULT, false, (DWORD)-1, -1} \
158 }; \
159 return pPerPropDisplayArray; \
160 }
161
173
174#define BEGIN_CATCMDBTN_MAP() \
175 static CATCMDBTN_ENTRY * GetCmdBtnArray() \
176 { \
177 static CATCMDBTN_ENTRY pCatCmdBtnArray[] = \
178 {
179
180
181#define CATCMDBTN_MAP_ENTRY(nId, NameId, \
182 lpEnBtnBmpRes, lpEnBtnBmpType, lpDisBtnBmpRes, lpDisBtnBmpType, \
183 nStyle, pfnBtnProc) \
184 {nId, static_cast<UINT>(NameId), lpEnBtnBmpRes, static_cast<UINT>(lpEnBtnBmpType), lpDisBtnBmpRes, static_cast<UINT>(lpDisBtnBmpType), nStyle, pfnBtnProc},
185
186#define END_CATCMDBTN_MAP() \
187 {-1, 0u, NULL, static_cast<UINT>(PICTYPE_UNINITIALIZED), NULL, static_cast<UINT>(PICTYPE_UNINITIALIZED), NULL, NULL} \
188 }; \
189 return pCatCmdBtnArray; \
190 }
191
202
203#define BEGIN_CMDBTN_MAP() \
204 static CMDBTN_ENTRY * GetPropCmdBtnArray() \
205 { \
206 static CMDBTN_ENTRY pCmdBtnArray[] = \
207 {
208
209
210#define CMDBTN_MAP_ENTRY(NameId, lpEnBtnBmpRes, lpEnBtnBmpType, \
211 lpDisBtnBmpRes, lpDisBtnBmpType, nStyle, pfnBtnProc) \
212 {NameId, lpEnBtnBmpRes, lpEnBtnBmpType, lpDisBtnBmpRes, lpDisBtnBmpType, nStyle, pfnBtnProc},
213
214#define END_CMDBTN_MAP() \
215 {0, NULL, (UINT)PICTYPE_UNINITIALIZED, NULL, (UINT)PICTYPE_UNINITIALIZED, NULL, NULL} \
216 }; \
217 return pCmdBtnArray; \
218 }
219
228
229#define BEGIN_CAT_MAP() \
230 static CATEGORY_ENTRY* GetCatArray() \
231 { \
232 static CATEGORY_ENTRY pCatArray[] = \
233 {
234
235
236#define CATEGORY_MAP_ENTRY(nId, NameId, DescId, nParentId, nWeight) \
237 {nId, NameId, DescId, nParentId, nWeight},
238
239#define END_CAT_MAP() \
240 {-1, 0, 0, -1, -1} \
241 }; \
242 return pCatArray; \
243 }
244
245typedef std::vector<PER_PROP_DISP_ENTRY> PROP_DISP_VECTOR;
246typedef std::vector<CATCMDBTN_ENTRY> CATCMDBTN_VECTOR;
247typedef std::vector<CATEGORY_ENTRY> CATEGORY_VECTOR;
248typedef std::vector<CMDBTN_ENTRY> CMDBTN_VECTOR;
249
250#pragma pack (pop)
251
253interface IDynamicProperty;
254
std::vector< PER_PROP_DISP_ENTRY > PROP_DISP_VECTOR
Definition prop.h:245
std::vector< CATCMDBTN_ENTRY > CATCMDBTN_VECTOR
Definition prop.h:246
int PROPCAT
Definition prop.h:119
std::vector< CATEGORY_ENTRY > CATEGORY_VECTOR
Definition prop.h:247
BOOL(* BUTTONPROC)(IAcPiCommandButton *pButton, VARIANT Objects)
Definition prop.h:118
std::vector< CMDBTN_ENTRY > CMDBTN_VECTOR
Definition prop.h:248
AcRxClass * pClass
Definition prop.h:258
IDynamicProperty * pProp
Definition prop.h:259
ATL::_ATL_CREATORFUNC * pfnCreateInstance
Definition prop.h:256
const ACHAR * strCmd
Definition prop.h:257
IPropertySource * pPropSrc
Definition prop.h:261
const CLSID * pclsid
Definition prop.h:260
const CLSID * pclsidPropPage
Definition prop.h:83
UINT nPredefinedStrID
Definition prop.h:78
const IID * piidDispatch
Definition prop.h:84
const CLSID * pclsidOther
Definition prop.h:82
const ACHAR * predefinedValues
Definition prop.h:79
unsigned short grouping
Definition prop.h:80
LPCOLESTR szEllipsesTxt
Definition prop.h:85
PROPCAT m_CatID
Definition prop.h:164
const ACHAR * m_lpEnBtnBmpRes
Definition prop.h:166
const ACHAR * m_lpDisBtnBmpRes
Definition prop.h:168
long m_nStyle
Definition prop.h:170
UINT m_nBtnNameId
Definition prop.h:165
UINT m_nDisBtnBmpType
Definition prop.h:169
UINT m_nEnBtnBmpType
Definition prop.h:167
BUTTONPROC m_pfnBtnProc
Definition prop.h:171
UINT m_nNameId
Definition prop.h:223
long m_nWeight
Definition prop.h:226
PROPCAT m_CatID
Definition prop.h:222
UINT m_nDescId
Definition prop.h:224
PROPCAT m_ParentCatID
Definition prop.h:225
long m_nStyle
Definition prop.h:199
UINT m_nEnBtnBmpType
Definition prop.h:196
BUTTONPROC m_pfnBtnProc
Definition prop.h:200
const ACHAR * m_lpDisBtnBmpRes
Definition prop.h:197
UINT m_nBtnNameId
Definition prop.h:194
const ACHAR * m_lpEnBtnBmpRes
Definition prop.h:195
UINT m_nDisBtnBmpType
Definition prop.h:198
const ACHAR * m_ProgID
Definition prop.h:124
const ACHAR * m_lpLeftIconRes
Definition prop.h:125
UINT m_nLeftIconType
Definition prop.h:126
DISPID m_dispid
Definition prop.h:123
DWORD m_dwIntegralHeight
Definition prop.h:131
const ACHAR * m_lpEllipsisBmpRes
Definition prop.h:127
COLORREF m_TextColor
Definition prop.h:129
UINT m_nEllipsisBmpType
Definition prop.h:128