开发者

How do I dynamically adjust size to fit text?

I am using Rails3 + jQuery to build an app using Facebox.

In the facebox, the title text is too big to fit in a single line, so it is being spr开发者_StackOverflow社区ead into two lines. It looks ugly, so I was wondering whether there was a way to either:

  1. Adjust the size of the title dynamically to fit the facebox width.
  2. Dynamically adjust the facebox width to fit the title text on a single line.


I think this answer fits your needs: Calculating text width

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜