Skip to content

Commit

Permalink
Fixed the correction of large text size in svg
Browse files Browse the repository at this point in the history
  • Loading branch information
PolyakovKirill committed Jan 25, 2025
1 parent 63887c9 commit c43fb92
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions DesktopEditor/raster/Metafile/svg/SvgObjects/CText.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -442,14 +442,14 @@ namespace SVG

if (!Equals(0., dFontHeight) && dFontHeight < MIN_FONT_SIZE)
{
dXScale *= dFontHeight / MIN_FONT_SIZE;
dYScale *= dFontHeight / MIN_FONT_SIZE;
dXScale *= MIN_FONT_SIZE / dFontHeight;
dYScale *= MIN_FONT_SIZE / dFontHeight;
dFontHeight = MIN_FONT_SIZE;
}
else if (!Equals(0., dFontHeight) && dFontHeight > MAX_FONT_SIZE)
{
dXScale *= MAX_FONT_SIZE / dFontHeight;
dYScale *= MAX_FONT_SIZE / dFontHeight;
dXScale *= dFontHeight / MAX_FONT_SIZE;
dYScale *= dFontHeight / MAX_FONT_SIZE;
dFontHeight = MAX_FONT_SIZE;
}

Expand Down

0 comments on commit c43fb92

Please sign in to comment.