Hello! I have just finished fixing all the bugs I found in Classpath to get the directory server running really well. There are still some things that are being worked on, such as some text, combo box and layout bugs. Attached is the patch needed to run the server against Classpath. After applying the patch and re-building, the jars that were built need to be replaced with the console jars. The console jar files are in the directory /opt/fedora-ds/java and /opt/fedora-ds/java/jars. Enjoy! Lillian
Index: build.xml =================================================================== RCS file: /cvs/dirsec/console/build.xml,v retrieving revision 1.1.1.1 diff -u -r1.1.1.1 build.xml --- build.xml 18 Jul 2005 00:34:05 -0000 1.1.1.1 +++ build.xml 11 Nov 2005 22:01:09 -0000 @@ -34,8 +34,8 @@ <property name="javadoc.dir" value="${built.dir}/doc"/> <property name="imports.dir" value="${consolesdk.root}/imports"/> <property name="java.src.dir" value="src"/> - - <!-- Prepare --> + <property environment="env"/> +<!-- Prepare --> <target name="prepare_build"> <!-- Create directories --> <mkdir dir="${built.classdir}"/> @@ -119,11 +119,12 @@ <!-- Build --> <target name="build" depends="import_ldapjdk,import_jss_jar"> <!-- compile regular java code --> - <javac srcdir="${java.src.dir}" + <javac srcdir="${java.src.dir}" destdir="${built.classdir}" debug="${compile.debug}" deprecation="${compile.deprecation}" optimize="${compile.optimize}" verbose="no" + fork="true" excludes="**/CVS/**"> <classpath refid="consolesdk.classpath" /> </javac> Index: src/com/netscape/management/client/ResourceCellRenderer.java =================================================================== RCS file: /cvs/dirsec/console/src/com/netscape/management/client/ResourceCellRenderer.java,v retrieving revision 1.1.1.1 diff -u -r1.1.1.1 ResourceCellRenderer.java --- src/com/netscape/management/client/ResourceCellRenderer.java 18 Jul 2005 00:34:07 -0000 1.1.1.1 +++ src/com/netscape/management/client/ResourceCellRenderer.java 11 Nov 2005 22:01:09 -0000 @@ -19,15 +19,10 @@ * END COPYRIGHT BLOCK **/ package com.netscape.management.client; -import java.util.*; import java.awt.*; -import java.awt.event.*; import javax.swing.*; -import javax.swing.event.*; import javax.swing.tree.*; -import javax.swing.border.*; import javax.swing.plaf.basic.*; -import com.netscape.management.client.util.*; /** * A specialized tree cell renderer for use with the ResourcePage tree. @@ -116,21 +111,23 @@ } else setText( tree.convertValueToText(value, selected, expanded, leaf, row, hasFocus)); - + return this; } public void paint(Graphics g) { Color backgroundColor; Icon icon = getIcon(); - int iconTextGap = getIconTextGap() - 2; + int iconTextGap = getIconTextGap(); + String s = getText(); int offset = 0; - int width = getWidth(); - int height = getHeight(); - - if (iconTextGap < 0) - iconTextGap = 0; - + int width = 0; + FontMetrics fm = getToolkit().getFontMetrics(getFont()); + + if (s != null) + width = SwingUtilities.computeStringWidth(fm, s); + int height = fm.getHeight() + 2; + if (icon != null) offset = icon.getIconWidth() + iconTextGap; @@ -146,21 +143,20 @@ g.setColor(backgroundColor); if (icon != null && getText() != null) { - g.fillRect(offset + 1, 1, width - 2 - offset, height - 2); + g.fillRect(offset + 1, 1, width, height); } else { - g.fillRect(1, 1, width - 2 - offset, height - 2); + g.fillRect(1, 1, width, height); } - super.paint(g); if (_isSelected) { if (_hasFocus) { g.setColor(Color.black); // TODO: hard-coded value BasicGraphicsUtils.drawDashedRect(g, offset, 0, - width - 1 - offset, height); + width, height); } else { g.setColor(backgroundColor); - g.drawRect(offset, 0, width - 1 - offset, height - 1); + g.drawRect(offset, 0, width, height); } } } Index: src/com/netscape/management/client/console/Console.java =================================================================== RCS file: /cvs/dirsec/console/src/com/netscape/management/client/console/Console.java,v retrieving revision 1.1.1.1 diff -u -r1.1.1.1 Console.java --- src/com/netscape/management/client/console/Console.java 18 Jul 2005 00:34:14 -0000 1.1.1.1 +++ src/com/netscape/management/client/console/Console.java 11 Nov 2005 22:01:10 -0000 @@ -28,8 +28,7 @@ import java.net.MalformedURLException; import javax.swing.*; -import javax.swing.event.*; -import javax.swing.border.*; +import javax.swing.plaf.metal.*; import com.netscape.management.nmclf.*; import com.netscape.management.client.*; Index: src/com/netscape/management/client/util/AbstractDialog.java =================================================================== RCS file: /cvs/dirsec/console/src/com/netscape/management/client/util/AbstractDialog.java,v retrieving revision 1.1.1.1 diff -u -r1.1.1.1 AbstractDialog.java --- src/com/netscape/management/client/util/AbstractDialog.java 18 Jul 2005 00:34:25 -0000 1.1.1.1 +++ src/com/netscape/management/client/util/AbstractDialog.java 11 Nov 2005 22:01:10 -0000 @@ -240,7 +240,7 @@ } c.setBackground(UIManager.getColor("control")); - c.setForeground(UIManager.getColor("text")); + c.setForeground(UIManager.getColor("textText")); } protected void finalize() throws Throwable { Index: src/com/netscape/management/nmclf/SuiLookAndFeel.java =================================================================== RCS file: /cvs/dirsec/console/src/com/netscape/management/nmclf/SuiLookAndFeel.java,v retrieving revision 1.1.1.1 diff -u -r1.1.1.1 SuiLookAndFeel.java --- src/com/netscape/management/nmclf/SuiLookAndFeel.java 18 Jul 2005 00:34:28 -0000 1.1.1.1 +++ src/com/netscape/management/nmclf/SuiLookAndFeel.java 11 Nov 2005 22:01:10 -0000 @@ -24,15 +24,9 @@ import javax.swing.*; import javax.swing.border.*; import javax.swing.plaf.basic.*; -import com.sun.java.swing.plaf.windows.*; +import javax.swing.plaf.metal.*; import javax.swing.plaf.*; -import javax.swing.text.JTextComponent; -import javax.swing.text.DefaultEditorKit; -import java.awt.event.KeyEvent; -import java.awt.event.InputEvent; -import java.util.*; -import java.net.URL; import java.io.Serializable; import com.netscape.management.client.util.*; @@ -49,7 +43,7 @@ * @author Ben fry * @author Andy Hakim */ -public class SuiLookAndFeel extends WindowsLookAndFeel implements Serializable, SuiConstants +public class SuiLookAndFeel extends MetalLookAndFeel implements Serializable, SuiConstants { public static final boolean _isWindows = System.getProperty("os.name").startsWith("Windows"); Index: src/com/netscape/management/nmclf/SuiTreeUI.java =================================================================== RCS file: /cvs/dirsec/console/src/com/netscape/management/nmclf/SuiTreeUI.java,v retrieving revision 1.1.1.1 diff -u -r1.1.1.1 SuiTreeUI.java --- src/com/netscape/management/nmclf/SuiTreeUI.java 18 Jul 2005 00:34:28 -0000 1.1.1.1 +++ src/com/netscape/management/nmclf/SuiTreeUI.java 11 Nov 2005 22:01:10 -0000 @@ -20,16 +20,11 @@ package com.netscape.management.nmclf; import java.awt.*; -import java.awt.event.*; - -import java.io.*; -import java.util.*; import javax.swing.*; import javax.swing.plaf.*; import javax.swing.tree.*; import javax.swing.plaf.basic.*; -import com.sun.java.swing.plaf.windows.*; /** * A UI for JTree. The original intent was to use curved lines