Skip to content

Problems centering Image inside in a SettingsCard #459

Answered by mikeclayton
mikeclayton asked this question in Q&A
Discussion options

You must be logged in to vote

I managed to put a workaround together - it's not pretty but it works.

The first part was to wrap the image in a Grid and StackPanel to allow it to centre property inside the "content" area of the SettingsCard:

<UserControl
    ... snip ...
    xmlns:tkcontrols="using:CommunityToolkit.WinUI.Controls"
    >

    <controls:SettingsGroup>

        <tkcontrols:SettingsExpander
            x:Uid="MouseUtils_MouseJump_Appearance"
            HeaderIcon="{ui:FontIcon Glyph=&#xEB3C;}"
            IsEnabled="{x:Bind ViewModel.IsMouseJumpEnabled, Mode=OneWay}"
            IsExpanded="False">
            <tkcontrols:SettingsExpander.Items>

                <tkcontrols:SettingsCard
                    x

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by mikeclayton
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant