2019-07-09 00:02:25 +00:00
|
|
|
<!--
|
|
|
|
Copyright 2019 faddenSoft
|
|
|
|
|
|
|
|
Licensed under the Apache License, Version 2.0 (the "License");
|
|
|
|
you may not use this file except in compliance with the License.
|
|
|
|
You may obtain a copy of the License at
|
|
|
|
|
|
|
|
http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
|
|
|
|
Unless required by applicable law or agreed to in writing, software
|
|
|
|
distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
|
See the License for the specific language governing permissions and
|
|
|
|
limitations under the License.
|
|
|
|
-->
|
|
|
|
|
2019-07-20 20:28:10 +00:00
|
|
|
<Window x:Class="SourceGen.WpfGui.EditDataOperand"
|
2019-07-09 00:02:25 +00:00
|
|
|
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:system="clr-namespace:System;assembly=mscorlib"
|
2019-07-20 20:28:10 +00:00
|
|
|
xmlns:local="clr-namespace:SourceGen.WpfGui"
|
2019-07-09 00:02:25 +00:00
|
|
|
mc:Ignorable="d"
|
|
|
|
Title="Edit Data Operand"
|
|
|
|
SizeToContent="WidthAndHeight" ResizeMode="NoResize"
|
|
|
|
ShowInTaskbar="False" WindowStartupLocation="CenterOwner"
|
|
|
|
Loaded="Window_Loaded"
|
|
|
|
ContentRendered="Window_ContentRendered">
|
|
|
|
|
|
|
|
<Window.Resources>
|
2019-07-11 20:56:16 +00:00
|
|
|
<system:String x:Key="str_SingleByte">Select data format (1 byte selected):</system:String>
|
|
|
|
<system:String x:Key="str_SingleGroup">Select data format ({0} bytes selected):</system:String>
|
2019-07-09 00:02:25 +00:00
|
|
|
<system:String x:Key="str_MultiGroup">Select data format ({0} bytes selected in {1} groups):</system:String>
|
2019-07-11 20:56:16 +00:00
|
|
|
|
2019-08-16 00:53:12 +00:00
|
|
|
<system:String x:Key="str_StringMixed">Mixed character ({0} bytes) and non-character ({1} bytes)</system:String>
|
|
|
|
<system:String x:Key="str_StringMixedReverse">Reversed character ({0} bytes) and non-character ({1} bytes)</system:String>
|
2019-07-11 20:56:16 +00:00
|
|
|
<system:String x:Key="str_StringNullTerm">Null-terminated strings ({0})</system:String>
|
|
|
|
<system:String x:Key="str_StringLen8">Strings prefixed with 8-bit length ({0})</system:String>
|
|
|
|
<system:String x:Key="str_StringLen16">Strings prefixed with 16-bit length ({0})</system:String>
|
|
|
|
<system:String x:Key="str_StringDci">Dextral character inverted ({0})</system:String>
|
2019-10-19 03:28:02 +00:00
|
|
|
|
|
|
|
<system:String x:Key="str_AlignmentNone">arbitrary boundary</system:String>
|
|
|
|
<system:String x:Key="str_AlignmentItemFmt">{0}-byte boundary ({1})</system:String>
|
2019-07-09 00:02:25 +00:00
|
|
|
</Window.Resources>
|
|
|
|
|
|
|
|
<StackPanel Margin="8">
|
2019-07-11 20:56:16 +00:00
|
|
|
<TextBlock Name="selectFormatLabel" Text="{StaticResource str_MultiGroup}"/>
|
2019-09-18 18:27:28 +00:00
|
|
|
<RadioButton Name="radioDefaultFormat" GroupName="Main" Content="D_efault" Margin="0,8,0,0"
|
|
|
|
Checked="MainGroup_CheckedChanged"/>
|
2019-07-09 00:02:25 +00:00
|
|
|
|
|
|
|
<TextBlock Text="Simple Data" Margin="0,12,0,0"/>
|
|
|
|
<Rectangle HorizontalAlignment="Stretch" Fill="LightGray" Height="2"/>
|
|
|
|
<Grid>
|
|
|
|
<Grid.ColumnDefinitions>
|
|
|
|
<ColumnDefinition Width="Auto"/>
|
|
|
|
<ColumnDefinition Width="*"/>
|
|
|
|
</Grid.ColumnDefinitions>
|
|
|
|
<StackPanel Grid.Column="0">
|
2019-07-11 20:56:16 +00:00
|
|
|
<RadioButton Name="radioSingleBytes" GroupName="Main" Content="Single _bytes" Margin="0,4,0,0"
|
|
|
|
Checked="MainGroup_CheckedChanged"/>
|
|
|
|
<RadioButton Name="radio16BitLittle" GroupName="Main" Content="16-bit words, little-endian" Margin="0,4,0,0"
|
|
|
|
Checked="MainGroup_CheckedChanged"/>
|
|
|
|
<RadioButton Name="radio16BitBig" GroupName="Main" Content="16-bit words, big-endian" Margin="0,4,0,0"
|
|
|
|
Checked="MainGroup_CheckedChanged"/>
|
|
|
|
<RadioButton Name="radio24BitLittle" GroupName="Main" Content="24-bit words, little-endian" Margin="0,4,0,0"
|
|
|
|
Checked="MainGroup_CheckedChanged"/>
|
|
|
|
<RadioButton Name="radio32BitLittle" GroupName="Main" Content="32-bit words, little-endian" Margin="0,4,0,0"
|
|
|
|
Checked="MainGroup_CheckedChanged"/>
|
2019-07-09 00:02:25 +00:00
|
|
|
</StackPanel>
|
2019-08-16 00:53:12 +00:00
|
|
|
<GroupBox Name="simpleDisplayAsGroupBox" Grid.Column="1" Header="Display As..." Margin="16,0,0,0"
|
|
|
|
Padding="2,4">
|
2019-07-09 00:02:25 +00:00
|
|
|
<Grid>
|
|
|
|
<Grid.ColumnDefinitions>
|
|
|
|
<ColumnDefinition Width="*"/>
|
|
|
|
<ColumnDefinition Width="*"/>
|
|
|
|
</Grid.ColumnDefinitions>
|
2019-08-16 00:53:12 +00:00
|
|
|
<Grid.RowDefinitions>
|
|
|
|
<RowDefinition Height="Auto"/>
|
|
|
|
<RowDefinition Height="Auto"/>
|
2019-09-15 20:16:38 +00:00
|
|
|
<RowDefinition Height="Auto"/>
|
|
|
|
<RowDefinition Height="Auto"/>
|
|
|
|
<RowDefinition Height="Auto"/>
|
2019-08-16 00:53:12 +00:00
|
|
|
</Grid.RowDefinitions>
|
2019-09-15 20:16:38 +00:00
|
|
|
<RadioButton Name="radioSimpleDataHex" Grid.Column="0" Grid.Row="0"
|
2019-09-18 18:27:28 +00:00
|
|
|
GroupName="Display" Content="_Hex" Checked="SimpleDisplay_CheckedChanged"/>
|
2019-09-15 20:16:38 +00:00
|
|
|
<RadioButton Name="radioSimpleDataDecimal" Grid.Column="0" Grid.Row="1"
|
2019-09-18 18:27:28 +00:00
|
|
|
GroupName="Display" Content="_Decimal" Margin="0,4,18,0"
|
2019-09-15 20:16:38 +00:00
|
|
|
Checked="SimpleDisplay_CheckedChanged"/>
|
|
|
|
<RadioButton Name="radioSimpleDataBinary" Grid.Column="0" Grid.Row="2"
|
2019-09-18 18:27:28 +00:00
|
|
|
GroupName="Display" Content="_Binary" Margin="0,4,0,0"
|
2019-09-15 20:16:38 +00:00
|
|
|
Checked="SimpleDisplay_CheckedChanged"/>
|
|
|
|
|
|
|
|
<RadioButton Name="radioSimpleDataAscii" Grid.Column="1" Grid.Row="0"
|
2019-09-18 18:27:28 +00:00
|
|
|
GroupName="Display" Content="_ASCII (low or high) character"
|
2019-09-15 20:16:38 +00:00
|
|
|
Checked="SimpleDisplay_CheckedChanged"/>
|
|
|
|
<RadioButton Name="radioSimpleDataPetscii" Grid.Column="1" Grid.Row="1"
|
2019-09-18 18:27:28 +00:00
|
|
|
GroupName="Display" Content="C64 _PETSCII character" Margin="0,4,0,0"
|
2019-09-15 20:16:38 +00:00
|
|
|
Checked="SimpleDisplay_CheckedChanged"/>
|
|
|
|
<RadioButton Name="radioSimpleDataScreenCode" Grid.Column="1" Grid.Row="2"
|
2019-09-18 18:27:28 +00:00
|
|
|
GroupName="Display" Content="C64 S_creen character" Margin="0,4,0,0"
|
2019-09-15 20:16:38 +00:00
|
|
|
Checked="SimpleDisplay_CheckedChanged"/>
|
|
|
|
|
|
|
|
<RadioButton Name="radioSimpleDataAddress" Grid.Column="0" Grid.Row="3" GroupName="Display"
|
2019-09-18 18:27:28 +00:00
|
|
|
Content="Add_ress" Margin="0,4,0,0" Checked="SimpleDisplay_CheckedChanged"/>
|
2019-09-15 20:16:38 +00:00
|
|
|
<!--<TextBox Grid.Column="1" Grid.Row="3" Margin="-8,4,0,0" Width="50" HorizontalAlignment="Left"
|
|
|
|
FontFamily="{StaticResource GeneralMonoFont}"
|
|
|
|
Text="{Binding SomethingCool, FallbackValue=+1Add}"/>-->
|
|
|
|
|
|
|
|
<StackPanel Grid.Column="0" Grid.Row="4" Grid.ColumnSpan="2">
|
2019-07-11 20:56:16 +00:00
|
|
|
<RadioButton Name="radioSimpleDataSymbolic" GroupName="Display" Content="_Symbolic reference"
|
2019-08-16 00:53:12 +00:00
|
|
|
Margin="0,4,0,0" Checked="SimpleDisplay_CheckedChanged"/>
|
2019-09-15 20:16:38 +00:00
|
|
|
<TextBox Name="symbolEntryTextBox" Margin="20,4,0,0" FontFamily="{StaticResource GeneralMonoFont}"
|
|
|
|
TextChanged="SymbolEntryTextBox_TextChanged"/>
|
2019-08-16 00:53:12 +00:00
|
|
|
|
|
|
|
<StackPanel Orientation="Horizontal" Margin="20,4,0,0"
|
2019-07-11 20:56:16 +00:00
|
|
|
IsEnabled="{Binding ElementName=radioSimpleDataSymbolic, Path=IsChecked}">
|
|
|
|
<RadioButton Name="radioSymbolPartLow" GroupName="Part" Content="Low"/>
|
2019-09-27 20:43:58 +00:00
|
|
|
<RadioButton Name="radioSymbolPartHigh" GroupName="Part" Content="H_igh" Margin="8,0,0,0"/>
|
2019-07-11 20:56:16 +00:00
|
|
|
<RadioButton Name="radioSymbolPartBank" GroupName="Part" Content="Bank" Margin="8,0,8,0"/>
|
2019-07-09 00:02:25 +00:00
|
|
|
</StackPanel>
|
|
|
|
</StackPanel>
|
|
|
|
</Grid>
|
|
|
|
</GroupBox>
|
|
|
|
</Grid>
|
|
|
|
|
|
|
|
<TextBlock Text="Bulk Data" Margin="0,12,0,0"/>
|
|
|
|
<Rectangle HorizontalAlignment="Stretch" Fill="LightGray" Height="2"/>
|
2019-07-11 20:56:16 +00:00
|
|
|
<RadioButton Name="radioDenseHex" GroupName="Main" Content="Densely-_packed bytes" Margin="0,4,0,0"
|
2019-12-11 01:41:00 +00:00
|
|
|
Checked="MainGroup_CheckedChanged"/>
|
|
|
|
<StackPanel Orientation="Horizontal" Margin="20,4,0,0">
|
|
|
|
<RadioButton Name="radioDenseHexLimited" GroupName="Main" Content="...with a limit of"
|
|
|
|
Checked="MainGroup_CheckedChanged"/>
|
|
|
|
<TextBox Width="40" Margin="7,-3,0,0" MaxLength="2"
|
|
|
|
Text="{Binding MaxDenseBytesPerLine, UpdateSourceTrigger=PropertyChanged}"/>
|
|
|
|
<TextBlock Text="bytes per line" Margin="7,0,0,0"/>
|
|
|
|
</StackPanel>
|
2019-10-19 03:28:02 +00:00
|
|
|
<RadioButton Name="radioFill" GroupName="Main" Content="Area _filled with value" Margin="0,4,0,0"
|
2019-12-11 01:41:00 +00:00
|
|
|
Checked="MainGroup_CheckedChanged"/>
|
|
|
|
<StackPanel Orientation="Horizontal" Margin="0,4,0,0">
|
|
|
|
<RadioButton Name="radioJunk" GroupName="Main" Content="_Junk bytes, end aligned to"
|
|
|
|
Checked="MainGroup_CheckedChanged"/>
|
|
|
|
<ComboBox Name="junkAlignComboBox" Margin="8,-5,0,0" Width="200"
|
2019-10-19 03:28:02 +00:00
|
|
|
ItemsSource="{Binding JunkAlignmentItems}" DisplayMemberPath="Description"/>
|
|
|
|
</StackPanel>
|
2019-07-09 00:02:25 +00:00
|
|
|
|
|
|
|
<TextBlock Text="String" Margin="0,12,0,0"/>
|
|
|
|
<Rectangle HorizontalAlignment="Stretch" Fill="LightGray" Height="2"/>
|
2019-08-16 00:53:12 +00:00
|
|
|
<StackPanel Orientation="Horizontal">
|
|
|
|
<TextBlock Text="Character encoding:" Margin="0,7,0,0"/>
|
|
|
|
<ComboBox Name="stringEncodingComboBox" Width="150" Margin="8,4,0,4"
|
|
|
|
ItemsSource="{Binding StringEncodingItems}" DisplayMemberPath="Name"
|
|
|
|
SelectionChanged="StringEncodingComboBox_SelectionChanged"/>
|
|
|
|
</StackPanel>
|
2019-07-11 20:56:16 +00:00
|
|
|
<RadioButton Name="radioStringMixed" GroupName="Main" Margin="0,4,0,0"
|
|
|
|
Content="{StaticResource str_StringMixed}"
|
|
|
|
Checked="MainGroup_CheckedChanged"/>
|
|
|
|
<RadioButton Name="radioStringMixedReverse" GroupName="Main" Margin="0,4,0,0"
|
|
|
|
Content="{StaticResource str_StringMixedReverse}"
|
|
|
|
Checked="MainGroup_CheckedChanged"/>
|
|
|
|
<RadioButton Name="radioStringNullTerm" GroupName="Main" Margin="0,4,0,0"
|
|
|
|
Content="{StaticResource str_StringNullTerm}"
|
|
|
|
Checked="MainGroup_CheckedChanged"/>
|
|
|
|
<RadioButton Name="radioStringLen8" GroupName="Main" Margin="0,4,0,0"
|
|
|
|
Content="{StaticResource str_StringLen8}"
|
|
|
|
Checked="MainGroup_CheckedChanged"/>
|
|
|
|
<RadioButton Name="radioStringLen16" GroupName="Main" Margin="0,4,0,0"
|
|
|
|
Content="{StaticResource str_StringLen16}"
|
|
|
|
Checked="MainGroup_CheckedChanged"/>
|
|
|
|
<RadioButton Name="radioStringDci" GroupName="Main" Margin="0,4,0,0"
|
|
|
|
Content="{StaticResource str_StringDci}"
|
|
|
|
Checked="MainGroup_CheckedChanged"/>
|
2019-07-09 00:02:25 +00:00
|
|
|
|
|
|
|
<StackPanel Orientation="Horizontal" HorizontalAlignment="Right" Margin="0,8,0,0">
|
|
|
|
<Button Name="okButton" Content="OK" IsDefault="True" Width="70"
|
|
|
|
IsEnabled="{Binding IsValid}" Click="OkButton_Click"/>
|
|
|
|
<Button Name="cancelButton" Content="Cancel" IsCancel="True"
|
|
|
|
Width="70" Margin="4,0,0,0"/>
|
|
|
|
</StackPanel>
|
|
|
|
</StackPanel>
|
|
|
|
</Window>
|