From 0ab76ea1f71c1fd577fba4270987653bcab95322 Mon Sep 17 00:00:00 2001 From: Andy McFadden Date: Tue, 18 Feb 2020 13:25:20 -0800 Subject: [PATCH] Improve CPU instruction chart Added "show undocumented opcodes" checkbox, so you can choose whether or not to see them at all. (Issue #60) Added formatter call for the instruction mnemonics so they get capitalized when the app is configured for upper-case opcodes. (Issue #59) Fix a bug where the instruction chart and ASCII chart were writing their modes to the same setting, stomping each other. Also, pluralized a button in the file concatenator. --- SourceGen/AppSettings.cs | 4 ++++ SourceGen/RuntimeData/Help/tools.html | 5 +++-- SourceGen/Tools/WpfGui/FileConcatenator.xaml | 2 +- SourceGen/Tools/WpfGui/InstructionChart.xaml | 8 +++++-- .../Tools/WpfGui/InstructionChart.xaml.cs | 21 +++++++++++++++---- 5 files changed, 31 insertions(+), 9 deletions(-) diff --git a/SourceGen/AppSettings.cs b/SourceGen/AppSettings.cs index 62abcd5..8ddbefc 100644 --- a/SourceGen/AppSettings.cs +++ b/SourceGen/AppSettings.cs @@ -111,6 +111,10 @@ namespace SourceGen { // ASCII chart viewer settings. public const string ASCCH_MODE = "ascch-mode1"; + // Instruction chart settings. + public const string INSTCH_MODE = "instch-mode"; + public const string INSTCH_SHOW_UNDOC = "instch-show-undoc"; + // Source generation settings. public const string SRCGEN_DEFAULT_ASM = "srcgen-default-asm"; public const string SRCGEN_ADD_IDENT_COMMENT = "srcgen-add-ident-comment"; diff --git a/SourceGen/RuntimeData/Help/tools.html b/SourceGen/RuntimeData/Help/tools.html index 9b909fc..99ca3fa 100644 --- a/SourceGen/RuntimeData/Help/tools.html +++ b/SourceGen/RuntimeData/Help/tools.html @@ -14,8 +14,9 @@

Instruction Chart

This opens a window with a summary of all 256 opcodes. The CPU can -be chosen from the pop-up list at the bottom. Undocumented opcodes are -shown in italics.

+be chosen from the pop-up list at the bottom. Undocumented opcodes for +6502/65C02 are shown in italics, and can be excluded from the list +by unchecking the box at the bottom.

The status flags affected by each instruction reflect their behavior on the 65816. The only significant difference between 65816 and 6502/65C02 is the way the BRK instruction affects the D and B/X flags.

diff --git a/SourceGen/Tools/WpfGui/FileConcatenator.xaml b/SourceGen/Tools/WpfGui/FileConcatenator.xaml index 57b88be..f4a856f 100644 --- a/SourceGen/Tools/WpfGui/FileConcatenator.xaml +++ b/SourceGen/Tools/WpfGui/FileConcatenator.xaml @@ -81,7 +81,7 @@ limitations under the License. -