From af95e635568c854ecad67bd82e1aea3f5a169859 Mon Sep 17 00:00:00 2001 From: Erik Darling <2136037+erikdarlingdata@users.noreply.github.com> Date: Tue, 24 Feb 2026 22:29:49 -0500 Subject: [PATCH] Issue #269: Make plan viewer properties copyable Switch property values from TextBlock to TextBox (IsReadOnly) so users can select text and Ctrl+C to copy. The TextBox's built-in context menu (Copy, Select All) also prevents the parent TabItem's alert context menu from appearing when right-clicking in the properties panel. Co-Authored-By: Claude Opus 4.6 --- .github/workflows/build.yml | 2 +- Dashboard/Controls/PlanViewerControl.xaml.cs | 15 ++++++++++----- 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index d33ee270..ec655ade 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -69,7 +69,7 @@ jobs: New-Item -ItemType Directory -Force -Path "$instDir/upgrades" Copy-Item 'Installer/bin/Release/net8.0/win-x64/publish/PerformanceMonitorInstaller.exe' $instDir - Copy-Item 'InstallerGui/bin/Release/net8.0-windows/win-x64/publish/InstallerGui.exe' $instDir -ErrorAction SilentlyContinue + Copy-Item 'InstallerGui/bin/Release/net8.0-windows/win-x64/publish/PerformanceMonitorInstallerGui.exe' $instDir -ErrorAction SilentlyContinue Copy-Item 'install/*.sql' "$instDir/install/" if (Test-Path 'upgrades') { Copy-Item 'upgrades/*' "$instDir/upgrades/" -Recurse -ErrorAction SilentlyContinue } if (Test-Path 'README.md') { Copy-Item 'README.md' $instDir } diff --git a/Dashboard/Controls/PlanViewerControl.xaml.cs b/Dashboard/Controls/PlanViewerControl.xaml.cs index 69a78c00..4e1f6e72 100644 --- a/Dashboard/Controls/PlanViewerControl.xaml.cs +++ b/Dashboard/Controls/PlanViewerControl.xaml.cs @@ -1115,16 +1115,21 @@ private void AddPropertyRow(string label, string value, bool isCode = false) Grid.SetColumn(labelBlock, 0); grid.Children.Add(labelBlock); - var valueBlock = new TextBlock + var valueBox = new TextBox { Text = value, FontSize = 11, Foreground = TooltipFgBrush, - TextWrapping = TextWrapping.Wrap + TextWrapping = TextWrapping.Wrap, + IsReadOnly = true, + BorderThickness = new Thickness(0), + Background = Brushes.Transparent, + Padding = new Thickness(0), + VerticalAlignment = VerticalAlignment.Top }; - if (isCode) valueBlock.FontFamily = new FontFamily("Consolas"); - Grid.SetColumn(valueBlock, 1); - grid.Children.Add(valueBlock); + if (isCode) valueBox.FontFamily = new FontFamily("Consolas"); + Grid.SetColumn(valueBox, 1); + grid.Children.Add(valueBox); var target = _currentPropertySection ?? PropertiesContent; target.Children.Add(grid);