title: Wrapping the text the same way in a div as in a textarea
body: <p>I'm creating a suggestion panel while live editing an HTML textarea. To get the {x,y} coordinates I use an hidden div placed behind the textarea. I get the carret position and then copy the text before the carret plus a span tag to the hidden div. Then I get the span coordinates and give it to the suggestion panel.</p>
  
  <p>The only problem is that when I add a long line without spaces to the textarea, the line is being wrapped while it's cut in the div panel (so the suggestion panel is not well placed anymore until I add a carriage return).</p>
  
  <p>Is there a way to fit the text the same way in these two places (textarea and div panel) ?</p>
  
  <p>(i'm using jQuery)</p>