Back to Devexpress

CustomMatrix8x14Presentation Class

wpf-devexpress-dot-xpf-dot-gauges-dot-custommatrix8x14presentation.md

latest3.5 KB
Original Source

CustomMatrix8x14Presentation Class

Contains presentation settings that specify the segment appearance.

Namespace : DevExpress.Xpf.Gauges

Assembly : DevExpress.Xpf.Gauges.v25.2.dll

NuGet Package : DevExpress.Wpf.Gauges

Declaration

csharp
public class CustomMatrix8x14Presentation :
    Matrix8x14Presentation
vb
Public Class CustomMatrix8x14Presentation
    Inherits Matrix8x14Presentation

Example

This example demonstrates how to define a custom matrix 8x14 presentation.

xaml
<Window
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:local="clr-namespace:GaugesDemoApp"
        xmlns:dxga="http://schemas.devexpress.com/winfx/2008/xaml/gauges" 
        x:Class="GaugesDemoApp.MainWindow"
        Title="MainWindow" Height="300" Width="500">
    <Grid>
        <dxga:DigitalGaugeControl Text="Ellipse">
            <dxga:DigitalGaugeControl.SymbolView>
                <dxga:MatrixView8x14>
                    <dxga:MatrixView8x14.Presentation>
                        <dxga:CustomMatrix8x14Presentation>
                            <dxga:CustomMatrix8x14Presentation.ActiveSegmentTemplate>
                                <DataTemplate>
                                    <Grid>
                                        <Ellipse Fill="Red" Margin="1"/>
                                        <Ellipse Fill="Yellow" Margin="1.5"/>
                                    </Grid>
                                </DataTemplate>
                            </dxga:CustomMatrix8x14Presentation.ActiveSegmentTemplate>
                            <dxga:CustomMatrix8x14Presentation.InactiveSegmentTemplate>
                                <DataTemplate>
                                    <Ellipse Fill="LightGray" Margin="1.5"/>
                                </DataTemplate>
                            </dxga:CustomMatrix8x14Presentation.InactiveSegmentTemplate>
                        </dxga:CustomMatrix8x14Presentation>
                    </dxga:MatrixView8x14.Presentation>
                </dxga:MatrixView8x14>
            </dxga:DigitalGaugeControl.SymbolView>
        </dxga:DigitalGaugeControl>
    </Grid>
</Window>

The image below illustrates the result.

Inheritance

Object DispatcherObject DependencyObject Freezable GaugeDependencyObject PresentationBase DevExpress.Xpf.Gauges.SymbolPresentation Matrix8x14Presentation CustomMatrix8x14Presentation

See Also

CustomMatrix8x14Presentation Members

DevExpress.Xpf.Gauges Namespace