Add Python API compatibility for GetEffectiveTextShape.

This commit is contained in:
Alex Shvartzkop 2023-10-25 00:03:07 +03:00
parent 3ce4a5bf7f
commit 2263535d3a
1 changed files with 14 additions and 0 deletions

View File

@ -80,6 +80,20 @@ principle should be easily implemented by adapting the current STL containers.
%ignore to_json;
%ignore from_json;
%rename(GetEffectiveTextShapeNative) EDA_TEXT::GetEffectiveTextShape;
%extend EDA_TEXT
{
%pythoncode
%{
# KiCad 7.0 API Compatibility
def GetEffectiveTextShape(self, aTriangulate=True, aUseTextRotation=True):
return self.GetEffectiveTextShapeNative(aTriangulate)
%}
}
// headers/imports that must be included in the _wrapper.cpp at top
%{