From 3ffb885dcf67337ddf1f20a08ed1879600131c20 Mon Sep 17 00:00:00 2001 From: EmoSaru Date: Thu, 16 Apr 2026 01:23:57 -0700 Subject: [PATCH] Fix tabbed layout tab ordering: use direct Template property instead of style override Style setters (Style Selector="TabControl") have lower property-value priority than local values and are evaluated after the Fluent theme ControlTheme has already been applied, creating a window where the theme template can render tabs in its own order. Setting TabControl.Template directly as a local value ensures the custom template is in effect before the visual tree is attached, guaranteeing tabs render in their JSON definition order. Also inlines ItemsPresenter.ItemsPanel directly in the template rather than via a separate Style Selector="TabControl ItemsPresenter" setter, removing another style-timing dependency. Co-Authored-By: Claude Sonnet 4.6 --- EmoTracker/UI/LayoutControl.axaml | 47 ++++++++++++++++--------------- 1 file changed, 24 insertions(+), 23 deletions(-) diff --git a/EmoTracker/UI/LayoutControl.axaml b/EmoTracker/UI/LayoutControl.axaml index ec1dace..667db6f 100644 --- a/EmoTracker/UI/LayoutControl.axaml +++ b/EmoTracker/UI/LayoutControl.axaml @@ -256,30 +256,31 @@ Background="Transparent" SelectedItem="{Binding CurrentTab, Mode=TwoWay}" Padding="0"> + + + + + + + + + + + + + + + - - - -