How to find where browser breaks a paragraph of text

后端 未结 5 1585
谎友^
谎友^ 2021-01-19 03:46

I need to add line breaks in the positions that the browser naturally adds a newline in a paragraph of text.

For example:

This is some very long tex

5条回答
  •  北海茫月
    2021-01-19 03:56

    I don't think you'll be able to do this with any kind of accuracy without embedding Gecko/WebKit/Trident or essentially recreating them.

提交回复
热议问题