Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Font icon's "MirroredWhenRightToLeft" property is not working in Run time changes. #7661

Closed
1 of 2 tasks
sethuramkumar opened this issue Aug 29, 2022 · 1 comment
Closed
1 of 2 tasks
Labels
bug Something isn't working product-winui3 WinUI 3 issues team-Controls Issue for the Controls team
Milestone

Comments

@sethuramkumar
Copy link

Describe the bug

Hi Team,

when changing the flow direction in run time, with MirroredWhenRightToLeft property of font icon as true, font icon is not mirrored, not updated properly.
"MirroredWhenRightToLeft property works fine on initial loading alone.

<Grid Width="800" Height="200" BorderBrush="RoyalBlue" BorderThickness="3">
    <Grid.Resources>
        <Style TargetType="StackPanel">
            <Setter Property="HorizontalAlignment" Value="Center"/>
            <Setter Property="VerticalAlignment" Value="Center"/>
        </Style>
    </Grid.Resources>
    <Grid.ColumnDefinitions>
        <ColumnDefinition Width="*"/>
        <ColumnDefinition Width="*"/>
        <ColumnDefinition Width="*"/>
    </Grid.ColumnDefinitions>
    <StackPanel Orientation="Vertical" FlowDirection="RightToLeft"   >
        <TextBlock Text="Right To Left - On Inital loading"/>
        <FontIcon Glyph="&#xE76C;"  Foreground="Black" FontSize="30" MirroredWhenRightToLeft="True" />
    </StackPanel>
    <StackPanel Orientation="Vertical" Grid.Column="1" x:Name="panel" >
        <TextBlock x:Name="textBlock" Text="Right To Left - Run time changing"/>
        <FontIcon Glyph="&#xE76C;" Foreground="Black" FontSize="30" MirroredWhenRightToLeft="True" />
    </StackPanel>
    <Button x:Name="myButton" Grid.Column="2" Click="myButton_Click">Change Flow Direction</Button>
</Grid>

Code Behind:

private void myButton_Click(object sender, RoutedEventArgs e)
{
    textBlock.Text = "Right To Left- Changed in Run time";
    panel.FlowDirection = FlowDirection.RightToLeft;
}

Steps to reproduce the bug

1.Provide font icon within a grid/stacklayout with MirroredWhenRightToLeft as true.
2,Modify the flow direction in run time.
3.Note icon is not mirrored.

Expected behavior

Icon should be mirrored based on the flow direction when the flow direction is changed at run time.

Screenshots

Before Changing the flow direction:

image

After Changing the flow direction :

image

NuGet package version

WinUI 3 - Windows App SDK 1.1.4

Windows app type

  • UWP
  • Win32

Device form factor

Desktop

Windows version

Windows 11 (21H2): Build 22000

Additional context

No response

@sethuramkumar sethuramkumar added the bug Something isn't working label Aug 29, 2022
@ghost ghost added the needs-triage Issue needs to be triaged by the area owners label Aug 29, 2022
@bpulliam bpulliam added the product-winui3 WinUI 3 issues label Oct 12, 2022
@bpulliam bpulliam added the team-Controls Issue for the Controls team label Oct 30, 2022
@bpulliam bpulliam removed the needs-triage Issue needs to be triaged by the area owners label Dec 7, 2022
@codendone codendone added the fixed-internally This bug has been fixed, and the fix will be shipped in the next version of WinUI 3. label Jun 15, 2023
@bpulliam bpulliam added this to the WinUI 3 in WinAppSDK 1.4 milestone Jul 7, 2023
@ghost1372
Copy link
Contributor

fixed in 1.3.3

@bpulliam bpulliam removed the fixed-internally This bug has been fixed, and the fix will be shipped in the next version of WinUI 3. label Feb 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working product-winui3 WinUI 3 issues team-Controls Issue for the Controls team
Projects
None yet
Development

No branches or pull requests

4 participants