corvid, you have just fixed an issue with horizontal scrolling during search. While testing it I realized, that horizontal scrolling during search does not work at all with plain text. Any idea why? Cheers, Johannes
Johannes wrote:
corvid, you have just fixed an issue with horizontal scrolling during search. While testing it I realized, that horizontal scrolling during search does not work at all with plain text. Any idea why?
Actually, I made a patch for that last night (attached). getAllocation() determines the boundaries and position of a Word, and then Iterator's scrollTo() figures out how to place it. But for plain text, the whole line is a Word, so scrollTo was just positioning the line as a whole and considering its work done. In the patch, I take start and end into account to figure out what part of the Word we really want to see. (The current behaviour of showing the whole word is a little bit nicer for html with "normal"-sized Words, but...)
On Wed, Sep 02, 2009 at 05:02:28PM +0000, corvid wrote:
Johannes wrote:
corvid, you have just fixed an issue with horizontal scrolling during search. While testing it I realized, that horizontal scrolling during search does not work at all with plain text. Any idea why?
Actually, I made a patch for that last night (attached).
getAllocation() determines the boundaries and position of a Word, and then Iterator's scrollTo() figures out how to place it.
But for plain text, the whole line is a Word, so scrollTo was just positioning the line as a whole and considering its work done.
In the patch, I take start and end into account to figure out what part of the Word we really want to see. (The current behaviour of showing the whole word is a little bit nicer for html with "normal"-sized Words, but...)
Cool! Please commit. Cheers, Johannes
participants (2)
-
corvid@lavabit.com
-
Johannes.Hofmann@gmx.de