Merge pull request #24262 from mnesarco/pyi-fixes-1

This commit is contained in:
Chris Hennes
2025-11-29 20:23:37 -06:00
committed by GitHub
250 changed files with 2821 additions and 2051 deletions

View File

@@ -1,6 +1,10 @@
from Base.Metadata import export, constmethod
# SPDX-License-Identifier: LGPL-2.1-or-later
from __future__ import annotations
from Base.Metadata import export
from Part.BodyBase import BodyBase
from typing import Final, overload
from typing import Final
@export(
Include="Mod/PartDesign/App/Body.h",
@@ -17,9 +21,8 @@ class Body(BodyBase):
VisibleFeature: Final[object] = ...
"""Return the visible feature of this body"""
def insertObject(self, feature: object, target: object, after: bool = False) -> None:
def insertObject(self, feature: object, target: object, after: bool = False, /) -> None:
"""
insertObject(feature, target, after=False)
Insert the feature into the body after the given feature.
@param feature The feature to insert into the body

View File

@@ -1,3 +1,7 @@
# SPDX-License-Identifier: LGPL-2.1-or-later
from __future__ import annotations
from Base.Metadata import export
from Part.PartFeature import PartFeature
from typing import Optional, overload

View File

@@ -1,6 +1,9 @@
# SPDX-License-Identifier: LGPL-2.1-or-later
from __future__ import annotations
from Base.Metadata import export
from Gui.ViewProviderPartExt import ViewProviderPartExt
from typing import Final, overload
@export(
Include="Mod/PartDesign/Gui/ViewProvider.h",
@@ -16,17 +19,17 @@ class ViewProvider(ViewProviderPartExt):
Licence: LGPL
"""
def setBodyMode(self, mode: bool) -> None:
def setBodyMode(self, mode: bool, /) -> None:
"""
setBodyMode(bool): body mode means that the object is part of a body
body mode means that the object is part of a body
and that the body is used to set the visual properties, not the features. Hence
setting body mode to true will hide most viewprovider properties.
"""
...
def makeTemporaryVisible(self, visible: bool) -> None:
def makeTemporaryVisible(self, visible: bool, /) -> None:
"""
makeTemporaryVisible(bool): makes this viewprovider visible in the
makes this viewprovider visible in the
scene graph without changing any properties, not the visibility one and also not
the display mode. This can be used to show the shape of this viewprovider from
other viewproviders without doing anything to the document and properties.