Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4073822

Fast scrolling causes un-needed refreshings of the whole child of a ScrollPane.

XMLWordPrintable

    • kestrel
    • x86
    • generic, windows_95



      Name: joT67522 Date: 08/22/97


      1. Construct a Frame sub-class (we are talking about an application)
         with its default layout.
      2. Construct a new ScrollPane object with the default constructor:
         'new ScrollPane()'.
      3. Construct a new Canvas sub-class.
      4. Draw on the canvas some graphical figures using the Graphics
         drawing API, also in coordinates beyond the shown area of the
         Frame so that the scroll bars will be created.
      5. Scroll fas in any direction by continuously holding the button
         left button on any of the scroll bar's arrowed edges.
      The Problem:
       When successive scrolling is requested, such that the canvas
       contents does not ends moving the increment amount before the
       next scrolling event is received, the whole
       canvas is refreshed, i.e. erased and redrawn again, what makes
       scrolling very inconvenient and very very slow.

       This behaved differently in JDK1.1Beta3. There was never a redraw
       of the whole canvas. I think that you have fixed some other bug
       regarding resources consumed during scrolling in the Beta3, but
       have brouht in another problem.

      company - Softera , email - ###@###.###
      ======================================================================

      ronan.mandel@Eng 1997-10-23
      After a validate(), ScrollPane redraws the whole
      of the component it contains. This redraw is not
      limited to the visible region of the component
      within the viewport of the ScrollPane. If the
      ScrollPane contains a large component it takes
      ages to redraw, rather than the redraw being
      proportional to the size of the ScrollPane.
      This is a very inefficient implementation.
      The ScrollPane should impose a clip region
      defined by the viewport when it redraws the
      component it contains.

            rkhansunw Robi Khan (Inactive)
            johsunw Joon Oh (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: