svn commit: r944088 - /logging/chainsaw/trunk/src/main/java/org/apache/log4j/chainsaw/LogPanel.java

[email protected]
Newsgroups gmane.comp.apache.logging
Message-ID <[email protected]>
Author: sdeboy
Date: Fri May 14 03:02:00 2010
New Revision: 944088

URL: http://svn.apache.org/viewvc?rev=944088&view=rev
Log:
Change vertical scrollbar unit increment to equal row height

When clicking scrollbar arrows in variable row height mode, default behavior is to shift the displayed events down enough to display the entire next event, which may cause a large change in the displayed events if the row has a large height.

This behavior is now changed - clicking on scroll bar arrows shifts the events up or down one standard row height)

Modified:
    logging/chainsaw/trunk/src/main/java/org/apache/log4j/chainsaw/LogPanel.java

Modified: logging/chainsaw/trunk/src/main/java/org/apache/log4j/chainsaw/LogPanel.java
URL: http://svn.apache.org/viewvc/logging/chainsaw/trunk/src/main/java/org/apache/log4j/chainsaw/LogPanel.java?rev=944088&r1=944087&r2=944088&view=diff
==============================================================================
--- logging/chainsaw/trunk/src/main/java/org/apache/log4j/chainsaw/LogPanel.java (original)
+++ logging/chainsaw/trunk/src/main/java/org/apache/log4j/chainsaw/LogPanel.java Fri May 14 03:02:00 2010
@@ -1123,6 +1123,7 @@ public class LogPanel extends DockablePa
     JPanel eventsAndStatusPanel = new JPanel(new BorderLayout());
 
     eventsPane = new JScrollPane(table);
+    eventsPane.getVerticalScrollBar().setUnitIncrement(table.getRowHeight());
 
     eventsAndStatusPanel.add(eventsPane, BorderLayout.CENTER);
     JPanel rightPanel = new JPanel();
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.