Fem: Allow clipping plane in edit mode
This commit is contained in:
committed by
Max Wilfinger
parent
f44af0929f
commit
2d531cc21b
@@ -107,6 +107,11 @@ class _ClippingPlaneAdd(CommandManager):
|
||||
)
|
||||
self.is_active = "with_document"
|
||||
|
||||
def GetResources(self):
|
||||
resources = super().GetResources()
|
||||
resources["CmdType"] = "ForEdit | Alter3DView"
|
||||
return resources
|
||||
|
||||
def Activated(self):
|
||||
from pivy import coin
|
||||
from femtools.femutils import getBoundBoxOfAllDocumentShapes
|
||||
@@ -163,6 +168,11 @@ class _ClippingPlaneRemoveAll(CommandManager):
|
||||
)
|
||||
self.is_active = "with_document"
|
||||
|
||||
def GetResources(self):
|
||||
resources = super().GetResources()
|
||||
resources["CmdType"] = "ForEdit | Alter3DView"
|
||||
return resources
|
||||
|
||||
def Activated(self):
|
||||
line1 = "for node in list(sg.getChildren()):\n"
|
||||
line2 = " if isinstance(node, coin.SoClipPlane):\n"
|
||||
|
||||
Reference in New Issue
Block a user