是否可以更改 Wicket 活动指示器的颜色?
情况:我正在使用 Wicket 的 IndicatingAjaxButton
。我在黑色背景的页面上设置了按钮。当用户按下按钮时,按钮的活动指示灯会熄灭并旋转,直到系统准备好继续前进。
问题:由于黑色背景,指示器看起来很糟糕。由于指示器的一部分以黑色动画,因此使用黑色背景上的指示器会丢失一些细节。
问题:Wicket 中是否可以更改 IndicatingX
[按钮、链接等] 的颜色,或者我是否必须以新的方式设计我的页面?
Situation: I'm working with Wicket's IndicatingAjaxButton
. I have the button set up on a page with black background. When the user pushes the button, the button's activity indicator goes off and spins until the system is ready to move on.
Problem: Because of the black background, the indicator looks bad. Since part of the indicator is animated in black, some of the details are lost using the indicator on a black background.
Question: Is it possible in Wicket to change the color of the IndicatingX
[Button, Link, etc.], or do I have to design my page in a new way?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
因此,利用 Lord Torgamus 提供的内容,您可以添加一个这样的类:
并将其用于您的任何页面。
So piggybacking off what Lord Torgamus provided, you could add a class like this:
and use that for any of your pages.
这是不可能的。嗯,不是以编程方式。
Wicket 的活动指示器/颤动器/旋转器实际上只不过是一个动画 GIF。它位于
和 在
AbstractDefaultAjaxBehavior
中引用。要更改颜色,您可以创建自己的相同大小的动画 GIF,并覆盖默认发行版中包含的 GIF。
编辑:
好吧,写完后我想“一定有免费的图标可用”,并通过 Google 图片搜索想到了这一点:
http://blogs.msdn.com/blogfiles/gduthie/WindowsLiveWriter/Needanimatedloadingicon_B811/ajax-loader_2.gif
我认为它是免费且无限制使用的,但是我没有检查太仔细。如果您将其用于个人玩具/示例应用程序之外的其他用途,您应该自行检查。
This is not possible. Well, not programmatically.
Wicket's activity indicator/throbber/spinner is actually nothing more than an animated GIF. It's located at
and referenced in
AbstractDefaultAjaxBehavior
.To change the colors, you could create your own animated GIF of the same size and overwrite the one that's included in the default distribution.
EDIT:
Okay, after writing that I thought "there must be free icons available" and came up with this through Google Image Search:
http://blogs.msdn.com/blogfiles/gduthie/WindowsLiveWriter/Needananimatedloadingicon_B811/ajax-loader_2.gif
I think it's free and unrestricted to use, but I didn't check too carefully. You should check for yourself if you're using it for anything more than a personal toy/sample app.