/
n-dimens
/
pascalabcnet
Обзор
Документация
Войти
/
n-dimens
/
pascalabcnet
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
InteractiveDataDisplay_OneDll/samples/LineGraphSample/MainWindow.xaml
35 строк
2 KB
Mikhalkovich Stanislav
Новый модуль PlotWPF на основе InteractiveDataDisplay.WPF.dll
13 июл 2021, 23:52
13 июл 2021, 23:52
fea18f8
Код
Авторство
О чём код?
<Window x:Class="LineGraphSample.MainWindow" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:d3="clr-namespace:InteractiveDataDisplay.WPF;assembly=InteractiveDataDisplay.WPF" xmlns:local="clr-namespace:LineGraphSample" mc:Ignorable="d" Title="Line graph" Height="600" Width="800"> <Window.Resources> <local:VisibilityToCheckedConverter x:Key="VisibilityToCheckedConverter"/> </Window.Resources> <Grid x:Name="LayoutRoot" Background="White"> <d3:Chart Name="plotter" IsXAxisReversed="True"> <d3:Chart.Title> <TextBlock HorizontalAlignment="Center" FontSize="18" Margin="0,5,0,5">Line graph legend sample</TextBlock> </d3:Chart.Title> <d3:Chart.LegendContent> <d3:LegendItemsPanel> <d3:LegendItemsPanel.Resources> <DataTemplate x:Key="InteractiveDataDisplay.WPF.LineGraph"> <StackPanel Orientation="Horizontal"> <CheckBox IsChecked="{Binding Path=Visibility, Converter={StaticResource VisibilityToCheckedConverter}, Mode=TwoWay}"/> <Line Width="15" Height="15" X1="0" Y1="0" X2="15" Y2="15" Stroke="{Binding Path=Stroke}" StrokeThickness="2"/> <TextBlock Margin="5,0,0,0" Text="{Binding Path=Description}"/> </StackPanel> </DataTemplate> </d3:LegendItemsPanel.Resources> </d3:LegendItemsPanel> </d3:Chart.LegendContent> <Grid Name="lines"/> </d3:Chart> </Grid> </Window>