コード例 #1
0
 private void btnCustomizeThisContentType_Click(object sender, EventArgs e)
 {
     try {
         IndentTheme theme;
         if (!Service.Themes.TryGetValue(CurrentContentType, out theme))
         {
             if (ActiveTheme == null)
             {
                 theme = new IndentTheme();
             }
             else
             {
                 theme = ActiveTheme.Clone();
             }
             theme.ContentType = CurrentContentType;
             Service.Themes[CurrentContentType] = theme;
             UpdateThemeList();
         }
         cmbTheme.SelectedItem = theme;
     } catch (Exception ex) {
         Trace.WriteLine(string.Format("IndentGuide::btnCustomizeThisContentType_Click: {0}", ex));
     }
 }