2009-07-15 Gonzalo Paniagua Javier <gonzalo@novell.com>
authorGonzalo Paniagua Javier <gonzalo.mono@gmail.com>
Thu, 16 Jul 2009 03:34:10 +0000 (03:34 -0000)
committerGonzalo Paniagua Javier <gonzalo.mono@gmail.com>
Thu, 16 Jul 2009 03:34:10 +0000 (03:34 -0000)
* Font.cs: implement OriginalFontName.

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

mcs/class/System.Drawing/System.Drawing/ChangeLog
mcs/class/System.Drawing/System.Drawing/Font.cs

index 7ecd6782d33470ee9b2eea33fb771844ff385762..dd3aa601e8d5638c893b595f1252624f2d0c9e49 100644 (file)
@@ -1,3 +1,7 @@
+2009-07-15 Gonzalo Paniagua Javier <gonzalo@novell.com>
+
+       * Font.cs: implement OriginalFontName.
+
 2009-07-15  Sebastien Pouliot  <sebastien@ximian.com>
 
        * gdipFunctions.cs: Fix XVisualIDFromVisual to return an IntPtr
index ecf616dd24ec1abda3f6288afb8e804c0deafc41..6b16e44addcfdc1d512862f86a1435c698e18c24 100644 (file)
@@ -47,6 +47,7 @@ namespace System.Drawing
                private IntPtr  fontObject = IntPtr.Zero;
 #if NET_2_0            
                private string  systemFontName;
+               private string  originalFontName;
 #endif         
                private float _size;
                private object olf;
@@ -59,6 +60,9 @@ namespace System.Drawing
 #if ONLY_1_1
                        if (familyName == null)
                                throw new ArgumentNullException ("familyName");
+#endif
+#if NET_2_0
+                       originalFontName = familyName;
 #endif
                         FontFamily family;
                        // NOTE: If family name is null, empty or invalid,
@@ -503,6 +507,13 @@ namespace System.Drawing
                                return systemFontName;
                        }
                }
+
+               [Browsable(false)]
+               public string OriginalFontName {
+                       get {
+                               return originalFontName;
+                       }
+               }
 #endif
                private bool _underline;