1
0
mirror of https://github.com/fadden/6502bench.git synced 2024-09-17 14:54:50 +00:00
6502bench/SourceGenWPF/AsmGen/WpfGui/GenAndAsm.xaml
Andy McFadden 99b484df4c Implement long-comment editing
We can now Edit Long Comment and Edit Header Comment.

Changing the number of lines in a long comment exposed a bug in the
display list update.  Fixed.

Running the WinForms version trashed the column widths, which exposed
the fact that the default column widths were set too narrow.  Fixed.

On an unrelated note, hitting undo/redo quickly will sometimes leave
you scrolled to the bottom of the code list.  Some sort of command-
handling race in the WPF framework?  (Not fixed.)
2019-07-07 16:18:46 -07:00

109 lines
5.1 KiB
XML

<!--
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.
-->
<Window x:Class="SourceGenWPF.AsmGen.WpfGui.GenAndAsm"
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:local="clr-namespace:SourceGenWPF.AsmGen.WpfGui"
mc:Ignorable="d"
Title="Generate and Assemble"
Width="800" Height="700" MinWidth="600" MinHeight="600" ResizeMode="CanResizeWithGrip"
ShowInTaskbar="False" WindowStartupLocation="CenterOwner"
Loaded="Window_Loaded">
<Grid Margin="8">
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="2*" MinHeight="150"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="*" MinHeight="100"/>
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
<Grid Grid.Row="0">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="12"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="20"/>
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
<TextBlock Grid.Column="0" Grid.Row="0" Margin="0,3,8,0">Assembler:</TextBlock>
<StackPanel Grid.Column="1" Grid.Row="0" Orientation="Horizontal">
<ComboBox Name="assemblerComboBox" Width="150" IsReadOnly="True"
SelectionChanged="AssemblerComboBox_SelectionChanged">
<ComboBox.Items>
<ComboBoxItem>ONE</ComboBoxItem>
<ComboBoxItem>TWO</ComboBoxItem>
</ComboBox.Items>
</ComboBox>
<Button Name="assemblerSettingsButton" Width="75" Margin="8,0,0,0"
Content="Settings" Click="AssemblerSettingsButton_Click"/>
</StackPanel>
<Button Grid.Column="3" Grid.Row="0" Name="generateButton" Width="100"
HorizontalAlignment="Left" FontWeight="Bold" Content="Generate" Click="GenerateButton_Click"/>
<TextBlock Grid.Column="0" Grid.Row="2" Margin="0,3,8,0">Preview file:</TextBlock>
<StackPanel Grid.Column="1" Grid.Row="2" HorizontalAlignment="Left">
<ComboBox Name="previewFileComboBox" Width="260" IsReadOnly="True"
SelectionChanged="PreviewFileComboBox_SelectionChanged">
<ComboBox.Items>
<ComboBoxItem>ONE</ComboBoxItem>
<ComboBoxItem>TWO</ComboBoxItem>
</ComboBox.Items>
</ComboBox>
</StackPanel>
<DockPanel Grid.Column="3" Grid.Row="2">
<TextBlock DockPanel.Dock="Left" Margin="0,1,0,0">Work directory:</TextBlock>
<TextBox DockPanel.Dock="Right" Name="workDirectoryTextBox" Margin="8,0,0,0"
Text="C:\this\that\theother"/>
</DockPanel>
</Grid>
<TextBox Grid.Row="1" Name="previewTextBox" IsReadOnly="True" Margin="0,4,0,0"
FontFamily="{StaticResource GeneralMonoFont}" VerticalScrollBarVisibility="Auto">
sample text1
</TextBox>
<GridSplitter Grid.Row="2" HorizontalAlignment="Stretch" VerticalAlignment="Center"
Height="4" Margin="-4,4"/>
<DockPanel Grid.Row="3">
<DockPanel DockPanel.Dock="Top" LastChildFill="False">
<Button DockPanel.Dock="Left" Name="runAssemblerButton" Width="120"
FontWeight="Bold" Content="Run Assembler" Click="RunAssemblerButton_Click"/>
<TextBlock Name="asmNotConfiguredText" DockPanel.Dock="Left" Margin="16,0,0,0"
Foreground="Red">Assembler not configured</TextBlock>
</DockPanel>
<TextBox DockPanel.Dock="Top" Name="cmdOutputTextBox" IsReadOnly="True" Margin="0,4,0,0"
FontFamily="{StaticResource GeneralMonoFont}" VerticalScrollBarVisibility="Auto">
sample text2
</TextBox>
</DockPanel>
<StackPanel Grid.Row="4" HorizontalAlignment="Right" Margin="0,4">
<Button Width="70" IsCancel="True">Close</Button>
</StackPanel>
</Grid>
</Window>