Flex:HSlider 上的刻度高度不同?
我在 Flex 应用程序中放置了一个 HSlider,其值为 0-10。我希望 0,5 和 10 处的刻度线比其余部分更长,以便除了标签和数据提示之外,它们还可以为用户提供一些关于其所在位置的视觉参考。知道如何做到这一点吗?理想情况下,您可以向tickHeight 参数提供一个数组,但不幸的是它只允许单个数字。这是我的滑块:
<mx:HSlider id="mySlider"
value="5"
styleName="label2"
tickOffset="7"
tickLength="5"
labelOffset="30"
labels="['LO','HI']"
tickInterval="1"
change="broadcastChange(event)"
liveDragging="false"
minimum="0" maximum="10"/>
I've placed an HSlider in my Flex application with values 0-10. I would like the tick marks at 0,5, and 10 to be longer than the rest so that they give the user some visual reference to where they are in addition to the labels and datatip. Any idea how to do this? Ideally you could supply an array to the tickHeight parameter, but unfortunately it only allows a single number. Here's my slider:
<mx:HSlider id="mySlider"
value="5"
styleName="label2"
tickOffset="7"
tickLength="5"
labelOffset="30"
labels="['LO','HI']"
tickInterval="1"
change="broadcastChange(event)"
liveDragging="false"
minimum="0" maximum="10"/>
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
据我所知,唯一的方法是编写自定义轨道皮肤类(并不难)
请在此处查看一些提示:http://forums.adobe.com/message/2486681 #2486681#2486681
As far as I know the only way is to code a custom track skin class (not really hard)
Take a look here for some pointers: http://forums.adobe.com/message/2486681#2486681#2486681