开发者

Cufon: Underline Text

How can I underl开发者_运维问答ine a text replaced with Cufon?


text-decoration is not supported by Cufon:
https://github.com/sorccu/cufon/wiki/known-bugs-and-issues

Perhaps you could add a border-bottom property to the element using normal CSS?


Cufon adds a class to the elements it creates that you can style (useful if your containing element has pads/margins). So for a link, just use this:

a .cufon {border-bottom: solid 1px #000000}
a:hover .cufon {border-bottom: none}

To keep your elements from shifting up/down, either add a border to the non hover state, or adjust the heights of both elements accordingly...


Be aware though. Adding a border bottom to a cufon class is quite ugly.

I'd be best to avoid underlines to these fonts in your design. It might look nice in Photoshop, but don't show this to you customers. It doesn't work out that well in HTML/CSS.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜