Skip to content

Fix Wi-Fi/Bluetooth toggle shifting on L2 pages#116

Open
Luckman-Khan wants to merge 1 commit into
ramensoftware:mainfrom
Luckman-Khan:fix/l2-toggle-alignment
Open

Fix Wi-Fi/Bluetooth toggle shifting on L2 pages#116
Luckman-Khan wants to merge 1 commit into
ramensoftware:mainfrom
Luckman-Khan:fix/l2-toggle-alignment

Conversation

@Luckman-Khan

Copy link
Copy Markdown

Added HorizontalAlignment=Stretch to ContentPresenter#PageHeader to ensure the header always takes full width, keeping the on/off toggle pinned to the right edge consistently.
Screenshot 2026-06-13 181357

@m417z

m417z commented Jun 13, 2026

Copy link
Copy Markdown
Member

@TheGamer1445891 please take a look.

@TheGamer1445891

Copy link
Copy Markdown
Contributor

@TheGamer1445891 please take a look.

i plan to rework (re-do) the entire theme to fix all the bugs and make the theme look more native.

@TheGamer1445891

Copy link
Copy Markdown
Contributor

@Luckman-Khan i have added this fix in my re-builded theme, so please wait for the new update (if i could finish it)

@TheGamer1445891

Copy link
Copy Markdown
Contributor

turns out this doesnt do anything (the header's switch buttons will still be mis-aligned for some reason)

Constrain PageHeaderContentControl on BetterControl11 L2 pages so Wi-Fi and Bluetooth header switches stay aligned at the trailing edge.

The previous PageHeader HorizontalAlignment change did not affect the header content width, so replace it with the narrower header content target.
@Luckman-Khan Luckman-Khan force-pushed the fix/l2-toggle-alignment branch from 5439fd2 to ad755b8 Compare June 19, 2026 10:27
@Luckman-Khan

Copy link
Copy Markdown
Author

Updated the PR with a different fix.

The previous HorizontalAlignment=Stretch rule on ContentPresenter#PageHeader did not actually constrain the header content, so I replaced it with ContentControl#PageHeaderContentControl Width=64. I tested this locally in Windhawk textual mode, and it keeps the Wi-Fi/Bluetooth L2 page toggle aligned to the right edge.

@TheGamer1445891

Copy link
Copy Markdown
Contributor

Updated the PR with a different fix.

The previous HorizontalAlignment=Stretch rule on ContentPresenter#PageHeader did not actually constrain the header content, so I replaced it with ContentControl#PageHeaderContentControl Width=64. I tested this locally in Windhawk textual mode, and it keeps the Wi-Fi/Bluetooth L2 page toggle aligned to the right edge.

@Luckman-Khan i tested it and turns out it still doesnt do anything and still makes the control center header switch button misaligned.
make sure to restart ShellHost.exe when applying this to see if works or not (since i tested it by restarting shellhost and it looks like it doesnt work/still misaligned).

@Luckman-Khan

Copy link
Copy Markdown
Author

I retested with ShellHost.exe restarted and confirmed a before/after on my setup: removing Width=64 makes the L2 toggle shift inward, adding it back moves it to the far right.

Could this be a Windows build / visual tree difference? To verify whether the selector applies on your setup, can you try temporarily adding Background:=Red to ContentControl#PageHeaderContentControl? If it does not show, then this selector is not matching your ShellHost tree and we need a more specific/different target.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants