View Issue Details

IDProjectCategoryView StatusLast Update
0002497NoesisGUIC++ SDKpublic2023-02-02 17:17
Reportersckriel Assigned Tosfernandez  
PrioritynormalSeverityminorReproducibilityalways
Status feedbackResolutionopen 
Product Version3.1.5 
Summary0002497: Flow Direction layout incorrect
DescriptionWe’ve noticed something strange about how Noesis implements the Flow Direction property. This occurs if you are setting flow direction on a panel and on its children.

If the Flow Direction properties are set during initialization, the behaviour is correct. However, if the Flow Direction is changed afterwards, the result is not correct. Instead of repeating the layout algorithm, the content of the panel is simply flipped horizontally.

A XAML file illustrating the problem is attached. The combo box changes the flow direction of the third line. When this is changed to RightToLeft, I expect the third line to match the second line. Instead, it is simply flipped horizontally.
Steps To Reproduce1. Load the attached XAML file.
2. Change the combo box to "RightToLeft"
TagsNo tags attached.
PlatformWindows

Activities

sckriel

sckriel

2023-01-30 08:56

reporter  

FlowDirectionBug.xaml (1,638 bytes)   
<Grid
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    xmlns:sys="clr-namespace:System"
    Background="Transparent">

    <StackPanel Margin="20" Width="200">
        <Border Height="50">
			<StackPanel FlowDirection="LeftToRight" Orientation="Horizontal">
				<TextBlock Text="First"  FlowDirection="LeftToRight"/>
				<TextBlock Text="Second" FlowDirection="LeftToRight"/>
				<TextBlock Text="Third"  FlowDirection="LeftToRight"/>
			</StackPanel>	
        </Border>

        <Border Height="50">
			<StackPanel FlowDirection="RightToLeft" Orientation="Horizontal">
				<TextBlock Text="First"  FlowDirection="LeftToRight"/>
				<TextBlock Text="Second" FlowDirection="LeftToRight"/>
				<TextBlock Text="Third"  FlowDirection="LeftToRight"/>
			</StackPanel>			
        </Border>
		
        <Border Height="50" >
			<StackPanel FlowDirection="{Binding SelectedItem, ElementName=FlowDirection1}" Orientation="Horizontal">
				<TextBlock Text="First"  FlowDirection="LeftToRight"/>
				<TextBlock Text="Second" FlowDirection="LeftToRight"/>
				<TextBlock Text="Third"  FlowDirection="LeftToRight"/>
			</StackPanel>						
        </Border>		

        <TextBlock Text="Flow Direction:"/>
		
        <ComboBox 
			x:Name="FlowDirection1"
            SelectedIndex="0">
            <sys:string>LeftToRight</sys:string>
            <sys:string>RightToLeft</sys:string>
        </ComboBox>
    </StackPanel>
</Grid>
FlowDirectionBug.xaml (1,638 bytes)   
after.png (9,953 bytes)   
after.png (9,953 bytes)   
before.png (9,940 bytes)   
before.png (9,940 bytes)   
sfernandez

sfernandez

2023-01-30 10:48

manager   ~0008250

Hi Steven,

FlowDirection is not supported in 3.1. We implemented full support for FlowDirection and RTL languages (like arabic) in 3.2 version.
Can I ask what are you trying to accomplish by using the FlowDirection property? maybe if it is something simple it can be achieved in a different way without upgrading to 3.2 version yet.
sfernandez

sfernandez

2023-02-02 17:17

manager   ~0008255

Ok, thanks for the explanation, should we close this issue then?

Issue History

Date Modified Username Field Change
2023-01-30 08:56 sckriel New Issue
2023-01-30 08:56 sckriel File Added: FlowDirectionBug.xaml
2023-01-30 08:56 sckriel File Added: after.png
2023-01-30 08:56 sckriel File Added: before.png
2023-01-30 10:48 sfernandez Assigned To => sfernandez
2023-01-30 10:48 sfernandez Status new => feedback
2023-01-30 10:48 sfernandez Note Added: 0008250
2023-02-02 12:05 sckriel Status feedback => assigned
2023-02-02 17:17 sfernandez Status assigned => feedback
2023-02-02 17:17 sfernandez Note Added: 0008255