daixinet

  博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理

2012年7月31日

摘要: 枚举m_Theme.HorizontalAlignment = (HorizontalAlignment)Enum.Parse(typeof(HorizontalAlignment), m_HorizontalAlignment);结构m_Theme.FontWeight = (FontWeight)System.ComponentModel.TypeDescriptor.GetConverter(typeof(FontWeight)).ConvertFromString(m_FontWeightName); 阅读全文
posted @ 2012-07-31 15:39 daixinet.com 阅读(1348) 评论(0) 推荐(0) 编辑

摘要: 今天做主题时,需要访问外部的xaml文件,方法:using (FileStream s = new FileStream("C:\\Control.xaml", FileMode.Open)) { ResourceDictionary rd = System.Windows.Markup.XamlReader.Load(s) as ResourceDictionary; this.Resources.MergedDictionaries.Clear(); this.Resources... 阅读全文
posted @ 2012-07-31 11:08 daixinet.com 阅读(526) 评论(0) 推荐(0) 编辑