Back to Devexpress

MonthViewCellViewModel Class

mobilecontrols-devexpress-dot-xamarinforms-dot-scheduler-72c5db28.md

latest5.1 KB
Original Source

MonthViewCellViewModel Class

The storage for appearance settings values of an individual month view cell‘s representation.

Namespace : DevExpress.XamarinForms.Scheduler

Assembly : DevExpress.XamarinForms.Scheduler.dll

NuGet Package : DevExpress.XamarinForms.Scheduler

Declaration

csharp
public class MonthViewCellViewModel :
    CellViewModel

Remarks

The Scheduler View uses this class is the following occurrences:

This view model provides the following settings that you can customize:

Example

This example demonstrates how to use the month view cell style and its customizer to modify the cell’s appearance.

xml
<dxs:MonthView.HeaderItemStyle>
    <dxs:MonthViewHeaderItemStyle>
        <dxs:MonthViewHeaderItemStyle.TodayWeekDayTextStyle>
            <dxs:TextStyle Color="#ff8000"/>
        </dxs:MonthViewHeaderItemStyle.TodayWeekDayTextStyle>
        <dxs:MonthViewHeaderItemStyle.Customizer>
            <views:MonthViewHeaderItemCustomizer/>
        </dxs:MonthViewHeaderItemStyle.Customizer>
    </dxs:MonthViewHeaderItemStyle>
</dxs:MonthView.HeaderItemStyle>
csharp
class MonthViewHeaderItemCustomizer : IMonthViewHeaderItemCustomizer {
    public void Customize(MonthViewHeaderItemViewModel header) {
        if (header.IsToday) {
            var tmp = header.BackgroundColor;
            header.BackgroundColor = header.WeekDayTextColor;
            header.WeekDayTextColor = tmp;
        }
    }
}

|

Symbol

|

Description

| | --- | --- | |

MonthView.AllDayCellStyle

|

Gets or sets appearance settings of cells.

| |

MonthViewCellStyle

|

The storage for month view cell appearance settings.

| |

MonthViewCellStyle.Customizer

|

Gets or sets an object that customizes the month view cell’s appearance depending on internal logic.

| |

IMonthViewCellCustomizer

|

The interface that should implement a class that modifies appearance settings of individual Month View cells.

| |

IMonthViewCellCustomizer.Customize(MonthViewCellViewModel)

|

Modifies appearance settings of an individual Month View cell.

| |

MonthViewCellViewModel

|

The storage for appearance settings values of an individual month view cell‘s representation.

|

Implements

INotifyPropertyChanged

INotifyPropertyChanging

Inheritance

Object DevExpress.XamarinForms.Scheduler.Internal.NotifyPropertyChangedBase ItemViewModel CellViewModel MonthViewCellViewModel

See Also

MonthViewCellViewModel Members

DevExpress.XamarinForms.Scheduler Namespace