2010-06-25 Carlos Alberto Cortez <calberto.cortez@gmail.com>
authorCarlos Alberto Cortez <calberto.cortez@gmail.com>
Fri, 25 Jun 2010 16:22:37 +0000 (16:22 -0000)
committerCarlos Alberto Cortez <calberto.cortez@gmail.com>
Fri, 25 Jun 2010 16:22:37 +0000 (16:22 -0000)
* TabControl.cs: Don't use the Font property of our TabPages - use our
own Font property instead, as .Net does.
Fixes some bits of #551032.

svn path=/trunk/mcs/; revision=159544

mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog
mcs/class/Managed.Windows.Forms/System.Windows.Forms/TabControl.cs

index 21275e6088efb73d2ece4aabf85d7e33b7660199..06cc8cb3244fac837c8df67872e77cf915cb105c 100644 (file)
@@ -1,3 +1,9 @@
+2010-06-25  Carlos Alberto Cortez <calberto.cortez@gmail.com>
+
+       * TabControl.cs: Don't use the Font property of our TabPages - use our
+       own Font property instead, as .Net does.
+       Fixes some bits of #551032.
+
 2010-06-24  Carlos Alberto Cortez <calberto.cortez@gmail.com>
 
        * TabControl.cs: Call Invalidate when removing a tab page. We were
index 911379ed955d01b3392b7224e0844aab6ace6115..c3e200cae05c36346e50b60f50a7199b124ba2ca 100644 (file)
@@ -1320,7 +1320,7 @@ namespace System.Windows.Forms {
                        if (SizeMode == TabSizeMode.Fixed) {
                                width = item_size.Width;
                        } else {                        
-                               width = MeasureStringWidth (DeviceContext, page.Text, page.Font);
+                               width = MeasureStringWidth (DeviceContext, page.Text, Font);
                                width += (Padding.X * 2) + 2;
 
                                if (ImageList != null && page.ImageIndex >= 0) {