From 2c8370fa925bd96c8b9aff738b56c6a9ff3ab9e0 Mon Sep 17 00:00:00 2001 From: leo Date: Thu, 8 May 2025 13:39:27 +0800 Subject: [PATCH] refactor: get graph clip width from grid column definition directly Signed-off-by: leo --- src/Views/CommitGraph.cs | 2 +- src/Views/Histories.axaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Views/CommitGraph.cs b/src/Views/CommitGraph.cs index faf883c6..c5baa0ae 100644 --- a/src/Views/CommitGraph.cs +++ b/src/Views/CommitGraph.cs @@ -56,7 +56,7 @@ namespace SourceGit.Views return; // Calculate drawing area. - var width = Bounds.Width - 273 - histories.AuthorNameColumnWidth.Value; + var width = histories.CommitListHeader.ColumnDefinitions[0].ActualWidth; var height = Bounds.Height; // Calculate row height diff --git a/src/Views/Histories.axaml b/src/Views/Histories.axaml index 2a7b39f5..c9a8ba5e 100644 --- a/src/Views/Histories.axaml +++ b/src/Views/Histories.axaml @@ -30,7 +30,7 @@ Background="{DynamicResource Brush.Window}" BorderThickness="0,0,0,1" BorderBrush="{DynamicResource Brush.Border0}"> - +