如何制作垂直进度条? [英] How to make a vertical progress bar?

查看:32
本文介绍了如何制作垂直进度条?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试创建一个垂直而不是水平的 ProgressBar,我已经尝试更改 ProgressBar 的角度,使其成为垂直而不是水平的,继承人我的代码:

I'm trying to create a ProgressBar that is vertical rather than horizontal, I've tried changing the angle of the ProgressBar so it's vertical rather than horizontal, heres my code:

<ProgressBar Maximum="100" Value="20" Height="30" Width="5" >
   <ProgressBar.Background>
       <SolidColorBrush Color="White" Opacity="0.15999999642372131"/>
   </ProgressBar.Background>
   <ProgressBar.RenderTransform>
       <RotateTransform Angle="0" CenterX="0" CenterY="0"/>
   </ProgressBar.RenderTransform>
</ProgressBar>

然而,进度条本身是从一侧到另一侧而不是从上到下.我试过改变 FlowDirection 但这只给你 LeftToRightRightToLeft

However, the progress bar itself is from side to side rather than top to bottom. I've tried changing the FlowDirection but that only gives you the 2 options of LeftToRight or RightToLeft

有人有任何想法/建议吗?

Does anyone have any ideas/suggestions?

推荐答案

您可能正在寻找 ProgressBar.Orientation 属性

获取或设置 ProgressBar 的方向:水平或垂直.

Gets or sets the orientation of a ProgressBar: horizontal or vertical.

这篇关于如何制作垂直进度条?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆