[izpack-changes] r1841 - izpack-src/branches/3.10/src/lib/com/izforge/izpack/gui
noreply at berlios.de
noreply at berlios.de
Tue May 22 10:14:59 CEST 2007
Author: bartzkau
Date: 2007-05-22 10:14:58 +0200 (Tue, 22 May 2007)
New Revision: 1841
Modified:
izpack-src/branches/3.10/src/lib/com/izforge/izpack/gui/IzPanelLayout.java
Log:
Used width for stretched components changed.
Modified: izpack-src/branches/3.10/src/lib/com/izforge/izpack/gui/IzPanelLayout.java
===================================================================
--- izpack-src/branches/3.10/src/lib/com/izforge/izpack/gui/IzPanelLayout.java 2007-05-22 07:58:09 UTC (rev 1840)
+++ izpack-src/branches/3.10/src/lib/com/izforge/izpack/gui/IzPanelLayout.java 2007-05-22 08:14:58 UTC (rev 1841)
@@ -826,6 +826,12 @@
int curPixel = (int) ((colConstraints[i].getXStretch() / rowStretch) * pixel);
Rectangle curBounds = colConstraints[i].component.getBounds();
+ // The width of some components differ from time to time. E.g. a JScrollPane
+ // with a JEditorPane as viewport has sometimes the minimum column width and
+ // some times the width of the scroll bar. Therefore we use the minimum
+ // column width.
+ int curWidth = this.minimumColumnWidth(i);
+ if (curBounds.width < curWidth) curBounds.width = curWidth;
int newWidth = curPixel + curBounds.width;
colConstraints[i].component.setBounds(curBounds.x + offset, curBounds.y,
newWidth, curBounds.height);
More information about the izpack-changes
mailing list