Further improvements to auto scrolling and text rect + container view resizing:
* Renaming things in Tracker list mode no longer magically grows the text view. * ScrollToOffset() is not supposed to depend on the existence of any scroll bars, in R5 text views simply scroll to where they need to. This fixes renaming things in Tracker when hitting the window bounds (text widget stops growing and starts to autoscroll) and also the Text tool in WonderBrush. * _ScrollToOffset() is therefor no longer needed. * The insets of the text rect are not so interesting as the original width. In auto resizing mode, the original width is important when there is no container view. In this setup, the text rect auto resizing is mainly needed for auto scrolling, but it should never shrink below the original size. * Further improved auto scrolling for right aligned and center aligned text views, it works like R5 now. Also take the line height into account when checking for the bounds bottom. Removed extra spacing for vertical scrolling. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24130 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -205,8 +205,6 @@ class BTextView : public BView {
|
||||
undo_state UndoState(bool* isRedo) const;
|
||||
|
||||
protected:
|
||||
void _ScrollToOffset(int32 nOffset, bool useHorz, bool useVert);
|
||||
|
||||
virtual void GetDragParameters(BMessage* drag, BBitmap** _bitmap,
|
||||
BPoint* point, BHandler** _handler);
|
||||
|
||||
@@ -315,8 +313,7 @@ class BTextView : public BView {
|
||||
_BLineBuffer_* fLines;
|
||||
_BStyleBuffer_* fStyles;
|
||||
BRect fTextRect;
|
||||
float fLeftInset;
|
||||
float fRightInset;
|
||||
float fMinTextRectWidth;
|
||||
int32 fSelStart;
|
||||
int32 fSelEnd;
|
||||
bool fCaretVisible;
|
||||
@@ -347,7 +344,7 @@ class BTextView : public BView {
|
||||
BPoint fWhere;
|
||||
_BTextTrackState_* fTrackingMouse;
|
||||
_BTextChangeResult_* fTextChange;
|
||||
uint32 _reserved[7];
|
||||
uint32 _reserved[8];
|
||||
|
||||
static _BWidthBuffer_* sWidths;
|
||||
static sem_id sWidthSem;
|
||||
|
||||
Reference in New Issue
Block a user