implemented function edit and alllows the edit in input and output now
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
<Window x:Class="Nodify.Calculator.CreateFunctionDialog"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
Title="Create New Function"
|
||||
Title="{Binding DialogTitle, RelativeSource={RelativeSource Self}, FallbackValue='Create New Function'}"
|
||||
Width="500"
|
||||
Height="520"
|
||||
WindowStartupLocation="CenterOwner"
|
||||
@@ -36,8 +36,32 @@
|
||||
AlternatingRowBackground="#333337" GridLinesVisibility="None"
|
||||
HeadersVisibility="Column" BorderBrush="#555">
|
||||
<DataGrid.Columns>
|
||||
<DataGridTextColumn Header="Name" Binding="{Binding Name}" Width="*" />
|
||||
<DataGridTextColumn Header="Name" Binding="{Binding Name}" Width="*">
|
||||
<DataGridTextColumn.ElementStyle>
|
||||
<Style TargetType="TextBlock">
|
||||
<Setter Property="Foreground" Value="White" />
|
||||
</Style>
|
||||
</DataGridTextColumn.ElementStyle>
|
||||
<DataGridTextColumn.EditingElementStyle>
|
||||
<Style TargetType="TextBox">
|
||||
<Setter Property="Foreground" Value="Black" />
|
||||
<Setter Property="Background" Value="White" />
|
||||
</Style>
|
||||
</DataGridTextColumn.EditingElementStyle>
|
||||
</DataGridTextColumn>
|
||||
<DataGridComboBoxColumn Header="Type" SelectedItemBinding="{Binding Type}" Width="120">
|
||||
<DataGridComboBoxColumn.ElementStyle>
|
||||
<Style TargetType="ComboBox">
|
||||
<Setter Property="Foreground" Value="White" />
|
||||
<Setter Property="Background" Value="#3E3E42" />
|
||||
</Style>
|
||||
</DataGridComboBoxColumn.ElementStyle>
|
||||
<DataGridComboBoxColumn.EditingElementStyle>
|
||||
<Style TargetType="ComboBox">
|
||||
<Setter Property="Foreground" Value="Black" />
|
||||
<Setter Property="Background" Value="White" />
|
||||
</Style>
|
||||
</DataGridComboBoxColumn.EditingElementStyle>
|
||||
<DataGridComboBoxColumn.ItemsSource>
|
||||
<x:Array Type="sys:String" xmlns:sys="clr-namespace:System;assembly=System.Runtime">
|
||||
<sys:String>string</sys:String>
|
||||
@@ -67,8 +91,32 @@
|
||||
AlternatingRowBackground="#333337" GridLinesVisibility="None"
|
||||
HeadersVisibility="Column" BorderBrush="#555">
|
||||
<DataGrid.Columns>
|
||||
<DataGridTextColumn Header="Name" Binding="{Binding Name}" Width="*" />
|
||||
<DataGridTextColumn Header="Name" Binding="{Binding Name}" Width="*">
|
||||
<DataGridTextColumn.ElementStyle>
|
||||
<Style TargetType="TextBlock">
|
||||
<Setter Property="Foreground" Value="White" />
|
||||
</Style>
|
||||
</DataGridTextColumn.ElementStyle>
|
||||
<DataGridTextColumn.EditingElementStyle>
|
||||
<Style TargetType="TextBox">
|
||||
<Setter Property="Foreground" Value="Black" />
|
||||
<Setter Property="Background" Value="White" />
|
||||
</Style>
|
||||
</DataGridTextColumn.EditingElementStyle>
|
||||
</DataGridTextColumn>
|
||||
<DataGridComboBoxColumn Header="Type" SelectedItemBinding="{Binding Type}" Width="120">
|
||||
<DataGridComboBoxColumn.ElementStyle>
|
||||
<Style TargetType="ComboBox">
|
||||
<Setter Property="Foreground" Value="White" />
|
||||
<Setter Property="Background" Value="#3E3E42" />
|
||||
</Style>
|
||||
</DataGridComboBoxColumn.ElementStyle>
|
||||
<DataGridComboBoxColumn.EditingElementStyle>
|
||||
<Style TargetType="ComboBox">
|
||||
<Setter Property="Foreground" Value="Black" />
|
||||
<Setter Property="Background" Value="White" />
|
||||
</Style>
|
||||
</DataGridComboBoxColumn.EditingElementStyle>
|
||||
<DataGridComboBoxColumn.ItemsSource>
|
||||
<x:Array Type="sys:String" xmlns:sys="clr-namespace:System;assembly=System.Runtime">
|
||||
<sys:String>string</sys:String>
|
||||
@@ -88,7 +136,7 @@
|
||||
|
||||
<!-- Buttons -->
|
||||
<StackPanel Orientation="Horizontal" HorizontalAlignment="Right" Grid.Row="6">
|
||||
<Button Content="Create" Width="80" Margin="0 0 10 0" Padding="4"
|
||||
<Button x:Name="CreateButton" Content="Create" Width="80" Margin="0 0 10 0" Padding="4"
|
||||
Click="OnCreateClick" IsDefault="True" />
|
||||
<Button Content="Cancel" Width="80" Padding="4"
|
||||
Click="OnCancelClick" IsCancel="True" />
|
||||
|
||||
Reference in New Issue
Block a user