Spread WPF 18
GrapeCity.Wpf.SpreadSheet.CellType.Editors Namespace / CalendarDayButton Class
Members


In This Topic
    CalendarDayButton Class
    In This Topic
    Object Model
    CalendarDayButton Class
    Syntax
    'Declaration
     
    <DesignTimeVisibleAttribute(False)>
    <TemplatePartAttribute(Name="PART_Content", Type=System.Windows.FrameworkElement)>
    <TemplateVisualStateAttribute(Name="Selected", GroupName="SelectionStates")>
    <DefaultEventAttribute("Click")>
    <LocalizabilityAttribute(LocalizationCategory.Button)>
    <DefaultPropertyAttribute("Content")>
    <ContentPropertyAttribute("Content")>
    <StyleTypedPropertyAttribute(Property="FocusVisualStyle", StyleTargetType=System.Windows.Controls.Control)>
    <XmlLangPropertyAttribute("Language")>
    <UsableDuringInitializationAttribute(True)>
    <RuntimeNamePropertyAttribute("Name")>
    <UidPropertyAttribute("Uid")>
    <TypeDescriptionProviderAttribute(MS.Internal.ComponentModel.DependencyObjectProvider)>
    <NameScopePropertyAttribute("NameScope", System.Windows.NameScope)>
    Public NotInheritable Class CalendarDayButton 
       Inherits System.Windows.Controls.Button
    'Usage
     
    Dim instance As CalendarDayButton
    [DesignTimeVisible(false)]
    [TemplatePart(Name="PART_Content", Type=System.Windows.FrameworkElement)]
    [TemplateVisualState(Name="Selected", GroupName="SelectionStates")]
    [DefaultEvent("Click")]
    [Localizability(LocalizationCategory.Button)]
    [DefaultProperty("Content")]
    [ContentProperty("Content")]
    [StyleTypedProperty(Property="FocusVisualStyle", StyleTargetType=System.Windows.Controls.Control)]
    [XmlLangProperty("Language")]
    [UsableDuringInitialization(true)]
    [RuntimeNameProperty("Name")]
    [UidProperty("Uid")]
    [TypeDescriptionProvider(MS.Internal.ComponentModel.DependencyObjectProvider)]
    [NameScopeProperty("NameScope", System.Windows.NameScope)]
    public sealed class CalendarDayButton : System.Windows.Controls.Button 
    Remarks
    The CalendarDayButton offered some properties for customizing visual presentation via styling:

    The IsInactive indicates whether the CalendarDayButton is trailing status. The IsSelected indicates whether the day the CalendarDayButton represents is selected. The IsToday indicates whether the day the CalendarDayButton represents Today. The IsBlackedOut indicates whether the day the CalendarDayButton represents is non-selectable.

    The CalendarDayButton also offered a DayInfo property to deliver more information about the day which it represents. It is set to the System.Windows.Controls.ContentControl.Content property, and you could also customizing the data presentation via System.Windows.Controls.ContentControl.ContentTemplate.

    Supported System.Windows.VisualState list:

    VisualStateGroup Name

    VisualState Name

    Description

    CommonStates

    Normal

    Represents the visual appearance when control is in normal state.

    CommonStates

    Disabled

    Represents the visual appearance when System.Windows.UIElement.IsEnabled is false.

    CommonStates

    Pressed

    Represents the visual appearance when System.Windows.Controls.Primitives.ButtonBase.IsPressed is true.

    CommonStates

    MouseOver

    Represents the visual appearance when System.Windows.UIElement.IsMouseOver is true.

    SelectionStates

    Selected

    Represents the visual appearance when IsHighlighted or IsSelected is true.
    If the Selected state isn't defined in System.Windows.Controls.ControlTemplate, Unselected state will be used.

    SelectionStates

    Unselected

    Represents the visual appearance when IsHighlighted and IsSelected all are false.

    ActiveStates

    Active

    Represents the visual appearance when IsInactive is false.
    If the Active state isn't defined in System.Windows.Controls.ControlTemplate, Inactive state will be used.

    ActiveStates

    Inactive

    Represents the visual appearance when IsInactive is true.

    CalendarButtonFocusStates

    CalendarButtonFocused

    Represents the visual appearance when System.Windows.UIElement.IsKeyboardFocused is true.
    If the CalendarButtonFocused state isn't defined in System.Windows.Controls.ControlTemplate, CalendarButtonUnfocused state will be used.

    CalendarButtonFocusStates

    CalendarButtonUnfocused

    Represents the visual appearance when System.Windows.UIElement.IsKeyboardFocused is false.

    DayStates

    Today

    Represents the visual appearance when IsToday is true.
    If the Today state isn't defined in System.Windows.Controls.ControlTemplate, RegularDay state will be used.

    DayStates

    RegularDay

    Represents the visual appearance when IsToday is false.

    BlackoutDayStates

    BlackoutDay

    Represents the visual appearance when IsBlackedOut is true.
    If the BlackoutDay state isn't defined in System.Windows.Controls.ControlTemplate, NormalDay state will be used.

    BlackoutDayStates

    NormalDay

    Represents the visual appearance when IsBlackedOut is false.

    HolidayStates

    OverrideHoliday

    Represents the visual appearance when GrapeCity.Windows.InputMan.Primitives.DayInfo.IsOverrideHoliday is true.
    If the OverrideHoliday state isn't defined in System.Windows.Controls.ControlTemplate, Holiday state will be used.

    HolidayStates

    WeeklyHoliday

    Represents the visual appearance when GrapeCity.Windows.InputMan.Primitives.DayInfo.IsWeeklyHoliday is true.
    If the WeeklyHoliday state isn't defined in System.Windows.Controls.ControlTemplate, Holiday state will be used.

    HolidayStates

    Holiday

    Represents the visual appearance when GrapeCity.Windows.InputMan.Primitives.DayInfo.IsHoliday is true but GrapeCity.Windows.InputMan.Primitives.DayInfo.IsWeeklyHoliday and GrapeCity.Windows.InputMan.Primitives.DayInfo.IsOverrideHoliday are false.

    HolidayStates

    ForcedWorkday

    Represents the visual appearance when GrapeCity.Windows.InputMan.Primitives.DayInfo.IsForceWorkday is true.
    If the ForcedWorkday state isn't defined in System.Windows.Controls.ControlTemplate, Workday state will be used.

    HolidayStates

    Workday

    Represents the visual appearance when GrapeCity.Windows.InputMan.Primitives.DayInfo.IsForceWorkday, GrapeCity.Windows.InputMan.Primitives.DayInfo.IsWeeklyHoliday, GrapeCity.Windows.InputMan.Primitives.DayInfo.IsOverrideHoliday and GrapeCity.Windows.InputMan.Primitives.DayInfo.IsHoliday all are false.

    FocusStates

    Focused

    Represents the visual appearance when System.Windows.UIElement.IsKeyboardFocused is true.

    FocusStates

    Unfocused

    Represents the visual appearance when System.Windows.UIElement.IsKeyboardFocused is false.

    ValidationStates

    Valid

    Represents the visual appearance when System.Windows.Controls.Validation.GetHasError(System.Windows.DependencyObject) returns false.

    ValidationStates

    InvalidFocused

    Represents the visual appearance when System.Windows.Controls.Validation.GetHasError(System.Windows.DependencyObject) returns true and System.Windows.UIElement.IsKeyboardFocused is true.

    ValidationStates

    InvalidUnfocused

    Represents the visual appearance when System.Windows.Controls.Validation.GetHasError(System.Windows.DependencyObject) returns true and System.Windows.UIElement.IsKeyboardFocused is false.

    Inheritance Hierarchy

    System.Object
       System.Windows.Threading.DispatcherObject
          System.Windows.DependencyObject
             System.Windows.Media.Visual
                System.Windows.UIElement
                   System.Windows.FrameworkElement
                      System.Windows.Controls.Control
                         System.Windows.Controls.ContentControl
                            System.Windows.Controls.Primitives.ButtonBase
                               System.Windows.Controls.Button
                                  GrapeCity.Wpf.SpreadSheet.CellType.Editors.CalendarDayButton

    See Also