Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEberhard Beilharz <eb1@sil.org>2014-11-19 21:48:27 +0300
committerEberhard Beilharz <eb1@sil.org>2014-11-19 21:48:27 +0300
commitda058bf8a4a545ca3cd1e0e7553c14a1fce9c8c2 (patch)
treecd26c89474468a152efff720535bd69a9df20971 /mcs/class/Managed.Windows.Forms
parent87f59dce24a940bb89b9867f0c956b6ab71dd804 (diff)
[MWF] Fix bug that truncates button text
A previous change (885b065e) accidentally calculated the text size in some places without padding. This resulted in a slightly to small text rectangle, causing the text to be truncated.
Diffstat (limited to 'mcs/class/Managed.Windows.Forms')
-rw-r--r--mcs/class/Managed.Windows.Forms/System.Windows.Forms/ThemeWin32Classic.cs2
1 files changed, 1 insertions, 1 deletions
diff --git a/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ThemeWin32Classic.cs b/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ThemeWin32Classic.cs
index d6214c5e93b..26edaf80995 100644
--- a/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ThemeWin32Classic.cs
+++ b/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ThemeWin32Classic.cs
@@ -369,7 +369,7 @@ namespace System.Windows.Forms
Image image = button.Image;
string text = button.Text;
Rectangle content_rect = button.PaddingClientRectangle;
- Size text_size = TextRenderer.MeasureTextInternal (g, text, button.Font, content_rect.Size, button.TextFormatFlags | TextFormatFlags.NoPadding, button.UseCompatibleTextRendering);
+ Size text_size = TextRenderer.MeasureTextInternal (g, text, button.Font, content_rect.Size, button.TextFormatFlags, button.UseCompatibleTextRendering);
Size image_size = image == null ? Size.Empty : image.Size;
textRectangle = Rectangle.Inflate (content_rect, -4, -4);