diff --git a/scripts/startup/bl_ui/properties_data_modifier.py b/scripts/startup/bl_ui/properties_data_modifier.py index 8c121f37928..b64b33816eb 100644 --- a/scripts/startup/bl_ui/properties_data_modifier.py +++ b/scripts/startup/bl_ui/properties_data_modifier.py @@ -274,7 +274,6 @@ class AddModifierMenu(Operator): @classmethod def poll(cls, context): # NOTE: This operator only exists to add a poll to the add modifier shortcut in the property editor. - object = context.object space = context.space_data return space and space.type == 'PROPERTIES' and space.context == 'MODIFIER' diff --git a/scripts/startup/bl_ui/properties_material_gpencil.py b/scripts/startup/bl_ui/properties_material_gpencil.py index 13a7fd52e02..c458615ff5e 100644 --- a/scripts/startup/bl_ui/properties_material_gpencil.py +++ b/scripts/startup/bl_ui/properties_material_gpencil.py @@ -91,7 +91,6 @@ class MATERIAL_PT_gpencil_slots(GreasePencilMaterialsPanel, Panel): @classmethod def poll(cls, context): - ob = context.object ma = context.material return ma and ma.grease_pencil diff --git a/source/blender/blenkernel/intern/vfont_curve.cc b/source/blender/blenkernel/intern/vfont_curve.cc index 6099f4b599e..3f70977fa22 100644 --- a/source/blender/blenkernel/intern/vfont_curve.cc +++ b/source/blender/blenkernel/intern/vfont_curve.cc @@ -591,7 +591,7 @@ static bool vfont_to_curve(Object *ob, CharTrans *chartransdata = nullptr, *ct; TempLineInfo *lineinfo; float xof, yof, xtrax, linedist; - float twidth = 0, maxlen = 0; + float twidth = 0; int i, slen, j; int curbox; /* These values are only set to the selection range when `selboxes` is non-null. */ @@ -867,15 +867,12 @@ static bool vfont_to_curve(Object *ob, lineinfo[lnr].char_nr = cnr; lineinfo[lnr].wspace_nr = wsnr; - CLAMP_MIN(maxlen, lineinfo[lnr].x_min); - if (tb_bounds_for_cursor != nullptr) { tb_bounds_for_cursor[curbox].char_index_last = i; } if ((tb_scale.h != 0.0f) && (-(yof - tb_scale.y) > (tb_scale.h - linedist) - yof_scale)) { if (cu->totbox > (curbox + 1)) { - maxlen = 0; curbox++; i_textbox_array[curbox] = i + 1;