bug-classpath
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug swing/26967] JTextField doesn't scroll when typing beyond boundary


From: thebohemian at gmx dot net
Subject: [Bug swing/26967] JTextField doesn't scroll when typing beyond boundary
Date: 13 Apr 2006 12:32:58 -0000


------- Comment #2 from thebohemian at gmx dot net  2006-04-13 12:32 -------
The following patch fixes the issue (I mentioned the wrong PR number though
...)

CVSROOT:        /cvsroot/classpath
Module name:    classpath
Branch:         
Changes by:     Robert Schuster <address@hidden>    06/04/13
12:20:43

Modified files:
        javax/swing    : JTextField.java 
        javax/swing/text: FieldView.java 
        .              : ChangeLog 

Log message:
        Fixes PR 26947.

        2006-04-13  Robert Schuster  <address@hidden>

        PR 26947
        * javax/swing/JTextField.java: Removed scrollOffset variable.
        (JTextField): Moved up initialization of horizontalVisibility field.
        (getScrollOffset): Implemented.
        (setScrollOffset): Implemented.
        (getHorizonztalVisibility): Removed note.
        (scrollRectToVisible): New method.
        * javax/swing/text/FieldView.java: Added cachedSpan variable.
        (checkContainer): New method.
        (updateVisibility): New method.
        (calculateHorizontalSpan): New method.
        (adjustAllocation): Removed unneeded local variables, added code
        to handle scrolling.
        (getPreferredSpan): Use new method calculateHorizontalSpan,
        avoid calculation by returning cached value cachedSpan.
        (paint): Added check whether the hosted component is a JTextField.
        (insertUpdate): Invalidate cached span value, update visibility
        if neccessary.
        (removeUpdate): Dito.
        (changeUpdate): Dito.

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/classpath/classpath/javax/swing/JTextField.java.diff?tr1=1.31&tr2=1.32&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/classpath/classpath/javax/swing/text/FieldView.java.diff?tr1=1.12&tr2=1.13&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/classpath/classpath/ChangeLog.diff?tr1=1.7093&tr2=1.7094&r1=text&r2=text

(Later I fixed the ChangeLog entry).


-- 

thebohemian at gmx dot net changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|                            |FIXED
   Target Milestone|---                         |0.91


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26967





reply via email to

[Prev in Thread] Current Thread [Next in Thread]