diff options
author | Kangho <rookiejava+github@gmail.com> | 2016-08-11 18:39:32 +0900 |
---|---|---|
committer | Stephane Delcroix <stephane@delcroix.org> | 2016-08-11 11:39:32 +0200 |
commit | ba29e59d20f4ae4b910b8576bc59af814ca4e151 (patch) | |
tree | baa1ec28b6770b4a2b7655c74fb1e5f58971c3b2 | |
parent | 69e9152f345a4a001282ddf60b19cc0a6b7d05e5 (diff) | |
download | xamarin-forms-ba29e59d20f4ae4b910b8576bc59af814ca4e151.tar.gz xamarin-forms-ba29e59d20f4ae4b910b8576bc59af814ca4e151.tar.bz2 xamarin-forms-ba29e59d20f4ae4b910b8576bc59af814ca4e151.zip |
Add Orange color to Color (#290)
* Add Orange color to Color
-rw-r--r-- | Xamarin.Forms.Core/Color.cs | 1 | ||||
-rw-r--r-- | Xamarin.Forms.Core/ColorTypeConverter.cs | 2 | ||||
-rw-r--r-- | docs/Xamarin.Forms.Core/Xamarin.Forms/Color.xml | 18 |
3 files changed, 20 insertions, 1 deletions
diff --git a/Xamarin.Forms.Core/Color.cs b/Xamarin.Forms.Core/Color.cs index e9f2987d..1444d98c 100644 --- a/Xamarin.Forms.Core/Color.cs +++ b/Xamarin.Forms.Core/Color.cs @@ -362,6 +362,7 @@ namespace Xamarin.Forms public static readonly Color Maroon = FromRgb(128, 0, 0); public static readonly Color Navy = FromRgb(0, 0, 128); public static readonly Color Olive = FromRgb(128, 128, 0); + public static readonly Color Orange = FromRgb(255, 165, 0); public static readonly Color Purple = FromRgb(128, 0, 128); public static readonly Color Pink = FromRgb(255, 102, 255); public static readonly Color Red = FromRgb(255, 0, 0); diff --git a/Xamarin.Forms.Core/ColorTypeConverter.cs b/Xamarin.Forms.Core/ColorTypeConverter.cs index 547adf3b..612174e9 100644 --- a/Xamarin.Forms.Core/ColorTypeConverter.cs +++ b/Xamarin.Forms.Core/ColorTypeConverter.cs @@ -42,6 +42,8 @@ namespace Xamarin.Forms return Color.Navy; case "Olive": return Color.Olive; + case "Orange": + return Color.Orange; case "Purple": return Color.Purple; case "Pink": diff --git a/docs/Xamarin.Forms.Core/Xamarin.Forms/Color.xml b/docs/Xamarin.Forms.Core/Xamarin.Forms/Color.xml index 755a61df..4368943b 100644 --- a/docs/Xamarin.Forms.Core/Xamarin.Forms/Color.xml +++ b/docs/Xamarin.Forms.Core/Xamarin.Forms/Color.xml @@ -43,7 +43,7 @@ <para>Application developers can specify colors in XAML either as a hexadecimal number or as a valid color name.</para> <para>When specifying a color with a hexadecimal number, app developers can use 3, 4, or 6 digits. If the developer specifies 3 digits, they are interpreted as RGB doublet data for a fully opaque color. For example, "#123" specifies the color that is represented by "#FF112233". If the developer provides a 4-digit hexadecimal number, then the data are interpreted as above, except that the first digit specifies the alpha channel. For example, "#1234" specifies the color that is represented by "#11223344". Finally, if the developer provides a 6 digit hexadecimal number, the data are interpreted as a fully opaque color with those RGB values. For example, "#112233" specifies the color that is represented by "#FF112233".</para> <para>When specifying a color with a string, app developers can use color name in isolation, or prefix it with "Color.". For example, both <c>Purple</c> and <c>Color.Purple</c> are valid ways to specify the color purple. The following table describes the valid color names that can be used to specify colors in XAML. -<list type="table"><listheader><term>Color</term><description>Short Name</description><description>RGB Value</description></listheader><item><term>Color.Transparent</term><description>Transparent</description><description>0, 0, 0 (With the alpha channel set to 0.)</description></item><item><term>Color.Aqua</term><description>Aqua</description><description>0, 255, 255</description></item><item><term>Color.Black</term><description>Black</description><description>0, 0, 0</description></item><item><term>Color.Blue</term><description>Blue</description><description>0, 0, 255</description></item><item><term>Color.Fuchsia</term><description>Fuchsia</description><description>255, 0, 255</description></item><item><term>Color.Gray</term><description>Gray</description><description>128, 128, 128</description></item><item><term>Color.Green</term><description>Green</description><description>0, 128, 0</description></item><item><term>Color.Lime</term><description>Lime</description><description>0, 255, 0</description></item><item><term>Color.Maroon</term><description>Maroon</description><description>128, 0, 0</description></item><item><term>Color.Navy</term><description>Navy</description><description>0, 0, 128</description></item><item><term>Color.Olive</term><description>Olive</description><description>128, 128, 0</description></item><item><term>Color.Purple</term><description>Purple</description><description>128, 0, 128</description></item><item><term>Color.Pink</term><description>Pink</description><description>255, 102, 255</description></item><item><term>Color.Red</term><description>Red</description><description>255, 0, 0</description></item><item><term>Color.Silver</term><description>Silver</description><description>192, 192, 192</description></item><item><term>Color.Teal</term><description>Teal</description><description>0, 128, 128</description></item><item><term>Color.White</term><description>White</description><description>255, 255, 255</description></item><item><term>Color.Yellow</term><description>Yellow</description><description>255, 255, 0</description></item></list></para> +<list type="table"><listheader><term>Color</term><description>Short Name</description><description>RGB Value</description></listheader><item><term>Color.Transparent</term><description>Transparent</description><description>0, 0, 0 (With the alpha channel set to 0.)</description></item><item><term>Color.Aqua</term><description>Aqua</description><description>0, 255, 255</description></item><item><term>Color.Black</term><description>Black</description><description>0, 0, 0</description></item><item><term>Color.Blue</term><description>Blue</description><description>0, 0, 255</description></item><item><term>Color.Fuchsia</term><description>Fuchsia</description><description>255, 0, 255</description></item><item><term>Color.Gray</term><description>Gray</description><description>128, 128, 128</description></item><item><term>Color.Green</term><description>Green</description><description>0, 128, 0</description></item><item><term>Color.Lime</term><description>Lime</description><description>0, 255, 0</description></item><item><term>Color.Maroon</term><description>Maroon</description><description>128, 0, 0</description></item><item><term>Color.Navy</term><description>Navy</description><description>0, 0, 128</description></item><item><term>Color.Olive</term><description>Olive</description><description>128, 128, 0</description></item><item><term>Color.Orange</term><description>Orange</description><description>255, 165, 0</description></item><item><term>Color.Purple</term><description>Purple</description><description>128, 0, 128</description></item><item><term>Color.Pink</term><description>Pink</description><description>255, 102, 255</description></item><item><term>Color.Red</term><description>Red</description><description>255, 0, 0</description></item><item><term>Color.Silver</term><description>Silver</description><description>192, 192, 192</description></item><item><term>Color.Teal</term><description>Teal</description><description>0, 128, 128</description></item><item><term>Color.White</term><description>White</description><description>255, 255, 255</description></item><item><term>Color.Yellow</term><description>Yellow</description><description>255, 255, 0</description></item></list></para> </remarks> </Docs> <Members> @@ -897,6 +897,22 @@ <remarks>To be added.</remarks> </Docs> </Member> + <Member MemberName="Orange"> + <MemberSignature Language="C#" Value="public static readonly Xamarin.Forms.Color Orange;" /> + <MemberSignature Language="ILAsm" Value=".field public static initonly valuetype Xamarin.Forms.Color Orange" /> + <MemberType>Field</MemberType> + <AssemblyInfo> + <AssemblyVersion>2.0.0.0</AssemblyVersion> + </AssemblyInfo> + <ReturnValue> + <ReturnType>Xamarin.Forms.Color</ReturnType> + </ReturnValue> + <Docs> + <summary>Orange, the color that is represented by the RGB value #ffa500.</summary> + <remarks> + </remarks> + </Docs> + </Member> <Member MemberName="Pink"> <MemberSignature Language="C#" Value="public static readonly Xamarin.Forms.Color Pink;" /> <MemberSignature Language="ILAsm" Value=".field public static initonly valuetype Xamarin.Forms.Color Pink" /> |