hi.p.hemmege
'SketchConstraints' certainly seems to be unusable.
I was interested in 'Selection Filters', so I made the following code.
import adsk.core, adsk.fusion, traceback
def InitFilterList():
return [
'Bodies',
'SolidBodies',
'SurfaceBodies',
'MeshBodies',
'Faces',
'SolidFaces',
'SurfaceFaces',
'PlanarFaces',
'CylindricalFaces',
'ConicalFaces',
'SphericalFaces',
'ToroidalFaces',
'SplineFaces',
'Edges',
'LinearEdges',
'CircularEdges',
'EllipticalEdges',
'TangentEdges',
'NonTangentEdges',
'Vertices',
'RootComponents',
'Occurrences',
'Sketches',
'SketchConstraints',
'Profiles',
'Texts',
'SketchCurves',
'SketchLines',
'SketchCircles',
'SketchPoints',
'ConstructionPoints',
'ConstructionLines',
'ConstructionPlanes',
'Features',
'Canvases',
'Decals',
'JointOrigins',
'Joints'
]
def run(context):
app = adsk.core.Application.get()
ui = app.userInterface
filterLst = InitFilterList()
print('')
print('** Fusion360 ver:{} **'.format(app.version))
for filter in filterLst:
try:
ui.selectEntity('Select / ESC-Cancel', filter)
print('{}'.format(filter).ljust(20,' ')+':ok')
except RuntimeError:
print('{}'.format(filter).ljust(20,' ')+':RuntimeError')
except:
pass
The results are as follows.
** Fusion360 ver:2.0.4126 **
Bodies :ok
SolidBodies :ok
SurfaceBodies :ok
MeshBodies :ok
Faces :ok
SolidFaces :ok
SurfaceFaces :ok
PlanarFaces :ok
CylindricalFaces :ok
ConicalFaces :ok
SphericalFaces :RuntimeError
ToroidalFaces :ok
SplineFaces :ok
Edges :ok
LinearEdges :ok
CircularEdges :ok
EllipticalEdges :ok
TangentEdges :ok
NonTangentEdges :ok
Vertices :ok
RootComponents :ok
Occurrences :ok
Sketches :ok
SketchConstraints :ok
Profiles :ok
Texts :ok
SketchCurves :ok
SketchLines :ok
SketchCircles :ok
SketchPoints :ok
ConstructionPoints :ok
ConstructionLines :ok
ConstructionPlanes :ok
Features :ok
Canvases :ok
Decals :ok
JointOrigins :ok
Joints :ok
'SphericalFaces' will not function, it will result in an error.
https://forums.autodesk.com/t5/fusion-360-ri-ben-yu/api-selection-filters-no-sphericalfaces-ga-ji-ne...
Even if it is described in the Japanese forum, it is hardly to be opponent.