Esempio n. 1
0
 private void cbExportElementType_SelectionChanged(object sender, Telerik.Windows.Controls.SelectionChangedEventArgs e)
 {
     if (e.AddedItems.Count > 0)
     {
         ExportElementOptions selectedOption = ExportElementOptionsInfo.Where(t => t.ExportElementType == (e.AddedItems[0] as ExportElementType).ExportElementTypeValue).FirstOrDefault();
         this.rcpBackground.SelectedColor = selectedOption.ExportElementBackground;
         this.rcpForeground.SelectedColor = selectedOption.ExportElementForeground;
         this.rnudFontSize.Value          = selectedOption.ExportElementFontSize;
         if (ExportFontFamilyInfo == null)
         {
             InitializeExportFontFamilyInfo();
         }
         this.cbFontFamily.SelectedValue = ExportFontFamilyInfo.Where(t => t.ExportFontFamilyValue.Source == selectedOption.ExportElementFontFamily.Source).FirstOrDefault();
         if (ExportFontWeightInfo == null)
         {
             InitializeExportFontWeightInfo();
         }
         this.cbFontWeight.SelectedValue = ExportFontWeightInfo.Where(t => t.ExportFontWeightValue == selectedOption.ExportElementFontWeight).FirstOrDefault();
         if (ExportTextAlignmentInfo == null)
         {
             InitializeExportTextAlignmentInfo();
         }
         this.cbTextAllignment.SelectedValue = ExportTextAlignmentInfo.Where(t => t.ExportTextAlignmentValue == selectedOption.ExportElementTextAlignment).FirstOrDefault();
     }
 }
Esempio n. 2
0
 private void cbTextAllignment_SelectionChanged(object sender, Telerik.Windows.Controls.SelectionChangedEventArgs e)
 {
     if (cbExportElementType != null)
     {
         ExportElementType exportElementType = this.cbExportElementType.SelectedValue as ExportElementType;
         ExportElementOptionsInfo.Where(t => t.ExportElementType == exportElementType.ExportElementTypeValue).FirstOrDefault().ExportElementTextAlignment = ((ExportTextAlignment)this.cbTextAllignment.SelectedValue).ExportTextAlignmentValue;
     }
 }
Esempio n. 3
0
 private void rnudFontSize_ValueChanged(object sender, RadRangeBaseValueChangedEventArgs e)
 {
     if (cbExportElementType != null)
     {
         ExportElementType exportElementType = this.cbExportElementType.SelectedValue as ExportElementType;
         ExportElementOptionsInfo.Where(t => t.ExportElementType == exportElementType.ExportElementTypeValue).FirstOrDefault().ExportElementFontSize = (double)this.rnudFontSize.Value;
     }
 }
Esempio n. 4
0
 private void rcpForeground_SelectedColorChanged(object sender, EventArgs e)
 {
     if (cbExportElementType != null)
     {
         ExportElementType exportElementType = this.cbExportElementType.SelectedValue as ExportElementType;
         ExportElementOptionsInfo.Where(t => t.ExportElementType == exportElementType.ExportElementTypeValue).FirstOrDefault().ExportElementForeground = this.rcpForeground.SelectedColor;
     }
 }