public HeaderElementStyle(Calendar Parent) { m_Parent = Parent; m_BStyle = new BorderStyle(this); m_BackgroundStyle = new BackgroundStyle(this); m_Padding = new MonthDaysPadding(this, 10, 6); m_Font = new Font("Tahoma", 9); }
public override object ConvertTo(ITypeDescriptorContext context, System.Globalization.CultureInfo culture, object value, Type destinationType) { if (destinationType == typeof(string) && (value is MonthDaysPadding)) { MonthDaysPadding myDaysPadding = (MonthDaysPadding)value; m_DaysPadding = myDaysPadding; return(myDaysPadding.Horizontal.ToString() + ";" + myDaysPadding.Vertical.ToString()); } return(base.ConvertTo(context, culture, value, destinationType)); }
public MonthDaysElementStyle(Calendar Parent) { m_Parent = Parent; m_BStyle = new BorderStyle(this); m_BackgroundStyle = new BackgroundStyle(this); m_SelectedDay = new ElementStyle(this); m_SelectedDay.ForeColor = Color.Black; m_SelectedDay.Background.StartColor = Color.FromArgb(230, 222, 185); m_SelectedDay.Background.Style = EStyle.esColor; m_HoverStyle = new HoverElementStyle(this); m_HoverStyle.Background.StartColor = Color.Blue; m_HoverStyle.Background.TransparencyStartColor = 128; m_HoverStyle.Background.Style = EStyle.esColor; m_HoverStyle.Border.BorderColor = Color.DarkBlue; m_HoverStyle.Border.Transparency = 128; m_HoverStyle.Border.Visible = true; m_TrailingDays = new ElementStyle(this); m_TrailingDays.ForeColor = Color.FromArgb(140, 140, 140); m_TrailingDays.Background.Style = EStyle.esParent; m_Padding = new Padding(2); m_Font = new Font("Tahoma", 9); m_DaysPadding = new MonthDaysPadding(this, 2, 2); }