Skip to content

Commit

Permalink
Update MainReinforcementDrawingDimensioning.py
Browse files Browse the repository at this point in the history
solves comma decimal separator issue for "Reinforcement Drawing Dimensioning"-dialogs described in #214
  • Loading branch information
balrobs authored and amrit3701 committed Jun 1, 2024
1 parent 98a8092 commit beb3610
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions ReinforcementDrawing/MainReinforcementDrawingDimensioning.py
Original file line number Diff line number Diff line change
Expand Up @@ -309,7 +309,7 @@ def setDefaultShapesData(self):
"""This function is used to set default values in "Shapes - Rebars &
Structure" stacked widget in UI."""
form = self.shapes_data_widget
form.rebars_stroke_width.setText(f"{self.rebars_stroke_width} mm")
form.rebars_stroke_width.setText(FreeCAD.Units.Quantity(self.rebars_stroke_width, FreeCAD.Units.Length).UserString)
if self.rebars_color_style == "Automatic":
form.rebars_shape_color_radio.setChecked(True)
form.rebars_custom_color_radio.setChecked(False)
Expand All @@ -323,7 +323,7 @@ def setDefaultShapesData(self):
self.rebars_color[0], self.rebars_color[1], self.rebars_color[2]
)
form.rebars_color.setProperty("color", color)
form.structure_stroke_width.setText(f"{self.structure_stroke_width} mm")
form.structure_stroke_width.setText(FreeCAD.Units.Quantity(self.structure_stroke_width, FreeCAD.Units.Length).UserString)
if self.structure_color_style == "Automatic":
form.structure_shape_color_radio.setChecked(True)
form.structure_color_none.setChecked(False)
Expand Down Expand Up @@ -397,7 +397,7 @@ def setDefaultDimensionLabelsLinesData(self):
self.dimension_text_color[2],
)
form.dimension_text_color.setProperty("color", color)
form.dimension_stroke_width.setText(f"{self.dimension_stroke_width} mm")
form.dimension_stroke_width.setText(FreeCAD.Units.Quantity(self.dimension_stroke_width, FreeCAD.Units.Length).UserString)
if form.dimension_line_style.findText(self.dimension_line_style) == -1:
form.dimension_line_style.setCurrentIndex(0)
else:
Expand Down

0 comments on commit beb3610

Please sign in to comment.