Verfin
Topic Author
Posts: 7
Joined: 07 Jun 2016, 11:46

ProgressBar Orientation doesn't work?

27 Jun 2016, 15:39

From the samples folder, I changed the
<ProgressBar Grid.Column="1" Width="150" Height="18" Value="50">
into
<ProgressBar Orientation="Vertical" Grid.Column="1" Width="150" Height="18" Value="50">
and tried the file in the xaml player, but nothing changes. The progress bar still progresses from right to left.

Is this bug, or am I once again missing something?
 
User avatar
sfernandez
Site Admin
Posts: 2984
Joined: 22 Dec 2011, 19:20

Re: ProgressBar Orientation doesn't work?

28 Jun 2016, 18:00

Hi,

If you are using the default ProgressBar style provided by Noesis, I'm afraid to say that its template is not yet prepared to show in Vertical Orientation. We will improve this in a future release though.

Meanwhile you can write your own ProgressBar template as follows to support vertical orientation:
<ControlTemplate TargetType="{x:Type ProgressBar}">
    <Grid x:Name="TemplateRoot" MinHeight="{TemplateBinding MinHeight}">
        <Border x:Name="PART_Track"
            Background="{TemplateBinding Background}" 
            BorderBrush="{TemplateBinding BorderBrush}"
            BorderThickness="{TemplateBinding BorderThickness}"
            CornerRadius="1"/>
        <Grid x:Name="PART_Indicator"
            HorizontalAlignment="Left">
            <Border x:Name="IndicatorBorder"
                Margin="{TemplateBinding Padding}"
                Background="{TemplateBinding Foreground}"/>
        </Grid>
    </Grid>
    <ControlTemplate.Triggers>
        <Trigger Property="Orientation" Value="Vertical">
            <Setter Property="LayoutTransform" TargetName="TemplateRoot">
                <Setter.Value>
                    <RotateTransform Angle="-90"/>
                </Setter.Value>
            </Setter>
        </Trigger>
    </ControlTemplate.Triggers>
</ControlTemplate>
 
Verfin
Topic Author
Posts: 7
Joined: 07 Jun 2016, 11:46

Re: ProgressBar Orientation doesn't work?

30 Jun 2016, 09:05

No biggie. Just posted to let you know.
 
User avatar
sfernandez
Site Admin
Posts: 2984
Joined: 22 Dec 2011, 19:20

Re: ProgressBar Orientation doesn't work?

30 Jun 2016, 21:06

Have you been able to make it work with a template like this?
 
XaeroDegreaz
Posts: 29
Joined: 26 Nov 2013, 04:47

Re: ProgressBar Orientation doesn't work?

12 Dec 2017, 21:21

Have there been any updates on this? I'd also like to use vertical orientated ProgressBars.
 
User avatar
sfernandez
Site Admin
Posts: 2984
Joined: 22 Dec 2011, 19:20

Re: ProgressBar Orientation doesn't work?

14 Dec 2017, 11:27

Vertical orientation progress bar template is not included in our defualt style, but you only have to define a ProgressBar template as explained here: viewtopic.php?f=3&t=933#p5076, and then you can set it in your progress bar:
<ProgressBar Template="{StaticResource VerticalProgressBar}" Orientation="Vertical"/>
In future versions we will continue improving our defualt styles to include this.

Who is online

Users browsing this forum: No registered users and 100 guests