an hour ago
Archicad 26 C++ API, Windows 11.
We create Interior Elevations with ACAPI_Element_CreateExt. After create we need to set the visible plan distance between the solid marker/view line and the dashed depth line. A user can drag that gap (tracker shows a millimetre). We cannot keep a value written from code.
Live dump of one selected Interior Elevation (id 5, name " - 01", one segment):
ieCreationSegmentHorizontalOffset / ieOffset = 0
ieCreationSegmentDepth / ieDepth = 0
Memo has all three bags, 2 points each:
sectionSegmentMainCoords = view / solid marker line
sectionSegmentDistCoords = marked distant, 500 mm from view
sectionSegmentDepthCoords = depth / dashed, 1000 mm from view
iePolygonEdge coincides with the depth line.
Live horizRange = APIHorRange_Infinite (tool default was Limited).
nMainCoord = nDistCoord = nDepthCoord = 2.
So the millimetre on screen is not the create-only scalars. It is the distance between memo coordinate polylines.
What already failed on similar elements:
1. Writing only ieCreationSegmentDepth at create: finished field 0, live gap unchanged.
2. ACAPI_Element_ChangeExt of dist or main coords: error -2130313112, or 0 with no keep.
3. APIEdit_Drag of the parent: 0, no keep.
4. Replaying the hand APIEdit_Stretch from GetTranParams: 0, no keep.
Hand drag of the isolated segment hotspot does move the line.
Questions:
1. After create, is the supported way to set that gap a ChangeExt of sectionSegmentDepthCoords with memo mask APIMemoMask_SectionDepthCoords? Which subIndex: 0 or ACAPI_ELEMENT_CHANGEEXT_ALLSEGMENTS?
2. Must we also rewrite iePolygonEdge when it currently sits on the depth line?
3. Must horizRange be APIHorRange_Limited for the depth line to be writable?
4. Why do the create-only scalars stay 0 on Get after a successful CreateExt? Are they write-only, and if so what is the post-create write?
5. Markers cannot be changed alone. We already follow that. Does the depth line still require ChangeExt of the parent Interior Elevation together with the marker objects?
We can attach a full segment dump if useful.
Operating system used: Windows 11