Background: anchor logo to bottom-right, never overlap the footer

Two related issues with the background bitmap:

1. The footer (download progress bar) appeared on top of the image,
   cropping the bottom strip — including the ASTERION VR mark in the
   bottom-right corner of Background.png.

2. UniformToFill scales-and-crops to maintain aspect ratio, but with
   the previous setup the crop was centered, so resizing the window
   wider/narrower silently pushed the bottom-right logo off-screen.

Fix:
- The bitmap now lives in a Rectangle restricted to Grid.Row="1"
  (body only). When the footer appears at Row 2, it sits below the
  body without overlapping the image.
- Switch from <Image Stretch="UniformToFill"> to
  <Rectangle><Fill><ImageBrush AlignmentX="Right" AlignmentY="Bottom"
  Stretch="UniformToFill" /></Fill></Rectangle>. The crop now
  happens on the LEFT and TOP edges, keeping the logo's corner pinned
  to the bottom-right and visible regardless of window proportions.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-05-02 11:54:20 +02:00
parent c27066ffe4
commit 661c464b7a

View File

@@ -166,15 +166,20 @@
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<!-- Background image (sous tout le reste, ne capte pas la souris).
Le fond noir du Grid garantit que les zones transparentes de l'image
(et l'image dans son ensemble à faible opacity) reposent sur du noir
pur, sans héritage du brush système. -->
<Image Grid.Row="0" Grid.RowSpan="3"
Source="pack://application:,,,/Resources/Background.png"
Stretch="UniformToFill"
Opacity="0.25"
IsHitTestVisible="False" />
<!-- Background image : limité au body uniquement (Grid.Row="1") pour ne pas
se faire chevaucher par le footer quand un download tourne. ImageBrush
avec AlignmentX=Right + AlignmentY=Bottom : si le ratio fenêtre force
un crop, on rogne en haut/à gauche — le logo ASTERION VR en bas-droite
reste TOUJOURS visible. -->
<Rectangle Grid.Row="1" IsHitTestVisible="False">
<Rectangle.Fill>
<ImageBrush ImageSource="pack://application:,,,/Resources/Background.png"
Stretch="UniformToFill"
AlignmentX="Right"
AlignmentY="Bottom"
Opacity="0.25" />
</Rectangle.Fill>
</Rectangle>
<!-- Top bar : 3 colonnes (brand / license center / chrome) -->
<Border Grid.Row="0" Background="{StaticResource Brush.Bg.Sidebar}"