1

If I have a long text inside a div that wraps into several lines, can I make the div not cut a line vertically on vertical overflow? Can I make my div have height expressed in number of lines, or some other way to make it fit integral number of lines?

EDIT: My text does not vertically fit into my div. But I want the div to show just integral number of lines.

here is jsfiddle: http://jsfiddle.net/A9VAe/1/

akonsu
  • 28,824
  • 33
  • 119
  • 194
  • _“Can I make my div have height expressed in number of lines”_ – no, but for a fixed number of visible lines you can try to find the right `height` to use in accordance to `font-size` and `line-height`. (Maybe you want to give the height in a unit relative to font-size, like `em`.) – CBroe Mar 28 '14 at 01:40
  • Don't specify div height. make it height:auto; – Kiran Mar 28 '14 at 01:43

0 Answers0