View Issue Details

IDProjectCategoryView StatusLast Update
0003374SketcherFeaturepublic2018-10-06 15:20
ReporterpaulleeAssigned To 
PrioritynormalSeverityfeatureReproducibilityhave not tried
Status newResolutionopen 
PlatformAllOSAllOS VersionAll
Product Version0.17 
Target Version0.19Fixed in Version 
Summary0003374: Sketch + Gui.SelectionEx() - - - Identify Geometry Index Outside Edit Mode
DescriptionDiscussion Thread in Forum ... (seem more than Sketcher, 'Selection' function?)
"Sketch - Identify Geometry Index (inside and outside Edit Mode)"

Problem is:-
Gui.SelectionEx()[0].SubElementNames would provide different Edges 'name' Inside and Outside Sketch Edit mode ...See screencaptures
  1. Say a rectangle inside sketch, Edges index report are, Anti-Clockwise, 1-2-3-4 [EDIT] ('1' being the edge at the 'bottom')
  2. Edge 2 is construction
  3. Exiting Edit mode, same code seem report the Wire edge number created, INSTEAD of the Geometry inside edit mode
  4. So, only 3 edges form a wire Outside edit mode
  5. Edges nos. BECOME (report here as it is in same direction) 1-(none)-3-2 [EDIT] 3-none-1-2 (same edge by edge)
  6. Or ClockWire as 1-2-3 [EDIT] Top Edge is '1' now
  7. Using the latter 'index' in sketch.geometry[index] would report wrong edge (following Geometry Index) information

So, Solution I haven't found:-
  1. Outside Edit Mode, how can I without enter edit mode, a script to identify the selected edge's (the wire shape I guess) internal Edge geometry Index?

Feature Request

to return the same name or index as in sketch.geometry[i]


Additional InformationOS: Linux
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.17.13375 (Git) AppImage
Build type: None
Branch: master
Hash: 2bfea410fce1434fec0f853b032549aa2cd3c47e
Python version: 2.7.6
Qt version: 4.8.6
Coin version: 4.0.0a
OCC version: 7.1.0
Locale: English/HongKong (en_HK)
TagsNo tags attached.



2018-03-14 19:00


Test_ Sketch_ Identify Geometry Index.fcstd (3,408 bytes)


2018-06-07 18:58

manager   ~0011363

@realthunder has implemented this in his fork:

Issue History

Date Modified Username Field Change
2018-03-14 19:00 paullee New Issue
2018-03-14 19:00 paullee File Added: Test_ Sketch_ Identify Geometry Index.fcstd
2018-06-07 18:58 Kunda1 Note Added: 0011363
2018-10-06 14:55 abdullah Product Version 0.17 => 0.19
2018-10-06 15:20 abdullah Product Version 0.19 => 0.17
2018-10-06 15:20 abdullah Target Version => 0.19