From ab755f1bc1584715ceb2994985ed09dde3a508c3 Mon Sep 17 00:00:00 2001 From: Andy McFadden Date: Tue, 17 Sep 2019 22:14:10 -0700 Subject: [PATCH] Tweak HTML output Changed the HTML template to make the SourceGen version visible, and added the expression style. --- SourceGen/Exporter.cs | 7 ++++++- SourceGen/RuntimeData/ExportTemplate.html | 8 ++++++-- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/SourceGen/Exporter.cs b/SourceGen/Exporter.cs index 6203b47..12a33d2 100644 --- a/SourceGen/Exporter.cs +++ b/SourceGen/Exporter.cs @@ -366,6 +366,11 @@ namespace SourceGen { // Perform some quick substitutions. tmplStr = tmplStr.Replace("$ProjectName$", mProject.DataFileName); tmplStr = tmplStr.Replace("$AppVersion$", App.ProgramVersion.ToString()); + string expModeStr = ((Formatter.FormatConfig.ExpressionMode) + AppSettings.Global.GetEnum(AppSettings.FMT_EXPRESSION_MODE, + typeof(Formatter.FormatConfig.ExpressionMode), + (int)Formatter.FormatConfig.ExpressionMode.Unknown)).ToString(); + tmplStr = tmplStr.Replace("$ExpressionStyle$", expModeStr); // Generate and substitute the symbol table. This should be small enough that // we won't break the world by doing it with string.Replace(). @@ -693,7 +698,7 @@ namespace SourceGen { sb.Append(" "); sb.Append("" + sym.Label + ""); - sb.Append("" + mFormatter.FormatHexValue(sym.Value, 2) + ""); + sb.Append("" + mFormatter.FormatHexValue(sym.Value, 2) + ""); sb.Append("\r\n"); count++; } diff --git a/SourceGen/RuntimeData/ExportTemplate.html b/SourceGen/RuntimeData/ExportTemplate.html index 9b52098..3d0ac38 100644 --- a/SourceGen/RuntimeData/ExportTemplate.html +++ b/SourceGen/RuntimeData/ExportTemplate.html @@ -25,7 +25,11 @@ $CodeLines$

Symbol Table

$SymbolTable$ - - + +