From 91dc7285e17c8f802a0b26eed0b5feafee50ddbf Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 20 Nov 2023 15:04:09 +0000 Subject: [PATCH] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- src/Mod/Import/App/dxf/ImpExpDxf.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/Mod/Import/App/dxf/ImpExpDxf.cpp b/src/Mod/Import/App/dxf/ImpExpDxf.cpp index edeaa831bb..4d639774a7 100644 --- a/src/Mod/Import/App/dxf/ImpExpDxf.cpp +++ b/src/Mod/Import/App/dxf/ImpExpDxf.cpp @@ -322,8 +322,8 @@ void ImpExpDxfRead::OnReadText(const double* point, const char* text, const double rotation) { - // Note that our parameters do not contain all the information needed to properly orient the text. - // As a result the text will always appear on the XY plane + // Note that our parameters do not contain all the information needed to properly orient the + // text. As a result the text will always appear on the XY plane if (optionImportAnnotations) { if (LayerName().substr(0, 6) != "BLOCKS") { PyObject* draftModule = nullptr; @@ -332,8 +332,9 @@ void ImpExpDxfRead::OnReadText(const double* point, Base::Rotation rot(Base::Vector3d(0, 0, 1), rotation); PyObject* placement = new Base::PlacementPy(Base::Placement(insertionPoint, rot)); draftModule = PyImport_ImportModule("Draft"); - if (draftModule != nullptr) + if (draftModule != nullptr) { PyObject_CallMethod(draftModule, "make_text", "sOif", text, placement, 0, height); + } // We own all the return values so we must release them. Py_DECREF(placement); Py_XDECREF(draftModule);