NSTextView scrolling behavior
NSTextView scrolling behavior
- Subject: NSTextView scrolling behavior
- From: Marten van Gelderen <email@hidden>
- Date: Thu, 10 Feb 2005 10:21:05 +0100
Hallo list,
About a year ago Seth Willits posted a message to the Apple Mailing
Lists concerning (in his view) a bug in NSTextView: if you have a text
that is larger than the scrollView and resize the window, the
horizontal scrollbar "jumps" to the right a little bit. There was no
reply.
I checked that Mike Ferris' example on text sizing displays the same
behavior in the BiScrollerAspect both in the horizontal and in the
vertical scrollbars. Also TextEdit.app displays the same behavior but
this time (obviously) only in the vertical scrollbar. XCode's own
editor also displays some jump behavior in the vertical direction (when
resizing the window), but this could very well have to to with
displaying the lines with their linenumbers properly. Horizontally
there is no jump.
I already figured out that it has to to with where the cursor (not a
selection) is. If it is inside the scrollView, resizing the window
somehow tries to "center" the cursor (but not a selection) in the
scrollView. If the cursor is in the upper left quadrant there is no
centering possible/necessary and everything works fine. When the cursor
is outside the scrollView, resizing probably also tries to do something
which results in the small jump (both horizontally and vertically). The
"little jump" behavior also happens when the cursor is before the first
character of the text (that is at the very outer left/top limit of the
left quadrant).
Any remarks will be greatly appreciated.
--
Groeten, Marten
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden