728x90
반응형
728x170
using System;
using System.Collections.Generic;
using System.Reflection;
using Windows.UI;
#region 알려진 색상 리스트 구하기 - GetKnownColorList()
/// <summary>
/// 알려진 색상 리스트 구하기
/// </summary>
/// <returns>알려진 색상 리스트</returns>
public List<Color> GetKnownColorList()
{
List<Color> colorList = new List<Color>();
IEnumerable<PropertyInfo> propertyInfoEnumerable = typeof(Colors).GetTypeInfo().DeclaredProperties;
foreach(PropertyInfo property in propertyInfoEnumerable)
{
Color color = (Color)property.GetValue(null);
colorList.Add(color);
}
return colorList;
}
#endregion
728x90
반응형
그리드형(광고전용)
'C# > UWP' 카테고리의 다른 글
[C#/UWP] MessageDialog 클래스 사용하기 (await 연산자 사용하기) (0) | 2016.02.20 |
---|---|
[C#/UWP] MessageDialog 클래스 사용하기 (익명 대리자 사용) (0) | 2016.02.19 |
[C#/UWP] MessageDialog 클래스 사용하기 (0) | 2016.02.19 |
[C#/UWP] DisplayRequest 클래스 : 자동 디스플레이 끄기 방지하기 (0) | 2016.02.08 |
[C#/UWP] 클래스 계층도 표시하기 (0) | 2016.02.06 |
[C#/UWP] LinearGradientBrush 엘리먼트 : 무지개 색상 브러시 사용하기 (0) | 2016.01.23 |
[C#/UWP] Path 마크업에서 Geometry 구하기 (0) | 2016.01.23 |
[C#/UWP] HyperlinkButton 엘리먼트 : 앱 스토어 실행하기 (0) | 2016.01.22 |
[C#/UWP] WebView 클래스 : InvokeScript 메소드를 사용해 HTML 자바 스크립트 실행하기 (0) | 2016.01.22 |
[C#/UWP] WebView 클래스 : ScriptNotify 이벤트를 사용해 컨트롤에 포함된 콘텐츠가 JavaScript를 사용하여 애플리케이션에 문자열 전달하기 (0) | 2016.01.22 |
댓글을 달아 주세요