Hi Jean-Marc > I hope you found your way out of this problem. Otherwise tomorrow I will comment on your patch and give advice.
> I think I found the pr > oblem. That is because in the for loop I am updatingthe left edge all the time. I will try to correct it. Although I found the reason, I am still trying to correct it. I want to call the new method cur.setLeftEdge() for only once when drawing a page. What I have done in my last commit was totally wrong, because there I am calling it per row. If I call it after the for loop in drawparagraph() method, that is also not correct. If I do so only one paragraph gets slid. So I tried calling it after the TextMetrics::draw(PainterInfo & pi, int x, int y) const method. What I thought was, this draw method draws all the paragraphs in a document. But it seems like it is not correct. After doing so, again only one paragraph got slid. Could you please tell me what would be the correct place? And where this draw() method gets called? Another problem is; if the current algorithm is used, when a row gets slide the cursor will be placed exactly at the right edge. Therefore the cursor will not appear to the outside. Proper solution would be sliding by an amount equals to (current cursor position- cursor position if the cursor is at one letter before (to left).) Is there a direct way to get this cursor position if the cursor is at one letter before? We may not gone through this cursor position (if going from right to left/ if we directly select a position using the mouse pointer). I noticed another thing. What is the different between cur.targetX() and bv.getPos(cur).x_? They give different values sometime. I feel bv.getPos(cur).x_ is more accurate. Before and just after entering a Math equation; cur.targetX() gives the same value (eg: 10). But bv.getPos(cur).x_ gives different values (eg 10 & 13). Thank you Hashini