diff options
author | Marek Safar <marek.safar@gmail.com> | 2017-06-06 14:05:26 +0300 |
---|---|---|
committer | Marek Safar <marek.safar@gmail.com> | 2017-06-06 14:05:26 +0300 |
commit | 684f306d0d2bfabac80d7aae99cfdfe6a300ca5f (patch) | |
tree | 81b2f5cca7fe0b4caa3d90d1fe945b4f496490e4 /src/System.Drawing.Primitives | |
parent | e49886bd091487abfbf5de934a451c5a8fe7f4c5 (diff) | |
parent | 0e2b8241482c472b1ff456f57bc032716d62c260 (diff) |
Merge remote-tracking branch 'upstream/master'
Diffstat (limited to 'src/System.Drawing.Primitives')
9 files changed, 976 insertions, 102 deletions
diff --git a/src/System.Drawing.Primitives/ref/System.Drawing.Primitives.cs b/src/System.Drawing.Primitives/ref/System.Drawing.Primitives.cs index e28d6de3f0..517d082523 100644 --- a/src/System.Drawing.Primitives/ref/System.Drawing.Primitives.cs +++ b/src/System.Drawing.Primitives/ref/System.Drawing.Primitives.cs @@ -72,7 +72,9 @@ namespace System.Drawing public static System.Drawing.Color IndianRed { get { throw null; } } public static System.Drawing.Color Indigo { get { throw null; } } public bool IsEmpty { get { throw null; } } + public bool IsKnownColor { get { throw null; } } public bool IsNamedColor { get { throw null; } } + public bool IsSystemColor { get { throw null; } } public static System.Drawing.Color Ivory { get { throw null; } } public static System.Drawing.Color Khaki { get { throw null; } } public static System.Drawing.Color Lavender { get { throw null; } } @@ -165,6 +167,7 @@ namespace System.Drawing public static System.Drawing.Color FromArgb(int alpha, System.Drawing.Color baseColor) { throw null; } public static System.Drawing.Color FromArgb(int red, int green, int blue) { throw null; } public static System.Drawing.Color FromArgb(int alpha, int red, int green, int blue) { throw null; } + public static System.Drawing.Color FromKnownColor(System.Drawing.KnownColor color) { throw null; } public static System.Drawing.Color FromName(string name) { throw null; } public float GetBrightness() { throw null; } public override int GetHashCode() { throw null; } @@ -173,6 +176,7 @@ namespace System.Drawing public static bool operator ==(System.Drawing.Color left, System.Drawing.Color right) { throw null; } public static bool operator !=(System.Drawing.Color left, System.Drawing.Color right) { throw null; } public int ToArgb() { throw null; } + public System.Drawing.KnownColor ToKnownColor() { throw null; } public override string ToString() { throw null; } } public partial struct Point : System.IEquatable<System.Drawing.Point> @@ -365,4 +369,181 @@ namespace System.Drawing public System.Drawing.Size ToSize() { throw null; } public override string ToString() { throw null; } } + public enum KnownColor + { + ActiveBorder = 1, + ActiveCaption = 2, + ActiveCaptionText = 3, + AliceBlue = 28, + AntiqueWhite = 29, + AppWorkspace = 4, + Aqua = 30, + Aquamarine = 31, + Azure = 32, + Beige = 33, + Bisque = 34, + Black = 35, + BlanchedAlmond = 36, + Blue = 37, + BlueViolet = 38, + Brown = 39, + BurlyWood = 40, + ButtonFace = 168, + ButtonHighlight = 169, + ButtonShadow = 170, + CadetBlue = 41, + Chartreuse = 42, + Chocolate = 43, + Control = 5, + ControlDark = 6, + ControlDarkDark = 7, + ControlLight = 8, + ControlLightLight = 9, + ControlText = 10, + Coral = 44, + CornflowerBlue = 45, + Cornsilk = 46, + Crimson = 47, + Cyan = 48, + DarkBlue = 49, + DarkCyan = 50, + DarkGoldenrod = 51, + DarkGray = 52, + DarkGreen = 53, + DarkKhaki = 54, + DarkMagenta = 55, + DarkOliveGreen = 56, + DarkOrange = 57, + DarkOrchid = 58, + DarkRed = 59, + DarkSalmon = 60, + DarkSeaGreen = 61, + DarkSlateBlue = 62, + DarkSlateGray = 63, + DarkTurquoise = 64, + DarkViolet = 65, + DeepPink = 66, + DeepSkyBlue = 67, + Desktop = 11, + DimGray = 68, + DodgerBlue = 69, + Firebrick = 70, + FloralWhite = 71, + ForestGreen = 72, + Fuchsia = 73, + Gainsboro = 74, + GhostWhite = 75, + Gold = 76, + Goldenrod = 77, + GradientActiveCaption = 171, + GradientInactiveCaption = 172, + Gray = 78, + GrayText = 12, + Green = 79, + GreenYellow = 80, + Highlight = 13, + HighlightText = 14, + Honeydew = 81, + HotPink = 82, + HotTrack = 15, + InactiveBorder = 16, + InactiveCaption = 17, + InactiveCaptionText = 18, + IndianRed = 83, + Indigo = 84, + Info = 19, + InfoText = 20, + Ivory = 85, + Khaki = 86, + Lavender = 87, + LavenderBlush = 88, + LawnGreen = 89, + LemonChiffon = 90, + LightBlue = 91, + LightCoral = 92, + LightCyan = 93, + LightGoldenrodYellow = 94, + LightGray = 95, + LightGreen = 96, + LightPink = 97, + LightSalmon = 98, + LightSeaGreen = 99, + LightSkyBlue = 100, + LightSlateGray = 101, + LightSteelBlue = 102, + LightYellow = 103, + Lime = 104, + LimeGreen = 105, + Linen = 106, + Magenta = 107, + Maroon = 108, + MediumAquamarine = 109, + MediumBlue = 110, + MediumOrchid = 111, + MediumPurple = 112, + MediumSeaGreen = 113, + MediumSlateBlue = 114, + MediumSpringGreen = 115, + MediumTurquoise = 116, + MediumVioletRed = 117, + Menu = 21, + MenuBar = 173, + MenuHighlight = 174, + MenuText = 22, + MidnightBlue = 118, + MintCream = 119, + MistyRose = 120, + Moccasin = 121, + NavajoWhite = 122, + Navy = 123, + OldLace = 124, + Olive = 125, + OliveDrab = 126, + Orange = 127, + OrangeRed = 128, + Orchid = 129, + PaleGoldenrod = 130, + PaleGreen = 131, + PaleTurquoise = 132, + PaleVioletRed = 133, + PapayaWhip = 134, + PeachPuff = 135, + Peru = 136, + Pink = 137, + Plum = 138, + PowderBlue = 139, + Purple = 140, + Red = 141, + RosyBrown = 142, + RoyalBlue = 143, + SaddleBrown = 144, + Salmon = 145, + SandyBrown = 146, + ScrollBar = 23, + SeaGreen = 147, + SeaShell = 148, + Sienna = 149, + Silver = 150, + SkyBlue = 151, + SlateBlue = 152, + SlateGray = 153, + Snow = 154, + SpringGreen = 155, + SteelBlue = 156, + Tan = 157, + Teal = 158, + Thistle = 159, + Tomato = 160, + Transparent = 27, + Turquoise = 161, + Violet = 162, + Wheat = 163, + White = 164, + WhiteSmoke = 165, + Window = 24, + WindowFrame = 25, + WindowText = 26, + Yellow = 166, + YellowGreen = 167, + } } diff --git a/src/System.Drawing.Primitives/src/System/Drawing/Color.cs b/src/System.Drawing.Primitives/src/System/Drawing/Color.cs index 07ff82e444..71f0a8f957 100644 --- a/src/System.Drawing.Primitives/src/System/Drawing/Color.cs +++ b/src/System.Drawing.Primitives/src/System/Drawing/Color.cs @@ -363,12 +363,14 @@ namespace System.Drawing public byte A => (byte)((Value >> ARGBAlphaShift) & 0xFF); - private bool IsKnownColor => ((state & StateKnownColorValid) != 0); + public bool IsKnownColor => ((state & StateKnownColorValid) != 0); public bool IsEmpty => state == 0; public bool IsNamedColor => ((state & StateNameValid) != 0) || IsKnownColor; + public bool IsSystemColor => IsKnownColor && ((((KnownColor) knownColor) <= KnownColor.WindowText) || (((KnownColor) knownColor) > KnownColor.YellowGreen)); + // Not localized because it's only used for the DebuggerDisplayAttribute, and the values are // programmatic items. // Also, don't inline into the attribute for performance reasons. This way means the debugger @@ -449,7 +451,7 @@ namespace System.Drawing public static Color FromArgb(int red, int green, int blue) => FromArgb(255, red, green, blue); - private static Color FromKnownColor(KnownColor color) + public static Color FromKnownColor(KnownColor color) { var value = (int)color; if (value < (int)KnownColor.FirstColor || value > (int)KnownColor.LastColor) @@ -574,7 +576,7 @@ namespace System.Drawing public int ToArgb() => unchecked((int)Value); - private KnownColor ToKnownColor() => (KnownColor)knownColor; + public KnownColor ToKnownColor() => (KnownColor)knownColor; public override string ToString() { diff --git a/src/System.Drawing.Primitives/src/System/Drawing/KnownColor.cs b/src/System.Drawing.Primitives/src/System/Drawing/KnownColor.cs index 450f3bfbf7..dbd287dd06 100644 --- a/src/System.Drawing.Primitives/src/System/Drawing/KnownColor.cs +++ b/src/System.Drawing.Primitives/src/System/Drawing/KnownColor.cs @@ -7,7 +7,7 @@ using System.Diagnostics.CodeAnalysis; namespace System.Drawing { [SuppressMessage("Microsoft.Design", "CA1008:EnumsShouldHaveZeroValue")] - internal enum KnownColor + public enum KnownColor { // This enum is order dependant!!! // @@ -17,192 +17,883 @@ namespace System.Drawing // 0 - reserved for "not a known color" - + FirstColor = 0, // "System" colors - /* + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.ActiveBorder"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> ActiveBorder = 1, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.ActiveCaption"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> ActiveCaption, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.ActiveCaptionText"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> ActiveCaptionText, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.AppWorkspace"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> AppWorkspace, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Control"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Control, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.ControlDark"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> ControlDark, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.ControlDarkDark"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> ControlDarkDark, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.ControlLight"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> ControlLight, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.ControlLightLight"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> ControlLightLight, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.ControlText"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> ControlText, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Desktop"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Desktop, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.GrayText"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> GrayText, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Highlight"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Highlight, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.HighlightText"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> HighlightText, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.HotTrack"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> HotTrack, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.InactiveBorder"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> InactiveBorder, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.InactiveCaption"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> InactiveCaption, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.InactiveCaptionText"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> InactiveCaptionText, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Info"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Info, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.InfoText"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> InfoText, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Menu"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Menu, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.MenuText"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> MenuText, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.ScrollBar"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> ScrollBar, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Window"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Window, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.WindowFrame"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> WindowFrame, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.WindowText"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> WindowText, - */ // "Web" Colors - FirstColor = 0, - Transparent = FirstColor, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Transparent"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> + Transparent, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.AliceBlue"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> AliceBlue, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.AntiqueWhite"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> AntiqueWhite, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Aqua"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Aqua, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Aquamarine"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Aquamarine, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Azure"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Azure, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Beige"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Beige, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Bisque"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Bisque, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Black"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Black, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.BlanchedAlmond"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> BlanchedAlmond, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Blue"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Blue, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.BlueViolet"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> BlueViolet, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Brown"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Brown, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.BurlyWood"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> BurlyWood, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.CadetBlue"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> CadetBlue, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Chartreuse"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Chartreuse, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Chocolate"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Chocolate, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Coral"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Coral, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.CornflowerBlue"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> CornflowerBlue, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Cornsilk"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Cornsilk, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Crimson"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Crimson, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Cyan"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Cyan, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.DarkBlue"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> DarkBlue, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.DarkCyan"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> DarkCyan, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.DarkGoldenrod"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> DarkGoldenrod, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.DarkGray"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> DarkGray, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.DarkGreen"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> DarkGreen, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.DarkKhaki"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> DarkKhaki, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.DarkMagenta"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> DarkMagenta, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.DarkOliveGreen"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> DarkOliveGreen, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.DarkOrange"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> DarkOrange, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.DarkOrchid"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> DarkOrchid, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.DarkRed"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> DarkRed, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.DarkSalmon"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> DarkSalmon, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.DarkSeaGreen"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> DarkSeaGreen, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.DarkSlateBlue"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> DarkSlateBlue, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.DarkSlateGray"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> DarkSlateGray, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.DarkTurquoise"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> DarkTurquoise, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.DarkViolet"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> DarkViolet, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.DeepPink"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> DeepPink, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.DeepSkyBlue"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> DeepSkyBlue, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.DimGray"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> DimGray, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.DodgerBlue"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> DodgerBlue, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Firebrick"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Firebrick, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.FloralWhite"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> FloralWhite, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.ForestGreen"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> ForestGreen, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Fuchsia"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Fuchsia, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Gainsboro"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Gainsboro, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.GhostWhite"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> GhostWhite, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Gold"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Gold, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Goldenrod"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Goldenrod, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Gray"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Gray, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Green"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Green, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.GreenYellow"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> GreenYellow, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Honeydew"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Honeydew, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.HotPink"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> HotPink, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.IndianRed"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> IndianRed, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Indigo"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Indigo, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Ivory"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Ivory, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Khaki"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Khaki, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Lavender"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Lavender, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.LavenderBlush"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> LavenderBlush, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.LawnGreen"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> LawnGreen, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.LemonChiffon"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> LemonChiffon, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.LightBlue"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> LightBlue, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.LightCoral"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> LightCoral, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.LightCyan"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> LightCyan, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.LightGoldenrodYellow"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> LightGoldenrodYellow, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.LightGray"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> LightGray, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.LightGreen"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> LightGreen, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.LightPink"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> LightPink, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.LightSalmon"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> LightSalmon, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.LightSeaGreen"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> LightSeaGreen, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.LightSkyBlue"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> LightSkyBlue, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.LightSlateGray"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> LightSlateGray, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.LightSteelBlue"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> LightSteelBlue, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.LightYellow"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> LightYellow, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Lime"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Lime, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.LimeGreen"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> LimeGreen, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Linen"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Linen, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Magenta"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Magenta, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Maroon"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Maroon, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.MediumAquamarine"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> MediumAquamarine, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.MediumBlue"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> MediumBlue, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.MediumOrchid"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> MediumOrchid, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.MediumPurple"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> MediumPurple, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.MediumSeaGreen"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> MediumSeaGreen, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.MediumSlateBlue"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> MediumSlateBlue, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.MediumSpringGreen"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> MediumSpringGreen, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.MediumTurquoise"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> MediumTurquoise, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.MediumVioletRed"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> MediumVioletRed, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.MidnightBlue"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> MidnightBlue, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.MintCream"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> MintCream, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.MistyRose"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> MistyRose, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Moccasin"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Moccasin, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.NavajoWhite"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> NavajoWhite, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Navy"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Navy, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.OldLace"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> OldLace, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Olive"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Olive, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.OliveDrab"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> OliveDrab, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Orange"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Orange, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.OrangeRed"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> OrangeRed, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Orchid"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Orchid, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.PaleGoldenrod"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> PaleGoldenrod, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.PaleGreen"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> PaleGreen, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.PaleTurquoise"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> PaleTurquoise, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.PaleVioletRed"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> PaleVioletRed, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.PapayaWhip"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> PapayaWhip, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.PeachPuff"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> PeachPuff, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Peru"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Peru, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Pink"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Pink, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Plum"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Plum, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.PowderBlue"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> PowderBlue, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Purple"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Purple, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Red"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Red, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.RosyBrown"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> RosyBrown, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.RoyalBlue"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> RoyalBlue, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.SaddleBrown"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> SaddleBrown, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Salmon"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Salmon, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.SandyBrown"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> SandyBrown, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.SeaGreen"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> SeaGreen, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.SeaShell"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> SeaShell, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Sienna"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Sienna, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Silver"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Silver, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.SkyBlue"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> SkyBlue, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.SlateBlue"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> SlateBlue, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.SlateGray"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> SlateGray, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Snow"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Snow, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.SpringGreen"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> SpringGreen, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.SteelBlue"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> SteelBlue, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Tan"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Tan, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Teal"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Teal, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Thistle"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Thistle, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Tomato"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Tomato, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Turquoise"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Turquoise, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Violet"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Violet, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Wheat"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Wheat, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.White"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> White, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.WhiteSmoke"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> WhiteSmoke, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.Yellow"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> Yellow, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.YellowGreen"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> YellowGreen, - LastColor = YellowGreen // NEW ADDITIONS IN WHIDBEY - DO NOT MOVE THESE UP OR IT WILL BE A BREAKING CHANGE - /* + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.ButtonFace"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> ButtonFace, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.ButtonHighlight"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> ButtonHighlight, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.ButtonShadow"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> ButtonShadow, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.GradientActiveCaption"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> GradientActiveCaption, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.GradientInactiveCaption"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> GradientInactiveCaption, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.MenuBar"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> MenuBar, + /// <include file='doc\KnownColor.uex' path='docs/doc[@for="KnownColor.MenuHighlight"]/*' /> + /// <devdoc> + /// <para>[To be supplied.]</para> + /// </devdoc> MenuHighlight, - */ + LastColor = MenuHighlight, } }
\ No newline at end of file diff --git a/src/System.Drawing.Primitives/src/System/Drawing/Point.cs b/src/System.Drawing.Primitives/src/System/Drawing/Point.cs index 56fb285778..6f9fdf9f50 100644 --- a/src/System.Drawing.Primitives/src/System/Drawing/Point.cs +++ b/src/System.Drawing.Primitives/src/System/Drawing/Point.cs @@ -20,8 +20,8 @@ namespace System.Drawing /// </summary> public static readonly Point Empty = new Point(); - private int _x; - private int _y; + private int x; // Do not rename (binary serialization) + private int y; // Do not rename (binary serialization) /// <summary> /// Initializes a new instance of the <see cref='System.Drawing.Point'/> class @@ -29,8 +29,8 @@ namespace System.Drawing /// </summary> public Point(int x, int y) { - _x = x; - _y = y; + this.x = x; + this.y = y; } /// <summary> @@ -41,8 +41,8 @@ namespace System.Drawing /// </summary> public Point(Size sz) { - _x = sz.Width; - _y = sz.Height; + x = sz.Width; + y = sz.Height; } /// <summary> @@ -51,8 +51,8 @@ namespace System.Drawing /// </summary> public Point(int dw) { - _x = LowInt16(dw); - _y = HighInt16(dw); + x = LowInt16(dw); + y = HighInt16(dw); } /// <summary> @@ -61,15 +61,15 @@ namespace System.Drawing /// </para> /// </summary> [Browsable(false)] - public bool IsEmpty => _x == 0 && _y == 0; + public bool IsEmpty => x == 0 && y == 0; /// <summary> /// Gets the x-coordinate of this <see cref='System.Drawing.Point'/>. /// </summary> public int X { - get { return _x; } - set { _x = value; } + get { return x; } + set { x = value; } } /// <summary> @@ -79,8 +79,8 @@ namespace System.Drawing /// </summary> public int Y { - get { return _y; } - set { _y = value; } + get { return y; } + set { y = value; } } /// <summary> diff --git a/src/System.Drawing.Primitives/src/System/Drawing/PointF.cs b/src/System.Drawing.Primitives/src/System/Drawing/PointF.cs index e05e67087e..891fb535d4 100644 --- a/src/System.Drawing.Primitives/src/System/Drawing/PointF.cs +++ b/src/System.Drawing.Primitives/src/System/Drawing/PointF.cs @@ -21,8 +21,8 @@ namespace System.Drawing /// </para> /// </summary> public static readonly PointF Empty = new PointF(); - private float _x; - private float _y; + private float x; // Do not rename (binary serialization) + private float y; // Do not rename (binary serialization) /// <summary> /// <para> @@ -32,8 +32,8 @@ namespace System.Drawing /// </summary> public PointF(float x, float y) { - _x = x; - _y = y; + this.x = x; + this.y = y; } /// <summary> @@ -42,7 +42,7 @@ namespace System.Drawing /// </para> /// </summary> [Browsable(false)] - public bool IsEmpty => _x == 0f && _y == 0f; + public bool IsEmpty => x == 0f && y == 0f; /// <summary> /// <para> @@ -51,8 +51,8 @@ namespace System.Drawing /// </summary> public float X { - get { return _x; } - set { _x = value; } + get { return x; } + set { x = value; } } /// <summary> @@ -62,8 +62,8 @@ namespace System.Drawing /// </summary> public float Y { - get { return _y; } - set { _y = value; } + get { return y; } + set { y = value; } } /// <summary> @@ -147,6 +147,6 @@ namespace System.Drawing public override int GetHashCode() => HashHelpers.Combine(X.GetHashCode(), Y.GetHashCode()); - public override string ToString() => "{X=" + _x.ToString() + ", Y=" + _y.ToString() + "}"; + public override string ToString() => "{X=" + x.ToString() + ", Y=" + y.ToString() + "}"; } } diff --git a/src/System.Drawing.Primitives/src/System/Drawing/Rectangle.cs b/src/System.Drawing.Primitives/src/System/Drawing/Rectangle.cs index 5165a73660..ddd1a5a9fd 100644 --- a/src/System.Drawing.Primitives/src/System/Drawing/Rectangle.cs +++ b/src/System.Drawing.Primitives/src/System/Drawing/Rectangle.cs @@ -18,10 +18,10 @@ namespace System.Drawing { public static readonly Rectangle Empty = new Rectangle(); - private int _x; - private int _y; - private int _width; - private int _height; + private int x; // Do not rename (binary serialization) + private int y; // Do not rename (binary serialization) + private int width; // Do not rename (binary serialization) + private int height; // Do not rename (binary serialization) /// <summary> /// <para> @@ -31,10 +31,10 @@ namespace System.Drawing /// </summary> public Rectangle(int x, int y, int width, int height) { - _x = x; - _y = y; - _width = width; - _height = height; + this.x = x; + this.y = y; + this.width = width; + this.height = height; } /// <summary> @@ -45,10 +45,10 @@ namespace System.Drawing /// </summary> public Rectangle(Point location, Size size) { - _x = location.X; - _y = location.Y; - _width = size.Width; - _height = size.Height; + x = location.X; + y = location.Y; + width = size.Width; + height = size.Height; } /// <summary> @@ -95,8 +95,8 @@ namespace System.Drawing /// </summary> public int X { - get { return _x; } - set { _x = value; } + get { return x; } + set { x = value; } } /// <summary> @@ -105,8 +105,8 @@ namespace System.Drawing /// </summary> public int Y { - get { return _y; } - set { _y = value; } + get { return y; } + set { y = value; } } /// <summary> @@ -115,8 +115,8 @@ namespace System.Drawing /// </summary> public int Width { - get { return _width; } - set { _width = value; } + get { return width; } + set { width = value; } } /// <summary> @@ -125,8 +125,8 @@ namespace System.Drawing /// </summary> public int Height { - get { return _height; } - set { _height = value; } + get { return height; } + set { height = value; } } /// <summary> @@ -172,7 +172,7 @@ namespace System.Drawing /// </para> /// </summary> [Browsable(false)] - public bool IsEmpty => _height == 0 && _width == 0 && _x == 0 && _y == 0; + public bool IsEmpty => height == 0 && width == 0 && x == 0 && y == 0; /// <summary> /// <para> diff --git a/src/System.Drawing.Primitives/src/System/Drawing/RectangleF.cs b/src/System.Drawing.Primitives/src/System/Drawing/RectangleF.cs index 40276361bf..338896522c 100644 --- a/src/System.Drawing.Primitives/src/System/Drawing/RectangleF.cs +++ b/src/System.Drawing.Primitives/src/System/Drawing/RectangleF.cs @@ -22,10 +22,10 @@ namespace System.Drawing /// </summary> public static readonly RectangleF Empty = new RectangleF(); - private float _x; - private float _y; - private float _width; - private float _height; + private float x; // Do not rename (binary serialization) + private float y; // Do not rename (binary serialization) + private float width; // Do not rename (binary serialization) + private float height; // Do not rename (binary serialization) /// <summary> /// <para> @@ -35,10 +35,10 @@ namespace System.Drawing /// </summary> public RectangleF(float x, float y, float width, float height) { - _x = x; - _y = y; - _width = width; - _height = height; + this.x = x; + this.y = y; + this.width = width; + this.height = height; } /// <summary> @@ -50,10 +50,10 @@ namespace System.Drawing /// </summary> public RectangleF(PointF location, SizeF size) { - _x = location.X; - _y = location.Y; - _width = size.Width; - _height = size.Height; + x = location.X; + y = location.Y; + width = size.Width; + height = size.Height; } /// <summary> @@ -106,8 +106,8 @@ namespace System.Drawing /// </summary> public float X { - get { return _x; } - set { _x = value; } + get { return x; } + set { x = value; } } /// <summary> @@ -118,8 +118,8 @@ namespace System.Drawing /// </summary> public float Y { - get { return _y; } - set { _y = value; } + get { return y; } + set { y = value; } } /// <summary> @@ -130,8 +130,8 @@ namespace System.Drawing /// </summary> public float Width { - get { return _width; } - set { _width = value; } + get { return width; } + set { width = value; } } /// <summary> @@ -142,8 +142,8 @@ namespace System.Drawing /// </summary> public float Height { - get { return _height; } - set { _height = value; } + get { return height; } + set { height = value; } } /// <summary> diff --git a/src/System.Drawing.Primitives/src/System/Drawing/Size.cs b/src/System.Drawing.Primitives/src/System/Drawing/Size.cs index 19cf1e314b..35da1dcb6e 100644 --- a/src/System.Drawing.Primitives/src/System/Drawing/Size.cs +++ b/src/System.Drawing.Primitives/src/System/Drawing/Size.cs @@ -22,8 +22,8 @@ namespace System.Drawing /// </summary> public static readonly Size Empty = new Size(); - private int _width; - private int _height; + private int width; // Do not rename (binary serialization) + private int height; // Do not rename (binary serialization) /** * Create a new Size object from a point @@ -36,8 +36,8 @@ namespace System.Drawing /// </summary> public Size(Point pt) { - _width = pt.X; - _height = pt.Y; + width = pt.X; + height = pt.Y; } /** @@ -49,8 +49,8 @@ namespace System.Drawing /// </summary> public Size(int width, int height) { - _width = width; - _height = height; + this.width = width; + this.height = height; } /// <summary> @@ -97,7 +97,7 @@ namespace System.Drawing /// width and height. /// </summary> [Browsable(false)] - public bool IsEmpty => _width == 0 && _height == 0; + public bool IsEmpty => width == 0 && height == 0; /** * Horizontal dimension @@ -111,8 +111,8 @@ namespace System.Drawing /// </summary> public int Width { - get { return _width; } - set { _width = value; } + get { return width; } + set { width = value; } } /** @@ -125,8 +125,8 @@ namespace System.Drawing /// </summary> public int Height { - get { return _height; } - set { _height = value; } + get { return height; } + set { height = value; } } /// <summary> @@ -189,6 +189,6 @@ namespace System.Drawing /// <see cref='System.Drawing.Size'/>. /// </para> /// </summary> - public override string ToString() => "{Width=" + _width.ToString() + ", Height=" + _height.ToString() + "}"; + public override string ToString() => "{Width=" + width.ToString() + ", Height=" + height.ToString() + "}"; } } diff --git a/src/System.Drawing.Primitives/src/System/Drawing/SizeF.cs b/src/System.Drawing.Primitives/src/System/Drawing/SizeF.cs index 82ae869061..1ea50b1064 100644 --- a/src/System.Drawing.Primitives/src/System/Drawing/SizeF.cs +++ b/src/System.Drawing.Primitives/src/System/Drawing/SizeF.cs @@ -23,8 +23,8 @@ namespace System.Drawing /// Initializes a new instance of the <see cref='System.Drawing.SizeF'/> class. /// </summary> public static readonly SizeF Empty = new SizeF(); - private float _width; - private float _height; + private float width; // Do not rename (binary serialization) + private float height; // Do not rename (binary serialization) /** * Create a new SizeF object from another size object @@ -35,8 +35,8 @@ namespace System.Drawing /// </summary> public SizeF(SizeF size) { - _width = size._width; - _height = size._height; + width = size.width; + height = size.height; } /** @@ -50,8 +50,8 @@ namespace System.Drawing /// </summary> public SizeF(PointF pt) { - _width = pt.X; - _height = pt.Y; + width = pt.X; + height = pt.Y; } /** @@ -65,8 +65,8 @@ namespace System.Drawing /// </summary> public SizeF(float width, float height) { - _width = width; - _height = height; + this.width = width; + this.height = height; } /// <summary> @@ -111,7 +111,7 @@ namespace System.Drawing /// </para> /// </summary> [Browsable(false)] - public bool IsEmpty => _width == 0 && _height == 0; + public bool IsEmpty => width == 0 && height == 0; /** * Horizontal dimension @@ -125,8 +125,8 @@ namespace System.Drawing /// </summary> public float Width { - get { return _width; } - set { _width = value; } + get { return width; } + set { width = value; } } /** @@ -141,8 +141,8 @@ namespace System.Drawing /// </summary> public float Height { - get { return _height; } - set { _height = value; } + get { return height; } + set { height = value; } } /// <summary> @@ -183,7 +183,7 @@ namespace System.Drawing /// <see cref='System.Drawing.SizeF'/>. /// </para> /// </summary> - public override string ToString() => "{Width=" + _width.ToString() + ", Height=" + _height.ToString() + "}"; + public override string ToString() => "{Width=" + width.ToString() + ", Height=" + height.ToString() + "}"; } } |