Skip to content

Commit

Permalink
Bug fix
Browse files Browse the repository at this point in the history
  • Loading branch information
qubqub committed Sep 20, 2023
1 parent bee65ef commit 7658a3e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Controls/TransparentLabel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ private Font GetFontForRoundName(string text) {
return new Font(this.Font.FontFamily, this.Font.Size * this.GetFontSizeFactorForRoundName(text), this.Font.Style, GraphicsUnit.Pixel);
}
private float GetFontSizeFactorForRoundName(string text) {
float factor = 1.0f,
float factor = 1f,
factorOffsetForSpace = 0f,
factorOffsetForEngAlphabet = 0f,
factorOffsetForKorAlphabet = 0f,
Expand Down Expand Up @@ -659,7 +659,7 @@ private float GetFontSizeFactorForRoundName(string text) {
}
}
}
return factor;
return factor > 1f ? 1f : factor;
}
private RectangleF FillRoundedRectangleF(Graphics g, Pen pen, Brush brush, float x, float y, float width, float height, float radius) {
using (GraphicsPath path = new GraphicsPath()) {
Expand Down

0 comments on commit 7658a3e

Please sign in to comment.