Add ToColor
This commit is contained in:
parent
35a01a0415
commit
30e8f6070a
1 changed files with 9 additions and 0 deletions
|
|
@ -543,6 +543,15 @@ public static class UniversalExtensions
|
|||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Convert Hex to Color
|
||||
/// </summary>
|
||||
/// <returns>The converted color</returns>
|
||||
public static Color ToColor(this string str)
|
||||
{
|
||||
return ColorTranslator.FromHtml(str);
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Convert RGB Value to Hex
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue