Is it possible to know the line-boxes a block element with inline elements inside has been broken up? This is a hard question for html experts but you can see what I mean here: http://bit.ly/6EMfet at “Inline flow” paragraph. I need to have the heights of each line-box the block ended up being made of at rendering time.
Is it possible to know the line-boxes a block element with inline elements inside
Share
element.getClientRects should be the answer. I tried it in a WebBrowser control in c# application and it seems to work but I tried it in a WebView in Android application too and it yields just 1 rect. I found that on Android I can successfully use {range = document.createRange();range.selectNode(element); rects=range.getClientRects(); } which yields the useful array of rects (note: the first rect is the bounding rectangle)