Hi,
I have a question about text selection in KHTML.  I am using KHTMLPart in my small application. By default double clicking on a peace of text that contains only one word selects the text. But I want to select a text that contains multiple words by dragging a mouse with pressed left button, the same way it works in Konqueror. I was able to get it to work by calculating "number of characters" in a pixel in a DOM::Node by simply dividing DOM:: Node.nodeValue().length() / DOM::Node.getRect().width(); Then I just calculated a DOM::Range in MouseMoveEvent and call KHTMLPart::setSelection(DOM::Range). It works very well, but only when DOM::Node does not span multiple lines. When it does the proportion chars/pixel is wrong. I don't know x coordinate where the text ends.  I tried to find how it is done in Konqueror, but could not find it. Can some one point me how to do it or where to find similar code since it works in Konqueror out of the box.

--
Sergejs Melderis