Re: [cp-patches] Patch: improve error handling in String

2005-09-15 Thread Meskauskas Audrius

Would it be better to use InternalError?  That is a little more specific.

That one is more difficult to chain (.initCause() must be used).

David Daney wrote:


Anthony Green wrote:


-  // XXX - Ignore coding exceptions? They shouldn't really happen.
-  return null;
+  // This shouldn't really happen.
+  throw new Error(e);






___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


Re: [cp-patches] Patch: minor ZipFile improvement

2005-09-15 Thread Tom Tromey
 Anthony == Anthony Green [EMAIL PROTECTED] writes:

Anthonyprivate void checkZipFile() throws IOException, ZipException
Anthony{
Anthony  byte[] magicBuf = new byte[4];
Anthony -raf.read(magicBuf);
Anthony -if (readLeInt(magicBuf, 0) != LOCSIG)
Anthony +if (raf.read(magicBuf) != 4
Anthony +  || readLeInt(magicBuf, 0) != LOCSIG)
Anthony{
Anthonyraf.close();
Anthonythrow new ZipException(Not a valid zip file);

Actually we ought to try reading until we get all 4 bytes or see EOF.
A short read is valid and not an error.

Tom


___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


Re: [cp-patches] Patch: fix || expressions in jdwp code

2005-09-15 Thread Mark Wielaard
Hi Anthony,

On Wed, 2005-09-14 at 17:49 -0700, Anthony Green wrote:
{
 -if (tid == null | tid.getReference().get () == null)
 +if (tid == null || tid.getReference().get () == null)
throw new InvalidThreadException (tid.getId ());

Note that in this case, and the case below you still will get a
NullPointerException, not an InvalidThreadException if tid == null.

Cheers,

Mark


signature.asc
Description: This is a digitally signed message part
___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


Re: [cp-patches] Patch: Class.pd is transient

2005-09-15 Thread Mark Wielaard
Hi Anthony,

On Wed, 2005-09-14 at 17:41 -0700, Anthony Green wrote:
 FindBugs is complaining that Class.pd will mess up serialization. 
 I don't know if this is the best fix.  Comments?

java.lang.Class is special for serialization. So this shouldn't be
necessary. Although I doubt it hurts.

Cheers,

Mark


signature.asc
Description: This is a digitally signed message part
___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


Re: [cp-patches] Patch: close charset provider readers

2005-09-15 Thread Mark Wielaard
Hi Anthony,

On Wed, 2005-09-14 at 17:38 -0700, Anthony Green wrote:
 We should close each reader we open.  Ok?

Yes that is fine.
Although better would be to rewrite this code to use
gnu.classpath.ServiceFactory which was specifically designed to
dynamically read providers from services files.

Cheers,

Mark


signature.asc
Description: This is a digitally signed message part
___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


[cp-patches]: Patch: JOptionPane fix

2005-09-15 Thread Lillian Angel
2005-09-15  Lillian Angel  [EMAIL PROTECTED]

Fixes #23873
* javax/swing/plaf/basic/BasicOptionPaneUI.java
(createMessageArea): Changed orientation of message from EAST to
CENTER. Also, fixed empty border values to make message more 
centered.
* javax/swing/JOptionPane.java
(showConfirmDialog): Added check for pane.getValue, since 
clicking on 'x' of window does not have an initialized value. 
Was causing a ClassCastException.
(showConfirmDialog): Likewise.
(showConfirmDialog): Likewise.
(showConfirmDialog): Likewise.

? .ChangeLog.swp
Index: ChangeLog
===
RCS file: /cvsroot/classpath/classpath/ChangeLog,v
retrieving revision 1.4793
diff -u -r1.4793 ChangeLog
--- ChangeLog	15 Sep 2005 13:19:07 -	1.4793
+++ ChangeLog	15 Sep 2005 14:02:12 -
@@ -1,3 +1,17 @@
+2005-09-15  Lillian Angel  [EMAIL PROTECTED]
+	
+	Fixes #23873
+	* javax/swing/plaf/basic/BasicOptionPaneUI.java
+	(createMessageArea): Changed orientation of message from EAST to
+	CENTER. Also, fixed empty border values to make message more centered.
+	* javax/swing/JOptionPane.java
+	(showConfirmDialog): Added check for pane.getValue, since clicking on 
+	'x' of window does not have an initialized value. Was causing a 
+	ClassCastException.
+	(showConfirmDialog): Likewise.
+	(showConfirmDialog): Likewise.
+	(showConfirmDialog): Likewise.
+
 2005-09-15  David Gilbert  [EMAIL PROTECTED]
 
 	* javax/swing/plaf/basic/BasicButtonUI.java
Index: java/awt/BorderLayout.java
===
RCS file: /cvsroot/classpath/classpath/java/awt/BorderLayout.java,v
retrieving revision 1.18
diff -u -r1.18 BorderLayout.java
--- java/awt/BorderLayout.java	4 Aug 2005 18:10:44 -	1.18
+++ java/awt/BorderLayout.java	15 Sep 2005 14:02:13 -
@@ -423,6 +423,7 @@
*/
   public float getLayoutAlignmentX(Container parent)
   {
+System.out.println(parent.getAlignmentX());
 return(parent.getAlignmentX());
   }
 
Index: javax/swing/JOptionPane.java
===
RCS file: /cvsroot/classpath/classpath/javax/swing/JOptionPane.java,v
retrieving revision 1.16
diff -u -r1.16 JOptionPane.java
--- javax/swing/JOptionPane.java	13 Sep 2005 23:23:40 -	1.16
+++ javax/swing/JOptionPane.java	15 Sep 2005 14:02:13 -
@@ -863,8 +863,10 @@
 
 dialog.pack();
 dialog.show();
-
-return ((Integer) pane.getValue()).intValue();
+
+if (pane.getValue() instanceof Integer)
+  return ((Integer) pane.getValue()).intValue();
+return -1;
   }
 
   /**
@@ -889,7 +891,9 @@
 dialog.pack();
 dialog.show();
 
-return ((Integer) pane.getValue()).intValue();
+if (pane.getValue() instanceof Integer)
+  return ((Integer) pane.getValue()).intValue();
+return -1;
   }
 
   /**
@@ -915,7 +919,9 @@
 dialog.pack();
 dialog.show();
 
-return ((Integer) pane.getValue()).intValue();
+if (pane.getValue() instanceof Integer)
+  return ((Integer) pane.getValue()).intValue();
+return -1;
   }
 
   /**
@@ -943,7 +949,9 @@
 dialog.pack();
 dialog.show();
 
-return ((Integer) pane.getValue()).intValue();
+if (pane.getValue() instanceof Integer)
+  return ((Integer) pane.getValue()).intValue();
+return -1;
   }
 
   /**
Index: javax/swing/plaf/basic/BasicOptionPaneUI.java
===
RCS file: /cvsroot/classpath/classpath/javax/swing/plaf/basic/BasicOptionPaneUI.java,v
retrieving revision 1.22
diff -u -r1.22 BasicOptionPaneUI.java
--- javax/swing/plaf/basic/BasicOptionPaneUI.java	13 Sep 2005 23:23:41 -	1.22
+++ javax/swing/plaf/basic/BasicOptionPaneUI.java	15 Sep 2005 14:02:13 -
@@ -860,10 +860,10 @@
 addIcon(messageArea);
 
 JPanel rightSide = new JPanel();
-rightSide.setBorder(BorderFactory.createEmptyBorder(0, 11, 17, 0));
+rightSide.setBorder(BorderFactory.createEmptyBorder(10, 10, 10, 10));
 rightSide.setLayout(new GridBagLayout());
 GridBagConstraints con = createConstraints();
-
+
 addMessageComponents(rightSide, con, getMessage(),
  getMaxCharactersPerLineCount(), false);
 
@@ -886,7 +886,7 @@
 	  }
   }
 
-messageArea.add(rightSide, BorderLayout.EAST);
+messageArea.add(rightSide, BorderLayout.CENTER);
 
 return messageArea;
   }
___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


Re: [cp-patches] patch for approval fixes bug #23006

2005-09-15 Thread Anthony Balkissoon
Done.
--Tony

On Thu, 2005-09-15 at 00:22 +0200, Roman Kennke wrote:
 Am Mittwoch, den 14.09.2005, 13:17 -0400 schrieb Anthony Balkissoon:
  This patch was inappropriate.  The appropriate changes should be made in
  JTextArea.  I've attached the new patch and will check it in and the
  Mauve test case.
  
  2005-09-14  Anthony Balkissoon  [EMAIL PROTECTED]
  
  * javax/swing/JTextArea.java:
  (append): After non-empty append, invalidate.
  (setRows): If number of rows changes, invalidate.
  (setColumns): If number of columns changes, invalidate.
 
 In Swing you should not use invalidate(). Generally you should use
 revalidate() in Swing. This also calls invalidate() and triggers the
 Swing RepaintManager to do it's job and validate and repaint the
 component soon. Could you change that?
   
 /Roman
 



___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


Re: [cp-patches] Patch: minor URLStreamHandler cleanup

2005-09-15 Thread Mark Wielaard
Hi,

On Wed, 2005-09-14 at 18:03 -0700, Anthony Green wrote:
 All this does is remove a redundant null pointer check.  This could
 never be null since we would have thrown an exception a couple of lines
 before (see the first line of the patch).

 2005-09-14  Anthony Green  [EMAIL PROTECTED]
 
   * java/net/URLStreamHandler.java: Remove redundant null pointer
   check.

Note that there are various other places in URLStreamHandler that are
checking for null on the URL protocol part. Which can never happen since
URL is final and its constructors don't allow a null protocol.

Cheers,

Mark


signature.asc
Description: This is a digitally signed message part
___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


Re: [cp-patches]: Patch: JOptionPane fix

2005-09-15 Thread Lillian Angel
Oops! That is just in my patch, i never committed that file.
attached is the proper patch.

On Thu, 2005-09-15 at 16:40 +0200, Mark Wielaard wrote:
 Hi Lillian,
 
 On Thu, 2005-09-15 at 10:04 -0400, Lillian Angel wrote:
  --- java/awt/BorderLayout.java  4 Aug 2005 18:10:44 -   1.18
  +++ java/awt/BorderLayout.java  15 Sep 2005 14:02:13 -
  @@ -423,6 +423,7 @@
  */
 public float getLayoutAlignmentX(Container parent)
 {
  +System.out.println(parent.getAlignmentX());
   return(parent.getAlignmentX());
 }
 
 You left some debug output there.
 
 Cheers,
 
 Mark
Index: javax/swing/JOptionPane.java
===
RCS file: /cvsroot/classpath/classpath/javax/swing/JOptionPane.java,v
retrieving revision 1.16
diff -u -r1.16 JOptionPane.java
--- javax/swing/JOptionPane.java	13 Sep 2005 23:23:40 -	1.16
+++ javax/swing/JOptionPane.java	15 Sep 2005 14:02:13 -
@@ -863,8 +863,10 @@
 
 dialog.pack();
 dialog.show();
-
-return ((Integer) pane.getValue()).intValue();
+
+if (pane.getValue() instanceof Integer)
+  return ((Integer) pane.getValue()).intValue();
+return -1;
   }
 
   /**
@@ -889,7 +891,9 @@
 dialog.pack();
 dialog.show();
 
-return ((Integer) pane.getValue()).intValue();
+if (pane.getValue() instanceof Integer)
+  return ((Integer) pane.getValue()).intValue();
+return -1;
   }
 
   /**
@@ -915,7 +919,9 @@
 dialog.pack();
 dialog.show();
 
-return ((Integer) pane.getValue()).intValue();
+if (pane.getValue() instanceof Integer)
+  return ((Integer) pane.getValue()).intValue();
+return -1;
   }
 
   /**
@@ -943,7 +949,9 @@
 dialog.pack();
 dialog.show();
 
-return ((Integer) pane.getValue()).intValue();
+if (pane.getValue() instanceof Integer)
+  return ((Integer) pane.getValue()).intValue();
+return -1;
   }
 
   /**
Index: javax/swing/plaf/basic/BasicOptionPaneUI.java
===
RCS file: /cvsroot/classpath/classpath/javax/swing/plaf/basic/BasicOptionPaneUI.java,v
retrieving revision 1.22
diff -u -r1.22 BasicOptionPaneUI.java
--- javax/swing/plaf/basic/BasicOptionPaneUI.java	13 Sep 2005 23:23:41 -	1.22
+++ javax/swing/plaf/basic/BasicOptionPaneUI.java	15 Sep 2005 14:02:13 -
@@ -860,10 +860,10 @@
 addIcon(messageArea);
 
 JPanel rightSide = new JPanel();
-rightSide.setBorder(BorderFactory.createEmptyBorder(0, 11, 17, 0));
+rightSide.setBorder(BorderFactory.createEmptyBorder(10, 10, 10, 10));
 rightSide.setLayout(new GridBagLayout());
 GridBagConstraints con = createConstraints();
-
+
 addMessageComponents(rightSide, con, getMessage(),
  getMaxCharactersPerLineCount(), false);
 
@@ -886,7 +886,7 @@
 	  }
   }
 
-messageArea.add(rightSide, BorderLayout.EAST);
+messageArea.add(rightSide, BorderLayout.CENTER);
 
 return messageArea;
   }
___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


Re: [cp-patches]: Patch: JOptionPane fix

2005-09-15 Thread Mark Wielaard
Hi Lillian,

On Thu, 2005-09-15 at 10:04 -0400, Lillian Angel wrote:
 --- java/awt/BorderLayout.java  4 Aug 2005 18:10:44 -   1.18
 +++ java/awt/BorderLayout.java  15 Sep 2005 14:02:13 -
 @@ -423,6 +423,7 @@
 */
public float getLayoutAlignmentX(Container parent)
{
 +System.out.println(parent.getAlignmentX());
  return(parent.getAlignmentX());
}

You left some debug output there.

Cheers,

Mark


signature.asc
Description: This is a digitally signed message part
___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


Re: [cp-patches] Patch: throw IOExceptions on closed PushbackInputStream operations

2005-09-15 Thread Mark Wielaard
Hi,

On Wed, 2005-09-14 at 18:00 -0700, Anthony Green wrote:
 If you try an operation on a closed PushbackInputStream, you'll probably
 get a NullPointerException.  This patch turns them into IOExceptions
 with an appropriate message.  I think this is a better response based on
 the spec (any error should throw an IOException).

 2005-09-14  Anthony Green  [EMAIL PROTECTED]
 
   * java/io/PushbackInputStream.java (available, read, skip): Handle
   closed stream operations gracefully.

Yes, but please write the following part like all others with an if
statement at the start of the method:

public int available() throws IOException
{
 -return (buf.length - pos) + super.available();
 +try {
 +  return (buf.length - pos) + super.available();
 +} catch (NullPointerException npe) {
 +  throw new IOException (Stream closed);
 +}
}

If you insist on writing it this way then please at least follow the
coding styleguide:
http://www.gnu.org/software/classpath/docs/hacking.html#SEC6

  try
{
  return (buf.length - pos) + super.available();
}
  catch (NullPointerException npe)
{
  throw new IOException(Stream closed);
}

Thanks,

Mark


signature.asc
Description: This is a digitally signed message part
___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


Re: [cp-patches] Patch: minor ZipFile improvement

2005-09-15 Thread Anthony Green
On Thu, 2005-09-15 at 07:27 -0600, Tom Tromey wrote:
 Actually we ought to try reading until we get all 4 bytes or see EOF.
 A short read is valid and not an error.

Ok, how about this?

2005-09-14  Anthony Green  [EMAIL PROTECTED]

* java/util/zip/ZipFile.java (checkZipFile): Make sure we read all
4 bytes of the magic number.

Index: java/util/zip/ZipFile.java
===
RCS file: /cvsroot/classpath/classpath/java/util/zip/ZipFile.java,v
retrieving revision 1.26
diff -u -r1.26 ZipFile.java
--- java/util/zip/ZipFile.java  13 Sep 2005 22:19:15 -  1.26
+++ java/util/zip/ZipFile.java  15 Sep 2005 15:03:56 -
@@ -144,9 +144,18 @@
   private void checkZipFile() throws IOException, ZipException
   {
 byte[] magicBuf = new byte[4];
-raf.read(magicBuf);
+boolean validRead = true;
 
-if (readLeInt(magicBuf, 0) != LOCSIG)
+try 
+  {
+   raf.readFully (magicBuf);
+  } 
+catch (EOFException) 
+  {
+   validRead = false;
+  } 
+
+if (validRead == false || readLeInt(magicBuf, 0) != LOCSIG)
   {
raf.close();
throw new ZipException(Not a valid zip file);




___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


Re: [cp-patches] Patch: throw IOExceptions on closed PushbackInputStream operations

2005-09-15 Thread Anthony Green
On Thu, 2005-09-15 at 16:44 +0200, Mark Wielaard wrote:
 Hi,
 
 On Wed, 2005-09-14 at 18:00 -0700, Anthony Green wrote:
  If you try an operation on a closed PushbackInputStream, you'll probably
  get a NullPointerException.  This patch turns them into IOExceptions
  with an appropriate message.  I think this is a better response based on
  the spec (any error should throw an IOException).
 
  2005-09-14  Anthony Green  [EMAIL PROTECTED]
  
  * java/io/PushbackInputStream.java (available, read, skip): Handle
  closed stream operations gracefully.
 
 Yes, but please write the following part like all others with an if
 statement at the start of the method:

But, unlike all the other methods, this method is unsynchronized.
Somebody could close the stream between the test and the use of buf.  A
try/catch block seemed like the best solution.

I'll commit this after reformatting.

Thanks,

AG





___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


Re: [cp-patches] Patch: throw IOExceptions on closed PushbackInputStream operations

2005-09-15 Thread Mark Wielaard
Hi Anthony,

On Thu, 2005-09-15 at 08:21 -0700, Anthony Green wrote:
  Yes, but please write the following part like all others with an if
  statement at the start of the method:
 
 But, unlike all the other methods, this method is unsynchronized.
 Somebody could close the stream between the test and the use of buf.  A
 try/catch block seemed like the best solution.

Ah, right, sorry I missed that. In that case something like:

  final byte[] buf = this.buf;
  if (buf == null)
throw new IOException (Stream closed);

  ... use buf ...

would be my preferred solution. But your try { } catch is equally valid.

Cheers,

Mark


signature.asc
Description: This is a digitally signed message part
___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


Re: [cp-patches] Patch: improve error handling in String

2005-09-15 Thread Tom Tromey
 David == David Daney [EMAIL PROTECTED] writes:

David Anthony Green wrote:
 -  // XXX - Ignore coding exceptions? They shouldn't really happen.
 -  return null;
 +  // This shouldn't really happen.
 +  throw new Error(e);

David Whould it be better to use InternalError?  That is a little
David more specific.

Yeah, I thought we had a rule about this, but I can't find it now.  I
think InternalError makes sense here (and furthermore should be in
hacking.texinfo).  Comments?

Tom


___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


Re: [cp-patches] Patch: improve error handling in String

2005-09-15 Thread David Daney

Tom Tromey wrote:

David == David Daney [EMAIL PROTECTED] writes:



David Anthony Green wrote:


- // XXX - Ignore coding exceptions? They shouldn't really happen.
- return null;
+ // This shouldn't really happen.
+ throw new Error(e);



David Whould it be better to use InternalError?  That is a little
David more specific.

Yeah, I thought we had a rule about this, but I can't find it now.  I
think InternalError makes sense here (and furthermore should be in
hacking.texinfo).  Comments?


You are preaching to the choir here, but:

My personal preference is that we should never throw any of: Throwable, 
Exception, RuntimeException, or Error.  There is always a reason why we 
are throwing.  This reason should be reflected in the type being thrown.


Too bad if the type that should be thrown does not have a constructor 
that takes a chained Throwable as its cause.  If this is the case use 
Throwable.initCause().  There is a reason that this method exists:  It 
is so that we can use it to report the best information available about 
what went wrong.



Just MHO,
David Daney


___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


[cp-patches] FYI: Component.isDisplayable fixlet and Window method removal

2005-09-15 Thread Anthony Balkissoon
Component.isDisplayable should return true if peer != null.  Window no
longer needs to override this method (and it doesn't, according to the
API), so I removed the method from Window.java.  Patch attached.

2005-09-15  Anthony Balkissoon  [EMAIL PROTECTED]

* java/awt/Component.java:
(isDisplayable): Return true if peer != null.
* java/awt/Window.java:
(isDisplayable): Removed this method. Now inherits from Component.

--Tony
Index: java/awt/Component.java
===
RCS file: /cvsroot/classpath/classpath/java/awt/Component.java,v
retrieving revision 1.72
diff -u -r1.72 Component.java
--- java/awt/Component.java	17 Aug 2005 08:54:40 -	1.72
+++ java/awt/Component.java	15 Sep 2005 16:45:23 -
@@ -735,7 +735,7 @@
   {
 if (parent != null)
   return parent.isDisplayable();
-return false;
+return peer != null;
   }
 
   /**
Index: java/awt/Window.java
===
RCS file: /cvsroot/classpath/classpath/java/awt/Window.java,v
retrieving revision 1.54
diff -u -r1.54 Window.java
--- java/awt/Window.java	9 Sep 2005 20:13:32 -	1.54
+++ java/awt/Window.java	15 Sep 2005 16:45:23 -
@@ -346,11 +346,6 @@
 super.hide();
   }
 
-  public boolean isDisplayable()
-  {
-return peer != null;
-  }
-
   /**
* Destroys any resources associated with this window.  This includes
* all components in the window and all owned top-level windows.
___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


Re: [cp-patches] Patch: improve error handling in String

2005-09-15 Thread Anthony Green
On Thu, 2005-09-15 at 09:50 -0600, Tom Tromey wrote:
  David == David Daney [EMAIL PROTECTED] writes:
 
 David Anthony Green wrote:
  -// XXX - Ignore coding exceptions? They shouldn't really happen.
  -return null;
  +// This shouldn't really happen.
  +throw new Error(e);
 
 David Whould it be better to use InternalError?  That is a little
 David more specific.
 
 Yeah, I thought we had a rule about this, but I can't find it now.  I
 think InternalError makes sense here (and furthermore should be in
 hacking.texinfo).  Comments?

InternalError doesn't let you specify a cause Exception, which is
handy in this case.

AG




___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


[cp-patches] FYI JRootPane fixlet

2005-09-15 Thread Anthony Balkissoon
I found this while running some tests for a JInternalFrame bug I'm
working on.  JRootPane's setContentPane method should remove the old
contentPane before adding the new one.  Also, the API says it should
throw an IllegalComponentStateException if the parameter is null.  Fixed
these.  Attached.

2005-09-15  Anthony Balkissoon  [EMAIL PROTECTED]

* javax/swing/JRootPane.java:
(setContentPane): Remove the old content pane first.  Throw 
IllegalComponentStateException if the parameter is null.  Added docs.

--Tony
Index: javax/swing/JRootPane.java
===
RCS file: /cvsroot/classpath/classpath/javax/swing/JRootPane.java,v
retrieving revision 1.25
diff -u -r1.25 JRootPane.java
--- javax/swing/JRootPane.java  9 Sep 2005 14:44:39 -   1.25
+++ javax/swing/JRootPane.java  15 Sep 2005 17:19:40 -
@@ -42,6 +42,7 @@
 import java.awt.Component;
 import java.awt.Container;
 import java.awt.Dimension;
+import java.awt.IllegalComponentStateException;
 import java.awt.LayoutManager;
 import java.awt.LayoutManager2;
 import java.io.Serializable;
@@ -404,1 +405,1 @@
   }

   /**
-   * DOCUMENT ME!
+   * Sets the JRootPane's content pane.  The content pane should typically be
+   * opaque for painting to work properly.  This method also
+   * removes the old content pane from the layered pane.
*
-   * @param p DOCUMENT ME!
+   * @param p the Container that will be the content pane
+   * @throws IllegalComponentStateException if p is null
*/
   public void setContentPane(Container p)
   {
-contentPane = p;
-getLayeredPane().add(contentPane, JLayeredPane.FRAME_CONTENT_LAYER);
+if (p == null)
+  throw new IllegalComponentStateException (cannot  +
+have a null content pane);
+else
+  {
+if (contentPane != null  contentPane.getParent() == layeredPane)
+  layeredPane.remove(contentPane);
+contentPane = p;
+getLayeredPane().add(contentPane, JLayeredPane.FRAME_CONTENT_LAYER);
+  }
   }

   /**

___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


Re: [cp-patches] FYI: Component.isDisplayable fixlet and Window method removal

2005-09-15 Thread Thomas Fitzsimmons
On Thu, 2005-09-15 at 12:50 -0400, Anthony Balkissoon wrote:
 Component.isDisplayable should return true if peer != null.  Window no
 longer needs to override this method (and it doesn't, according to the
 API), so I removed the method from Window.java.  Patch attached.

Window overrides isDisplayable specifically because
Window.isDisplayable's return value should *not* depend on its parents
displayability.  Please revert that part of this patch.  Also, it'd be
nice if you could add a javadoc to Window.isDisplayable explaining its
divergence from Component.isDisplayable.

Tom




___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


[cp-patches]: Patch: JFileChooser fix

2005-09-15 Thread Lillian Angel
2005-09-15  Lillian Angel  [EMAIL PROTECTED]

Fixes Bug #23678
* javax/swing/plaf/basic/BasicFileChooserUI.java
(CBLabelRenderer): Removed. Not in API, and it is really
redundant to have.
(installComponents): Changed the renderer set for the combo box.
Also, added the buttonPanel to the parentsPanel, so they are
always painted correctly. Set the FlowLayout to LEFT
instead of default being CENTER.

Index: javax/swing/plaf/basic/BasicFileChooserUI.java
===
RCS file: /cvsroot/classpath/classpath/javax/swing/plaf/basic/BasicFileChooserUI.java,v
retrieving revision 1.11
diff -u -r1.11 BasicFileChooserUI.java
--- javax/swing/plaf/basic/BasicFileChooserUI.java	14 Sep 2005 16:52:08 -	1.11
+++ javax/swing/plaf/basic/BasicFileChooserUI.java	15 Sep 2005 17:49:22 -
@@ -44,6 +44,7 @@
 import java.awt.Graphics;
 import java.awt.GridBagConstraints;
 import java.awt.GridBagLayout;
 import java.awt.Point;
 import java.awt.Polygon;
 import java.awt.Window;
@@ -945,7 +946,7 @@
   File currDir = null;
 
   JPanel bottomPanel;
-
+  
   /** DOCUMENT ME! */
   JPanel closePanel;
 
@@ -997,46 +998,6 @@
 }
   }
 
-  /**
-   * DOCUMENT ME!
-   */
-  public class CBLabelRenderer extends JLabel implements ListCellRenderer
-  {
-/**
- * Creates a new CBLabelRenderer object.
- */
-public CBLabelRenderer()
-{
-  super();
-  setOpaque(true);
-}
-
-/**
- * DOCUMENT ME!
- *
- * @param list DOCUMENT ME!
- * @param value DOCUMENT ME!
- * @param index DOCUMENT ME!
- * @param isSelected DOCUMENT ME!
- * @param cellHasFocus DOCUMENT ME!
- *
- * @return DOCUMENT ME!
- */
-public Component getListCellRendererComponent(JList list, Object value,
-  int index,
-  boolean isSelected,
-  boolean cellHasFocus)
-{
-  setHorizontalAlignment(SwingConstants.LEFT);
-  setIcon(directoryIcon);
-  setText(value.toString());
-  setForeground(Color.BLACK);
-  setBackground(Color.WHITE);
-
-  return this;
-}
-  }
-
   void closeDialog()
   {
 Window owner = SwingUtilities.windowForComponent(filechooser);
@@ -1210,7 +1171,7 @@
 JLabel look = new JLabel(Look In:);
 
 parents = new JComboBox();
-parents.setRenderer(new CBLabelRenderer());
+parents.setRenderer(new BasicComboBoxRenderer());
 boxEntries();
 look.setLabelFor(parents);
 JPanel parentsPanel = new JPanel();
@@ -1242,9 +1203,9 @@
 buttonPanel.add(detailsViewButton);
 
 JPanel topPanel = new JPanel();
-topPanel.setLayout(new java.awt.FlowLayout());
+parentsPanel.add(buttonPanel);
+topPanel.setLayout(new java.awt.FlowLayout(java.awt.FlowLayout.LEFT, 0, 0));
 topPanel.add(parentsPanel);
-topPanel.add(buttonPanel);
 
 accessoryPanel = new JPanel();
 if (filechooser.getAccessory() != null)
___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


[cp-patches] [RFC] ProgressMonitor implemented

2005-09-15 Thread Robert Schuster
Hi,
this patch implements the ProgressMonitor. I'll send a demo application to the
associated bug report[0].

2005-09-15  Robert Schuster  [EMAIL PROTECTED]

* javax/swing/ProgressMonitor: Implemented the former stubbed
class and added documentation.
(close): Implemented and added documentation.
(setProgress): Dito.
(isCanceled): Dito.
(setMinimum): Added documentation.
(getMinimum): Dito.
(setMaximum): Dito.
(getMaximum): Dito.
(setNote): Dito.
(getMillisToDecideToPopup): Dito.
(setMillisToDecideToPopup): Dito.
(getMillisToPopup): Dito.
(setMillisToPopup): Dito.
(getNote): Dito.

[0] - http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23850

cu
Robert
Index: javax/swing/ProgressMonitor.java
===
RCS file: /cvsroot/classpath/classpath/javax/swing/ProgressMonitor.java,v
retrieving revision 1.4
diff -u -r1.4 ProgressMonitor.java
--- javax/swing/ProgressMonitor.java	13 Sep 2005 09:17:21 -	1.4
+++ javax/swing/ProgressMonitor.java	15 Sep 2005 17:59:38 -
@@ -1,5 +1,5 @@
 /* ProgressMonitor.java --
-   Copyright (C) 2002, 2004 Free Software Foundation, Inc.
+   Copyright (C) 2002, 2004, 2005 Free Software Foundation, Inc.
 
 This file is part of GNU Classpath.
 
@@ -38,56 +38,74 @@
 package javax.swing;
 
 import java.awt.Component;
+import java.awt.event.ActionListener;
+import java.awt.event.ActionEvent;
 
 /**
- * ProgressMonitor
- * @author	Andrew Selkirk
- * @version	1.0
+ * pUsing this class you can easily monitor tasks where you cannot
+ * estimate the duration exactly./p 
+ *
+ * pA ProgressMonitor instance waits until the first time setProgress
+ * is called. When codemillisToDecideToPopup/code time elapsed the
+ * instance estimates the duration until the whole operation is completed.
+ * If this duration exceeds codemillisToPopup/code a non-modal dialog
+ * with a message and a progress bar is shown./p
+ *
+ * pThe value of codemillisToDecideToPopup/code defaults to
+ * code500/code and codemillisToPopup/code to
+ * code2000/code./p
+ *
+ * @author Andrew Selkirk
+ * @author Robert Schuster ([EMAIL PROTECTED])
+ * @since 1.2
+ * @status updated to 1.2
  */
 public class ProgressMonitor
 {
   /**
* parentComponent
*/
-  private Component component;
+  Component component;
 
   /**
* note
*/
-  private String note;
+  String note;
 
   /**
* message
*/
-  private Object message;
+  Object message;
 
   /**
* millisToDecideToPopup
*/
-  private int millisToDecideToPopup;
+  int millisToDecideToPopup = 500;
 
   /**
* millisToPopup
*/
-  private int millisToPopup;
+  int millisToPopup = 2000;
 
-  /**
-   * min
-   */
-  private int minimum;
+  int min, max, progress;
 
-  /**
-   * max
-   */
-  private int maximum;
+  JProgressBar progressBar;
+
+  JLabel noteLabel;
+
+  JDialog progressDialog;
+
+  Timer timer;
+
+  boolean canceled;
 
   /**
* Constructor ProgressMonitor
-   * @param component TODO
-   * @param message TODO
-   * @param note TODO
-   * @param minimum TODO
-   * @param maximum TODO
+   * @param component The parent component of the progress dialog or codenull/code.
+   * @param message A constant message object which works in the way it does in codeJOptionPane/code.
+   * @param note A string message which can be changed while the operation goes on.
+   * @param minimum The minimum value for the operation (start value).
+   * @param maximum The maximum value for the operation (end value).
*/
   public ProgressMonitor(Component component, Object message,
  String note, int minimum, int maximum)
@@ -97,93 +115,154 @@
 this.component = component;
 this.message = message;
 this.note = note;
-this.minimum = minimum;
-this.maximum = maximum;
 
-// TODO
+min = minimum;
+max = maximum;
   }
 
   /**
-   * close
+   * pHides the dialog and stops any measurements./p
+   *
+   * pHas no effect when codesetProgress/code is not at least
+   * called once./p
*/
   public void close()
   {
-// TODO
+if ( progressDialog != null )
+{
+  progressDialog.setVisible(false);
+}
+
+if ( timer != null )
+{
+  timer.stop();
+  timer = null;
+}
   }
 
   /**
-   * setProgress
-   * @param progress TODO
+   * pUpdates the progress value./p
+   *
+   * pWhen called for the first time this initializes a timer
+   * which decides after codemillisToDecideToPopup/code time
+   * whether to show a progress dialog or not./p
+   *
+   * pIf the progress value equals or exceeds the maximum
+   * value the progress dialog is closed automatically./p
+   *
+   * @param progress New progress value.
*/
   public void setProgress(int progress)
   {
-// TODO
+this.progress = progress;
+
+// Initializes and starts a timer with a task
+// which measures the duration and displays
+// a progress dialog if neccessary.
+if ( timer == null 

Re: [cp-patches] Patch: don't use integer division in color calculation

2005-09-15 Thread Tom Tromey
 Anthony == Anthony Green [EMAIL PROTECTED] writes:

Anthony 2005-09-14  Anthony Green  [EMAIL PROTECTED]
Anthony * java/awt/Color.java (RGBtoHSB): Don't use integer division when
Anthony calculating saturation.
Anthony * java/awt/Rectangle.java (equals): Explain why hashCode() isn't
Anthony required.
Anthony * java/awt/Point.java (equals): Ditto.

Ok, thanks.

Tom


___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


[cp-patches] Reformatted BasicInternalFrameUI

2005-09-15 Thread Anthony Balkissoon
I reformatted this file to match our coding style.

--Tony
Index: javax/swing/plaf/basic/BasicInternalFrameUI.java
===
RCS file: /cvsroot/classpath/classpath/javax/swing/plaf/basic/BasicInternalFrameUI.java,v
retrieving revision 1.16
diff -u -r1.16 BasicInternalFrameUI.java
--- javax/swing/plaf/basic/BasicInternalFrameUI.java	24 Aug 2005 09:00:32 -	1.16
+++ javax/swing/plaf/basic/BasicInternalFrameUI.java	15 Sep 2005 18:07:20 -
@@ -202,67 +202,66 @@
  */
 public void mouseDragged(MouseEvent e)
 {
-  // If the frame is maximized, there is nothing that 
+  // If the frame is maximized, there is nothing that
   // can be dragged around.
   if (frame.isMaximum())
-	return;
+return;
   DesktopManager dm = getDesktopManager();
   Rectangle b = frame.getBounds();
   Dimension min = frame.getMinimumSize();
   if (min == null)
-	min = new Dimension(0, 0);
+min = new Dimension(0, 0);
   Insets insets = frame.getInsets();
   int x = e.getX();
   int y = e.getY();
   if (e.getSource() == frame  frame.isResizable())
 {
-	  switch (direction)
-	{
-	case NORTH:
-	  cacheRect.setBounds(b.x,
-	  Math.min(b.y + y, b.y + b.height
-	   - min.height), b.width, b.height
-	  - y);
-	  break;
-	case NORTH_EAST:
-	  cacheRect.setBounds(b.x,
-	  Math.min(b.y + y, b.y + b.height
-	   - min.height), x, b.height - y);
-	  break;
-	case EAST:
-	  cacheRect.setBounds(b.x, b.y, x, b.height);
-	  break;
-	case SOUTH_EAST:
-	  cacheRect.setBounds(b.x, b.y, x, y);
-	  break;
-	case SOUTH:
-	  cacheRect.setBounds(b.x, b.y, b.width, y);
-	  break;
-	case SOUTH_WEST:
-	  cacheRect.setBounds(Math.min(b.x + x, b.x + b.width - min.width),
-	  b.y, b.width - x, y);
-	  break;
-	case WEST:
-	  cacheRect.setBounds(Math.min(b.x + x, b.x + b.width - min.width),
-	  b.y, b.width - x, b.height);
-	  break;
-	case NORTH_WEST:
-	  cacheRect.setBounds(Math.min(b.x + x, b.x + b.width - min.width),
-	  Math.min(b.y + y, b.y + b.height
-	   - min.height), b.width - x,
-	  b.height - y);
-	  break;
-	}
-	  dm.resizeFrame(frame, cacheRect.x, cacheRect.y,
-	 Math.max(min.width, cacheRect.width),
-	 Math.max(min.height, cacheRect.height));
+  switch (direction)
+{
+case NORTH:
+  cacheRect.setBounds(b.x, Math.min(b.y + y, b.y + b.height
+ - min.height),
+  b.width, b.height - y);
+  break;
+case NORTH_EAST:
+  cacheRect.setBounds(b.x, Math.min(b.y + y, b.y + b.height
+ - min.height), x,
+  b.height - y);
+  break;
+case EAST:
+  cacheRect.setBounds(b.x, b.y, x, b.height);
+  break;
+case SOUTH_EAST:
+  cacheRect.setBounds(b.x, b.y, x, y);
+  break;
+case SOUTH:
+  cacheRect.setBounds(b.x, b.y, b.width, y);
+  break;
+case SOUTH_WEST:
+  cacheRect.setBounds(Math.min(b.x + x, b.x + b.width - min.width),
+  b.y, b.width - x, y);
+  break;
+case WEST:
+  cacheRect.setBounds(Math.min(b.x + x, b.x + b.width - min.width),
+  b.y, b.width - x, b.height);
+  break;
+case NORTH_WEST:
+  cacheRect.setBounds(
+  Math.min(b.x + x, b.x + b.width - min.width),
+  Math.min(b.y + y, b.y + b.height - min.height),
+  b.width - x, b.height - y);
+  break;
+}
+  dm.resizeFrame(frame, cacheRect.x, cacheRect.y,
+ Math.max(min.width, cacheRect.width),
+ Math.max(min.height, cacheRect.height));
 }
   else if (e.getSource() == titlePane)
 {
-	  Rectangle fBounds = frame.getBounds();
+  Rectangle fBounds = frame.getBounds();
 
-	  dm.dragFrame(frame, e.getX() - xOffset + b.x,
-	   e.getY() - yOffset + b.y);
+  dm.dragFrame(frame, e.getX() - xOffset + b.x, e.getY() - yOffset
++ b.y);
 }
 }
 
@@ -304,17 +303,17 @@
 
   if (e.getSource() == frame  frame.isResizable())
 {
-	  direction = sectionOfClick(x, y);
-	  

Re: [cp-patches] Patch: minor ZipFile improvement

2005-09-15 Thread Tom Tromey
 Anthony == Anthony Green [EMAIL PROTECTED] writes:

Anthony 2005-09-14  Anthony Green  [EMAIL PROTECTED]
Anthony * java/util/zip/ZipFile.java (checkZipFile): Make sure we read all
Anthony 4 bytes of the magic number.

Looks reasonable to me.
I wonder if there are other instances of us not reading fully here.

Tom


___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


Re: [cp-patches] FYI: Component.isDisplayable fixlet and Window method removal

2005-09-15 Thread Roman Kennke
Am Donnerstag, den 15.09.2005, 13:42 -0400 schrieb Thomas Fitzsimmons:
 On Thu, 2005-09-15 at 12:50 -0400, Anthony Balkissoon wrote:
  Component.isDisplayable should return true if peer != null.  Window no
  longer needs to override this method (and it doesn't, according to the
  API), so I removed the method from Window.java.  Patch attached.
 
 Window overrides isDisplayable specifically because
 Window.isDisplayable's return value should *not* depend on its parents
 displayability.

Sorry, maybe I misunderstand something here, but are there Windows that
have a non-null parent?

Also, wouldn't it be sufficent to check if a component has a peer? The
API docs are a little bit confusing, but that is what it sounds to me. 

Ok, the effect of Tony's patch is exactly that, that a component is
displayable if the top-level component has a peer. I think Tony is right
here. But as always, I would recommend writing testcases to clear up the
situation (I really have become a fan of mauve).

/Roman



signature.asc
Description: This is a digitally signed message part
___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


[cp-patches] FYI: JInternalFrame - fix for icons in title pane

2005-09-15 Thread David Gilbert
I committed this patch which fixes the clipping of the icons in the title pane of 
JInternalFrame components under the MetalLookAndFeel.  The main problem was that the 
Action objects used  for the 'Name' property - the buttons used this for the text, 
which messed up the icon alignment.  I've fixed the names in the Action objects, and 
set the button text to null explicitly:


2005-09-15  David Gilbert  [EMAIL PROTECTED]

* javax/swing/SwingUtilities.java
(layoutCompoundLabel): check for empty text string,
* javax/swing/plaf/basic/BasicButtonUI.java
(paint): check isBorderPainted() when calculating view rect,
* javax/swing/plaf/basic/BasicInternalFrameTitlePane.java
(CloseAction): new constructor,
(IconifyAction): new constructor,
(MaximizeAction): new constructor,
(MoveAction): new constructor,
(RestoreAction): new constructor,
(SizeAction): new constructor,
(TitlePaneLayout.layoutContainer): calculate button widths from icon
widths,
(installDefaults): initialise icon fields,
(uninstallDefaults): clear icon fields,
(createButtons): set button text to null,
(setButtonIcons): use icon fields.

Regards,

Dave

Index: javax/swing/SwingUtilities.java
===
RCS file: /cvsroot/classpath/classpath/javax/swing/SwingUtilities.java,v
retrieving revision 1.34
diff -u -r1.34 SwingUtilities.java
--- javax/swing/SwingUtilities.java 22 Aug 2005 11:07:02 -  1.34
+++ javax/swing/SwingUtilities.java 15 Sep 2005 20:22:10 -
@@ -840,7 +840,7 @@
 iconR.width = icon.getIconWidth();
 iconR.height = icon.getIconHeight();
   }
-if (text == null)
+if (text == null || text.equals())
   {
 textIconGap = 0;
textR.width = 0;
Index: javax/swing/plaf/basic/BasicButtonUI.java
===
RCS file: 
/cvsroot/classpath/classpath/javax/swing/plaf/basic/BasicButtonUI.java,v
retrieving revision 1.25
diff -u -r1.25 BasicButtonUI.java
--- javax/swing/plaf/basic/BasicButtonUI.java   15 Sep 2005 13:19:09 -  
1.25
+++ javax/swing/plaf/basic/BasicButtonUI.java   15 Sep 2005 20:22:11 -
@@ -268,7 +268,10 @@
 
 g.setFont(f);
 
-SwingUtilities.calculateInnerArea(b, vr);
+if (b.isBorderPainted())
+  SwingUtilities.calculateInnerArea(b, vr);
+else
+  vr = SwingUtilities.getLocalBounds(b);
 String text = SwingUtilities.layoutCompoundLabel(c, g.getFontMetrics(f), 
  b.getText(),
  currentIcon(b),
Index: javax/swing/plaf/basic/BasicInternalFrameTitlePane.java
===
RCS file: 
/cvsroot/classpath/classpath/javax/swing/plaf/basic/BasicInternalFrameTitlePane.java,v
retrieving revision 1.14
diff -u -r1.14 BasicInternalFrameTitlePane.java
--- javax/swing/plaf/basic/BasicInternalFrameTitlePane.java 12 Sep 2005 
23:04:55 -  1.14
+++ javax/swing/plaf/basic/BasicInternalFrameTitlePane.java 15 Sep 2005 
20:22:12 -
@@ -84,6 +84,14 @@
   public class CloseAction extends AbstractAction
   {
 /**
+ * Creates a new action.
+ */
+public CloseAction()
+{
+  super(Close);
+}
+
+/**
  * This method is called when something closes the JInternalFrame.
  *
  * @param e The ActionEvent.
@@ -113,6 +121,14 @@
   public class IconifyAction extends AbstractAction
   {
 /**
+ * Creates a new action.
+ */
+public IconifyAction()
+{
+  super(Minimize);
+}
+
+/**
  * This method is called when the user wants to iconify the
  * JInternalFrame.
  *
@@ -143,6 +159,13 @@
   public class MaximizeAction extends AbstractAction
   {
 /**
+ * Creates a new action.
+ */
+public MaximizeAction()
+{
+  super(Maximize);
+}
+/**
  * This method is called when the user wants to maximize the
  * JInternalFrame.
  *
@@ -173,6 +196,13 @@
   public class MoveAction extends AbstractAction
   {
 /**
+ * Creates a new action.
+ */
+public MoveAction()
+{
+  super(Move);
+}
+/**
  * This method is called when the user wants to drag the JInternalFrame.
  *
  * @param e The ActionEvent.
@@ -194,6 +224,13 @@
   public class RestoreAction extends AbstractAction
   {
 /**
+ * Creates a new action.
+ */
+public RestoreAction()
+{
+  super(Restore);
+}
+/**
  * This method is called when the user wants to restore the
  * JInternalFrame.
  *
@@ -224,6 +261,13 @@
   public class SizeAction extends AbstractAction
   {
 /**
+ * Creates a new action.
+ */
+public SizeAction()
+{
+  super(Size);
+}
+/**
  * This method is called 

Re: [cp-patches] FYI: Component.isDisplayable fixlet and Window method removal

2005-09-15 Thread Thomas Fitzsimmons
On Thu, 2005-09-15 at 16:16 -0400, Anthony Balkissoon wrote:
 On Thu, 2005-09-15 at 14:53 -0400, Thomas Fitzsimmons wrote: 
  On Thu, 2005-09-15 at 20:48 +0200, Roman Kennke wrote:
   Also, wouldn't it be sufficent to check if a component has a peer? The
   API docs are a little bit confusing, but that is what it sounds to me.
  
  You mean rather than climbing the parent ladder?  Whether or not a
  Component is displayable depends on the displayability of its parents.
  Whether or not a Window is displayable doesn't.
  
 
 The docs actually say that a Component is displayable when it is
 attached to a native screen resource.  It is _made_ displayable when it
 is added to a displayable hierarchy or when it's hierarchy is made
 displayable.  These actions (adding to displayable hierarchy or making
 hierarchy displayable) attach a native resource to the Component.  So I
 believe Component should simply return (peer != null).  I tested this
 and it passes the Mauve tests.

Please submit tests for all these assertions to Mauve, and run them on
Sun.  If they all pass on both Sun and ours with this patch, then you
can commit it.  Feel free to add to the existing isDisplayable tests.

It would also be nice to clarify our javadocs on the matter now that
we've figured it out (including a comment like this reduces to checking
that peer != null).

Tom




___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


[cp-patches] Patch: FYI: Name -vs- 1.5

2005-09-15 Thread Tom Tromey
I'm checking this in.

In 1.5, javax.naming.Name is Comparable.
It already declares compareTo in 1.4, so this does not affect source
or binary compatibility.

Tom

Index: ChangeLog
from  Tom Tromey  [EMAIL PROTECTED]

* javax/naming/Name.java: Extends Comparable.

Index: javax/naming/Name.java
===
RCS file: /cvsroot/classpath/classpath/javax/naming/Name.java,v
retrieving revision 1.6
diff -u -r1.6 Name.java
--- javax/naming/Name.java 2 Jul 2005 20:32:45 - 1.6
+++ javax/naming/Name.java 15 Sep 2005 23:08:24 -
@@ -1,5 +1,5 @@
 /* Name.java -- Name build up from different components
-   Copyright (C) 2000, 2001, 2004 Free Software Foundation, Inc.
+   Copyright (C) 2000, 2001, 2004, 2005 Free Software Foundation, Inc.
 
 This file is part of GNU Classpath.
 
@@ -60,7 +60,7 @@
  * @author Anthony Green ([EMAIL PROTECTED])
  * @author Mark Wielaard ([EMAIL PROTECTED])
  */
-public interface Name extends Cloneable, Serializable
+public interface Name extends Cloneable, Serializable, Comparable
 {
   long serialVersionUID = -3617482732056931635L;
 


___
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches


Re: 0.16 Screenshots

2005-09-15 Thread theUser BL

On Mon, 2005-09-12 at 10:49 +, theUser BL wrote:
 There are Screenhsots of 0.16 at
 http://rapidshare.de/files/4979682/cp15shots.zip.html

Thanks for all those screenshots!


and they are now at OSDir:

http://shots.osdir.com/slideshows/slideshow.php?release=435slide=1title=classpath+0.16+screenshots



In your README you say:

 This are screenshots of GNU Classpath 0.16.
 The actual version is 0.18.
 But I have not found any Java-like VM, which used 0.17 or 0.18 AND
 which I have become to run.
 And I think, if the first VM used Classpath 0.18, then Classpath 0.19
 or higher is out.
 So I used the last versions of SableVM and CacaoVM.
 Mostly SableVM 1.12. But if there is a program, which SableVM can't
 run, but CacaoVM 0.92 can, than I have used CacaoVM.

If you can use CVS then either classpath CVS + jamvm CVS (or jamvm 1.3.3
and classpath 0.18) or Kaffe CVS should give you a much more up to date
environment. And I promise you that some of the screenshots do indeed
look even nicer with the new GNU Classpath releases :)


I have tried JamVM and become an error by compiling. (see one of my other 
posting today here in the list).


I have tried IKVM 0.20.0.0 , which used GNU Classpath 0.18 and have made 
this screenshots:

ArcTest of the Sun-Apllet Demos:
http://www.theuserbl.ag.vu/sshot1z.png
As you can see, the Arc is not drawn.

And at
http://www.theuserbl.ag.vu/sshot3z.png
the Notepad-example by Sun direct after the start. If I move the mouse over 
the window, it shows much less of it. And it flickers.



For more about it, I want now to write in the posting GNU Classpath and 
JVMs



Greatings
theuserbl




___
Classpath mailing list
Classpath@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath


Re: JamVM 1.3.3 released

2005-09-15 Thread theUser BL

I have tested it - to compile - and become errors.

At first I tried this:

[EMAIL PROTECTED]:~/z/jamvm-1.3.3 ./configure --prefix=$HOME/jamvm
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
[...]
checking for inflate in -lz... yes
checking for ffi_call in -lffi... no
configure: error: cannot find libffi
[EMAIL PROTECTED]:~/z/jamvm-1.3.3

After that Error I tried to set LD_LIBRARY_PATH to the path where my 
compiled libffi is. But it don't helped. There comes the same error, that it 
wasn't found. So I have given in:


[EMAIL PROTECTED]:~/z/jamvm-1.3.3 ./configure --prefix=$HOME/jamvm 
-disable-ffi

checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for gawk... gawk
[...]
config.status: creating lib/gnu/classpath/Makefile
config.status: linking ./src/arch/x86_64.h to src/arch.h
config.status: executing depfiles commands
[EMAIL PROTECTED]:~/z/jamvm-1.3.3

That works.
But if I tried to compile it:

[EMAIL PROTECTED]:~/z/jamvm-1.3.3 make
Making all in src
make[1]: Entering directory `/home/patrick/z/jamvm-1.3.3/src'
Making all in os
make[2]: Entering directory `/home/patrick/z/jamvm-1.3.3/src/os'
Making all in linux
[...]
gcc -DPACKAGE_NAME=\\ -DPACKAGE_TARNAME=\\ -DPACKAGE_VERSION=\\ 
-DPACKAGE_STRING=\\ -DPACKAGE_BUGREPORT=\\ -DPACKAGE=\jamvm\ 
-DVERSION=\1.3.3\ -DTHREADED=1 -DDIRECT=1 -DUSE_CACHE=1 
-DHAVE_LIBPTHREAD=1 -DHAVE_LIBM=1 -DHAVE_LIBDL=1 -DHAVE_LIBZ=1 
-DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 
-DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 
-DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DUSE_ZIP=1 -DHAVE_SYS_TIME_H=1 
-DHAVE_UNISTD_H=1 -DHAVE_ENDIAN_H=1 -DHAVE_SYS_PARAM_H=1 -DHAVE_LOCALE_H=1 
-DTIME_WITH_SYS_TIME=1 -DHAVE_ALLOCA_H=1 -DHAVE_ALLOCA=1 -DHAVE_STDLIB_H=1 
-DHAVE_UNISTD_H=1 -DHAVE_GETPAGESIZE=1 -DHAVE_MMAP=1 -DHAVE_GETTIMEOFDAY=1 
-DHAVE_STRTOL=1 -DHAVE_SETLOCALE=1 -DHAVE_LC_MESSAGES=1  -I. -I.  
-DINSTALL_DIR=\/home/patrick/jamvm\ 
-DCLASSPATH_INSTALL_DIR=\/usr/local/classpath\   -g -O2 -c `test -f 
'direct.c' || echo './'`direct.c

source='dll_ffi.c' object='dll_ffi.o' libtool=no \
depfile='.deps/dll_ffi.Po' tmpdepfile='.deps/dll_ffi.TPo' \
depmode=gcc3 /bin/sh ../depcomp \
gcc -DPACKAGE_NAME=\\ -DPACKAGE_TARNAME=\\ -DPACKAGE_VERSION=\\ 
-DPACKAGE_STRING=\\ -DPACKAGE_BUGREPORT=\\ -DPACKAGE=\jamvm\ 
-DVERSION=\1.3.3\ -DTHREADED=1 -DDIRECT=1 -DUSE_CACHE=1 
-DHAVE_LIBPTHREAD=1 -DHAVE_LIBM=1 -DHAVE_LIBDL=1 -DHAVE_LIBZ=1 
-DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 
-DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 
-DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DUSE_ZIP=1 -DHAVE_SYS_TIME_H=1 
-DHAVE_UNISTD_H=1 -DHAVE_ENDIAN_H=1 -DHAVE_SYS_PARAM_H=1 -DHAVE_LOCALE_H=1 
-DTIME_WITH_SYS_TIME=1 -DHAVE_ALLOCA_H=1 -DHAVE_ALLOCA=1 -DHAVE_STDLIB_H=1 
-DHAVE_UNISTD_H=1 -DHAVE_GETPAGESIZE=1 -DHAVE_MMAP=1 -DHAVE_GETTIMEOFDAY=1 
-DHAVE_STRTOL=1 -DHAVE_SETLOCALE=1 -DHAVE_LC_MESSAGES=1  -I. -I.  
-DINSTALL_DIR=\/home/patrick/jamvm\ 
-DCLASSPATH_INSTALL_DIR=\/usr/local/classpath\   -g -O2 -c `test -f 
'dll_ffi.c' || echo './'`dll_ffi.c
gcc  -g -O2   -o jamvm  alloc.o cast.o class.o dll.o excep.o execute.o 
hash.o interp.o jam.o jni.o lock.o natives.o reflect.o resolve.o string.o 
thread.o utf8.o zip.o properties.o direct.o dll_ffi.o 
os/linux/x86_64/libnative.a os/linux/libos.a -lz -ldl -lm -lpthread

dll.o(.text+0x8e): In function `callJNIWrapper':
/home/patrick/z/jamvm-1.3.3/src/dll.c:322: undefined reference to 
`callJNIMethod'

dll.o(.text+0x809): In function `lookupLoadedDlls':
/home/patrick/z/jamvm-1.3.3/src/dll.c:350: undefined reference to 
`nativeExtraArg'

collect2: ld returned 1 exit status
make[2]: *** [jamvm] Fehler 1
make[2]: Leaving directory `/home/patrick/z/jamvm-1.3.3/src'
make[1]: *** [all-recursive] Fehler 1
make[1]: Leaving directory `/home/patrick/z/jamvm-1.3.3/src'
make: *** [all-recursive] Fehler 1
[EMAIL PROTECTED]:~/z/jamvm-1.3.3


I have also used later an other compiler and have written make clean, 
make.

But the error is everytime the same.

The reason, why I have written it here in Classpath and not only to Robert, 
I will write in a later posting called GNU Classpath and JVMs.



Greatings
theuserbl




___
Classpath mailing list
Classpath@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath


GNU Classpath and JVMs

2005-09-15 Thread theUser BL

Hi!

What me everytime wonder is, that GNU Classpath have not its own VM.

To show the situation so, like I see it:
Suns Java comes as a complete package, which includes the Classes _and_ the 
JVM.
Mono comes as a complete package, which includes the .net-classes and the 
mono-runtime.


Only with GNU Classpath it looks a little bit different.

At first the developer changed the GNU Classpath code on any JVM, so that is 
no longer compatible to the old one.
So, when a new GNU Classpath version is released, there existing at first, 
no JVMs on which it can run.


After the release, the first JVMs are using the new Classpath version in its 
CVS. And later some using the new one. And some are being on older one 
(GCC-20050909 used still 0.17; SableVM used still 0.16 in CVS)


From the new versions, which use 0.17 or 0.18, I can either not compile it 

or it (like JamVM), or it have problems with AWT and Swing (IKVM).
And a CVS-version of Kaffe I have not tried. But Kaffe 1.1.5 don't run Swing 
programs on my computer.


So I asked myself, what JVM does the GNU Classpath developer use?
They can not use a JVM, which still have a old version of GNU Classpath 
(like SableVM or Gcj).


And I don't understand, why GNU Classpath comes not with its own JVM.
Other JVMs can then always later bringing GNU Classpath to its own JVM.
But at first it need a JVM as basis.

And it is not so, that GNU Classpath includes only the platformindependent 
parts.
The native libs like gtkpeers.so are existing, too. Why not then additionaly 
having the own JVM, which is then the standard JVM for GNU Classpath?



Greatings
theuserbl




___
Classpath mailing list
Classpath@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath


Re: GNU Classpath and JVMs

2005-09-15 Thread Andrew Haley
theUser BL writes:
  
  What me everytime wonder is, that GNU Classpath have not its own VM.
  
  To show the situation so, like I see it:
  Suns Java comes as a complete package, which includes the Classes _and_ the 
  JVM.
  Mono comes as a complete package, which includes the .net-classes and the 
  mono-runtime.
  
  Only with GNU Classpath it looks a little bit different.
  
  At first the developer changed the GNU Classpath code on any JVM, so that is 
  no longer compatible to the old one.
  So, when a new GNU Classpath version is released, there existing at first, 
  no JVMs on which it can run.
  
  After the release, the first JVMs are using the new Classpath version in its 
  CVS. And later some using the new one. And some are being on older one 
  (GCC-20050909 used still 0.17; SableVM used still 0.16 in CVS)
  
  From the new versions, which use 0.17 or 0.18, I can either not compile it 
  or it (like JamVM), or it have problems with AWT and Swing (IKVM).
  And a CVS-version of Kaffe I have not tried. But Kaffe 1.1.5 don't run Swing 
  programs on my computer.
  
  So I asked myself, what JVM does the GNU Classpath developer use?
  They can not use a JVM, which still have a old version of GNU Classpath 
  (like SableVM or Gcj).

gcj doesn't have an old version of Classpath; it's been changed so
that it comes with a recent tested version, and you can drop Classpath
CVS in if you wish.

  And I don't understand, why GNU Classpath comes not with its own JVM.

You're missing the whole idea of Classpath, which is to provide a set
of class libraries for free VMs.  In this regard it is no different
from glibc, which is a C library, not a C compiler.

  Other JVMs can then always later bringing GNU Classpath to its own JVM.
  But at first it need a JVM as basis.
  
  And it is not so, that GNU Classpath includes only the platformindependent 
  parts.
  The native libs like gtkpeers.so are existing, too. Why not then additionaly 
  having the own JVM, which is then the standard JVM for GNU Classpath?

Keeping a clean separation between VM and library is a good idea.  The
problem that we are all trying to solve is to make sure that Classpath
runs out of the box on the free VMs.  We're getting there.

Andrew.


___
Classpath mailing list
Classpath@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath


Re: JamVM 1.3.3 released

2005-09-15 Thread Robert Lougher
Hi,

The problem is you're trying to build on AMD64.  This is the only
platform which needs libffi.  On my AMD64 system I've installed libffi
from the distribution, and configure has no problems in finding this.

From your message you've compiled libffi yourself.  I guess it's in a
non-standard place and so configure can't find it.  I've no idea how
to make configure find it, beyond putting it where configure expects.

Disabling libffi with --disable-ffi won't work because AMD64 requires
it (and it's the only platform which has it enabled by default).  I
will make configure bomb out on AMD64 in this case.

Anybody know how to get configure to find it?  If not, I'll look at it tonight.

Rob.

On 9/15/05, theUser BL [EMAIL PROTECTED] wrote:
 I have tested it - to compile - and become errors.
 
 At first I tried this:
 
 [EMAIL PROTECTED]:~/z/jamvm-1.3.3 ./configure --prefix=$HOME/jamvm
 checking for a BSD-compatible install... /usr/bin/install -c
 checking whether build environment is sane... yes
 checking for gawk... gawk
 checking whether make sets $(MAKE)... yes
 [...]
 checking for inflate in -lz... yes
 checking for ffi_call in -lffi... no
 configure: error: cannot find libffi
 [EMAIL PROTECTED]:~/z/jamvm-1.3.3
 
 After that Error I tried to set LD_LIBRARY_PATH to the path where my
 compiled libffi is. But it don't helped. There comes the same error, that it
 wasn't found. So I have given in:
 
 [EMAIL PROTECTED]:~/z/jamvm-1.3.3 ./configure --prefix=$HOME/jamvm
 -disable-ffi
 checking for a BSD-compatible install... /usr/bin/install -c
 checking whether build environment is sane... yes
 checking for gawk... gawk
 [...]
 config.status: creating lib/gnu/classpath/Makefile
 config.status: linking ./src/arch/x86_64.h to src/arch.h
 config.status: executing depfiles commands
 [EMAIL PROTECTED]:~/z/jamvm-1.3.3
 
 That works.
 But if I tried to compile it:
 
 [EMAIL PROTECTED]:~/z/jamvm-1.3.3 make
 Making all in src
 make[1]: Entering directory `/home/patrick/z/jamvm-1.3.3/src'
 Making all in os
 make[2]: Entering directory `/home/patrick/z/jamvm-1.3.3/src/os'
 Making all in linux
 [...]
 gcc -DPACKAGE_NAME=\\ -DPACKAGE_TARNAME=\\ -DPACKAGE_VERSION=\\
 -DPACKAGE_STRING=\\ -DPACKAGE_BUGREPORT=\\ -DPACKAGE=\jamvm\
 -DVERSION=\1.3.3\ -DTHREADED=1 -DDIRECT=1 -DUSE_CACHE=1
 -DHAVE_LIBPTHREAD=1 -DHAVE_LIBM=1 -DHAVE_LIBDL=1 -DHAVE_LIBZ=1
 -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1
 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1
 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DUSE_ZIP=1 -DHAVE_SYS_TIME_H=1
 -DHAVE_UNISTD_H=1 -DHAVE_ENDIAN_H=1 -DHAVE_SYS_PARAM_H=1 -DHAVE_LOCALE_H=1
 -DTIME_WITH_SYS_TIME=1 -DHAVE_ALLOCA_H=1 -DHAVE_ALLOCA=1 -DHAVE_STDLIB_H=1
 -DHAVE_UNISTD_H=1 -DHAVE_GETPAGESIZE=1 -DHAVE_MMAP=1 -DHAVE_GETTIMEOFDAY=1
 -DHAVE_STRTOL=1 -DHAVE_SETLOCALE=1 -DHAVE_LC_MESSAGES=1  -I. -I.
 -DINSTALL_DIR=\/home/patrick/jamvm\
 -DCLASSPATH_INSTALL_DIR=\/usr/local/classpath\   -g -O2 -c `test -f
 'direct.c' || echo './'`direct.c
 source='dll_ffi.c' object='dll_ffi.o' libtool=no \
 depfile='.deps/dll_ffi.Po' tmpdepfile='.deps/dll_ffi.TPo' \
 depmode=gcc3 /bin/sh ../depcomp \
 gcc -DPACKAGE_NAME=\\ -DPACKAGE_TARNAME=\\ -DPACKAGE_VERSION=\\
 -DPACKAGE_STRING=\\ -DPACKAGE_BUGREPORT=\\ -DPACKAGE=\jamvm\
 -DVERSION=\1.3.3\ -DTHREADED=1 -DDIRECT=1 -DUSE_CACHE=1
 -DHAVE_LIBPTHREAD=1 -DHAVE_LIBM=1 -DHAVE_LIBDL=1 -DHAVE_LIBZ=1
 -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1
 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1
 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DUSE_ZIP=1 -DHAVE_SYS_TIME_H=1
 -DHAVE_UNISTD_H=1 -DHAVE_ENDIAN_H=1 -DHAVE_SYS_PARAM_H=1 -DHAVE_LOCALE_H=1
 -DTIME_WITH_SYS_TIME=1 -DHAVE_ALLOCA_H=1 -DHAVE_ALLOCA=1 -DHAVE_STDLIB_H=1
 -DHAVE_UNISTD_H=1 -DHAVE_GETPAGESIZE=1 -DHAVE_MMAP=1 -DHAVE_GETTIMEOFDAY=1
 -DHAVE_STRTOL=1 -DHAVE_SETLOCALE=1 -DHAVE_LC_MESSAGES=1  -I. -I.
 -DINSTALL_DIR=\/home/patrick/jamvm\
 -DCLASSPATH_INSTALL_DIR=\/usr/local/classpath\   -g -O2 -c `test -f
 'dll_ffi.c' || echo './'`dll_ffi.c
 gcc  -g -O2   -o jamvm  alloc.o cast.o class.o dll.o excep.o execute.o
 hash.o interp.o jam.o jni.o lock.o natives.o reflect.o resolve.o string.o
 thread.o utf8.o zip.o properties.o direct.o dll_ffi.o
 os/linux/x86_64/libnative.a os/linux/libos.a -lz -ldl -lm -lpthread
 dll.o(.text+0x8e): In function `callJNIWrapper':
 /home/patrick/z/jamvm-1.3.3/src/dll.c:322: undefined reference to
 `callJNIMethod'
 dll.o(.text+0x809): In function `lookupLoadedDlls':
 /home/patrick/z/jamvm-1.3.3/src/dll.c:350: undefined reference to
 `nativeExtraArg'
 collect2: ld returned 1 exit status
 make[2]: *** [jamvm] Fehler 1
 make[2]: Leaving directory `/home/patrick/z/jamvm-1.3.3/src'
 make[1]: *** [all-recursive] Fehler 1
 make[1]: Leaving directory `/home/patrick/z/jamvm-1.3.3/src'
 make: *** [all-recursive] Fehler 1
 [EMAIL PROTECTED]:~/z/jamvm-1.3.3
 
 
 I have also used 

Re: GNU Classpath and JVMs

2005-09-15 Thread Robert Lougher
Hi,

 From the new versions, which use 0.17 or 0.18, I can either not compile it
 or it (like JamVM), or it have problems with AWT and Swing (IKVM).
 And a CVS-version of Kaffe I have not tried. But Kaffe 1.1.5 don't run Swing
 programs on my computer.
 

JamVM _does_ work with Classpath-0.18.  The latest version is usually
at most broken for a couple of days whever a new snapshot of Classpath
is made.  You can now also get JamVM from CVS, and I intend to ensure
that this is current with Classpath CVS.  So when a new Classpath
snapshot is made, the CVS version of JamVM should work, even if the
latest released version doesn't (which was the case last week).

In your case the problem is a configuration issue on your machine
regarding libffi which is stopping JamVM building.

Rob.


___
Classpath mailing list
Classpath@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath


Re: GNU Classpath and JVMs

2005-09-15 Thread Robert Schuster
Hi.

theUser BL wrote:
 Hi!
 
 What me everytime wonder is, that GNU Classpath have not its own VM.
Theoretically every Java replacement package should develop a VM, tools and a
class library.
However it quickly turned out that there is a lot of stuff which can be shared
between the
projects. One of them is the huge class library and the helper tools
(appletviewer, javadoc, serialver, rmic, ...)

 To show the situation so, like I see it:
 Suns Java comes as a complete package, which includes the Classes _and_
 the JVM.
 Mono comes as a complete package, which includes the .net-classes and
 the mono-runtime.
SableVM, Kaffe (= 1.1.6) and a few other VMs work in the same way.
The difference is that they 'outsource' development of the library into
another project (GNU Classpath).

Isn't there some shared development work between DotGNU and Mono, too?

 Only with GNU Classpath it looks a little bit different.
 
 At first the developer changed the GNU Classpath code on any JVM, so
 that is no longer compatible to the old one.
 So, when a new GNU Classpath version is released, there existing at
 first, no JVMs on which it can run.
This depends entirely on the associated projects. JamVM for example is pretty
fast in always supporting the latest Classpath version out of the box.

 After the release, the first JVMs are using the new Classpath version in
 its CVS. And later some using the new one. And some are being on older
 one (GCC-20050909 used still 0.17; SableVM used still 0.16 in CVS)
GCJ does a lot of things differently and they need special versions of certain
core classes (String?). Nevertheless efforts are underway to unify development
as far as possible (At least, I hope so ;) ).

For SableVM the situation is similar. You may ask on the SableVM list for
further details.

 From the new versions, which use 0.17 or 0.18, I can either not
 compile it 
 
 or it (like JamVM), or it have problems with AWT and Swing (IKVM).
Please keep in mind that GNU Classpath is alpha quality software (see README)
and we cannot promise to *not* make VM-breaking changes between our release
snapshots. It is one of the long-term goals to reach a stable VM Interface API
(this is what causes most breakages) but currently this is not possible. As the
free VMs evolve new requirements are posed upon Classpath.

Especially the projects that leave the roads of traditional Java (I am speaking
of IKVM.NET and JNode here ...) environments stress the flexibility of this API
frequently. (Which is good because this will finally bring robustness.)

Btw: It is hardly predictable which new requirements the Apache Harmony project
may have for us ... :)

Only one thing is for sure: We want to support as many as possible JVM and JVM
look-alikes in the most elegant and efficient way.

 And a CVS-version of Kaffe I have not tried. But Kaffe 1.1.5 don't run
 Swing programs on my computer.
For a long long time Kaffe developed its own class library. These days Dalibor
is applying Classpath' patch flood into Kaffe's library to keep the projects in
sync.

However the long term goal for Kaffe is supporting Classpath out of the box,
too. But this needs some time because IMHO Dalibor is the only one working on 
this.

 So I asked myself, what JVM does the GNU Classpath developer use?
 They can not use a JVM, which still have a old version of GNU Classpath
 (like SableVM or Gcj).
I am pretty sure most of us use a tiny little spec-compliant VM that is
developed by Robert Lougher: JamVM

For me JamVM is ideal because it compiles in a short amount of time and is not
so complex (I am not a VM developer but was able to fix a few issues myself).

 And I don't understand, why GNU Classpath comes not with its own JVM.
 Other JVMs can then always later bringing GNU Classpath to its own JVM.
 But at first it need a JVM as basis.
GNU Classpath is in some aspects comparable to GNU libc. So while the glibc does
not has its 'own'* compiler and other Unix tools GNU Classpath does not have 
either.

However the GNU project has what you asking for:
Java VM: GCJ
Java library: Classpath
C compiler: GCC
C library: glibc

I hope this makes sense and the Classpath fellow have no major complains about
the way I see the things. :)

cu
Robert

* Ok, I just read that glibc is not really ported to different compilers.


___
Classpath mailing list
Classpath@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath


Re: GNU Classpath and JVMs

2005-09-15 Thread Dalibor Topic

theUser BL wrote:

Hi!

What me everytime wonder is, that GNU Classpath have not its own VM.


The FSF has gcj, actually. It is the 'GNU' runtime.


To show the situation so, like I see it:
Suns Java comes as a complete package, which includes the Classes _and_ 
the JVM.
Mono comes as a complete package, which includes the .net-classes and 
the mono-runtime.


Only with GNU Classpath it looks a little bit different.


That's the same as for the Linux kernel and GNU libc: one is an 
operating system core, the other one is a standard C library.


You can use the linux kernel with other C libraries, and you can use 
glibc with other kernels. They are, at the core, separate projects and 
separate tools for, I dare say, separate but often overlapping 
audiences, and nevertheless work very well together, and are both 
necessary for a distribution to deliver a GNU/Linux environment. ;)


BTW, Mono includes GNU Classpath as well, afair.

There are various projects that integrate various components into an 
equivalent of an out-of-the box environment for development and 
execution of applications useing GNU Classpath. java-gcj-compat does it 
around gcj, free-java-sdk in Debian does it around SableVM.


And of course, there is Kaffe, and probably other solutions I am not 
aware of yet.


At first the developer changed the GNU Classpath code on any JVM, so 
that is no longer compatible to the old one.
So, when a new GNU Classpath version is released, there existing at 
first, no JVMs on which it can run.


Yes. That's part of the necessity of being a work-in-progress, though: 
the VM interface is still in huge flux, and will be until GNU Classpath 
is finished. Since GNU Classpath is fortunately not tied to a single 
runtime, the VM interface is regularly improved upon to fix design 
decisions that cause problems on one runtime or another.


That obviously puts a price on some design decisions by the runtime 
developers: if they maintain their own copy of GNU Classpath, then they 
miss out on the latest features, but nothing breaks ;) If they go with 
CVS head, then they need to keep their VM up with the changes in the VM 
interface in close step. The simplest solution, afaict, is to go with 
the tested releases of GNU Classpath, and update your VM interface 
accordingly. That's what CACAO and JikesRVM do, afaik.


If that situation bothers you for a particular VM that you'd like to use 
with latest release of GNU Classpath, you can send patches to that VM 
development team and help that way. ;)



or it (like JamVM), or it have problems with AWT and Swing (IKVM).
And a CVS-version of Kaffe I have not tried. But Kaffe 1.1.5 don't run 
Swing programs on my computer.


Kaffe's CVS version is up to GNU Classpath CVS HEAD of 2005-09-14, GNU 
intetlib HEAD, etc. I try to keep it largely in sync with all the major 
upstreams, every couple of days. If you have a specific bug report for 
Kaffe's CVS head, try getting in touch with the Kaffe mailing list. If 
it's not a Kaffe crash, or something like that, your bug report may be 
better filed in the GNU Classpath bug database, though, since most of 
the class library development takes place here.



So I asked myself, what JVM does the GNU Classpath developer use?


Their own VMs CVS HEADS, or (a common favourite) JamVM (CVS HEAD). JamVM 
just got CVS access, btw, so you may want to give that a try, and hop on 
the respective mailing list.



And I don't understand, why GNU Classpath comes not with its own JVM.


For the same reason why GNU libc does not come with its own operating 
system core: it is not necessary. (Or similarly: why doesn't the Linux 
kernel come with KDE?). The primary target group of such projects are 
not end users, but other developers and integrators, who in turn, then 
repackage, modify, integrate the code into environments that are more 
suitable for end-users. What you run on your desktop is usually a fair 
shot away from the latest CVS head of the respective project. And 
usually way more stable, too, because of the work that went into 
testing, and integrating it. ;)


As people involved in packaging efforts on systems like Fedora and 
Debian can probably elaborate for a while, that part is also lots of 
work. Separating the concerns and responsibilities here has proven to 
work well in practice, as the blooming GNU/Linux ecosystem shows.


That all being said, if you want to write your own VM, and make sure it 
is kept up to date with GNU Classpath releases, more power to you. Feel 
free to fork Kaffe anytime, if you don't want to start from scratch.


cheers,
dalibor topic


___
Classpath mailing list
Classpath@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath


Re: GNU Classpath and JVMs

2005-09-15 Thread Dalibor Topic

Robert Schuster wrote:


And a CVS-version of Kaffe I have not tried. But Kaffe 1.1.5 don't run
Swing programs on my computer.


For a long long time Kaffe developed its own class library. These days Dalibor
is applying Classpath' patch flood into Kaffe's library to keep the projects in
sync.

However the long term goal for Kaffe is supporting Classpath out of the box,
too. But this needs some time because IMHO Dalibor is the only one working on 
this.


insert obligatory Volunteers! Volunteers! Volunteers! imitation of 
Steve Ballmer


Missing bits and pieces:
String (yay, same as gcj. May be really hard. ;)
java.lang.reflection (hard in a way, easy in a way. Hard since GNU 
Classpath has almost no code for it, so it'll be easy to merge in 
Kaffe's implementation. Volunteers!)
java.util.zip (easy to do by switching completely over, but then the 
performance is going to suffer extremely on the interpreter on slower 
CPUs. Otoh...less work for me, and more pressure on people to write/fix 
jits. Hmm... ;)


14 files in total, afaict. It may even be possible to use GNU Classpath 
out of the box now by playing around with -Xbootclasspath and 
-Djava.library.path,  but I have not tried it. Busy preparing the next 
release. ;)


cheers,
dalibor topic


___
Classpath mailing list
Classpath@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath


Re: GNU Classpath and JVMs

2005-09-15 Thread Stuart Ballard
On 9/15/05, Dalibor Topic [EMAIL PROTECTED] wrote:
 Missing bits and pieces:
 String (yay, same as gcj. May be really hard. ;)
 java.lang.reflection (hard in a way, easy in a way. Hard since GNU
 Classpath has almost no code for it, so it'll be easy to merge in
 Kaffe's implementation. Volunteers!)
 java.util.zip (easy to do by switching completely over, but then the
 performance is going to suffer extremely on the interpreter on slower
 CPUs. Otoh...less work for me, and more pressure on people to write/fix
 jits. Hmm... ;)

Makes me wonder, since the need to override certain files and/or
packages in Classpath for a particular VM is such a common scenario,
whether Classpath's build system shouldn't include native support for
this. Obviously this doesn't jive with the eventual goal of a single
glibj.zip shared between all runtimes, but until that point is
reached, it might save Dalibor in particular lots of work ;)

Wouldn't it be nice if there were a way to stick a kaffe.overrides
file somewhere which contained something like:

path ../whatever
class java.lang.String
package java.lang.reflect
package java.util.zip

Then you'd build classpath --with-overrides=path/to/kaffe.overrides
and it produces a glibj-kaffe.zip taking most of the sources from the
usual place but the String, reflect and zip sources from the
../whatever path instead.

I think gcj already has something like this, because since the Big
Merge they're actually using classpath in a subdirectory, but they
still need to override some classes. But it seems like something that
would be useful beyond gcj and kaffe and having each VM roll their own
solution to the same problem seems silly.

Unfortunately my build-system-fu is non-existant so I'd be completely
incapable of implementing this myself. Perhaps everyone already thinks
it's a good idea and the only reason it hasn't happened yet is
nobody's volunteered, in which case this mail was kind of pointless ;)

Thoughts?

Stuart.

-- 
http://sab39.dev.netreach.com/


___
Classpath mailing list
Classpath@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath


Re: GNU Classpath and JVMs

2005-09-15 Thread Meskauskas Audrius
GNU Classpath is a library. Depending on the needs of you project, 
significant part of it can be used as an alternative library for an 
arbitrary jre's. Many newer packages provide standard mechanism to 
plug-in the alternative implementation just by setting several system 
poperties to the alternative class names.


Audrius.




___
Classpath mailing list
Classpath@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath


Re: JamVM 1.3.3 released

2005-09-15 Thread Tom Tromey
 Robert == Robert Lougher [EMAIL PROTECTED] writes:

Robert Anybody know how to get configure to find it?  If not, I'll
Robert look at it tonight.

libffi isn't really separately released or installed.
Most packages just ship their own copy.  There was talk a while back
about doing releases again (now that more folks seem to be using it),
but nobody has done it yet.

Tom


___
Classpath mailing list
Classpath@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath


Re: GNU Classpath and JVMs

2005-09-15 Thread Tom Tromey
 Stuart == Stuart Ballard [EMAIL PROTECTED] writes:

Stuart Makes me wonder, since the need to override certain files and/or
Stuart packages in Classpath for a particular VM is such a common scenario,
Stuart whether Classpath's build system shouldn't include native support for
Stuart this.

Stuart I think gcj already has something like this, because since the Big
Stuart Merge they're actually using classpath in a subdirectory, but they
Stuart still need to override some classes. But it seems like something that
Stuart would be useful beyond gcj and kaffe and having each VM roll their own
Stuart solution to the same problem seems silly.

I added --with-vm-classes to solve this problem for the
classpath-in-libgcj build.  Basically by default we use the stuff in
vm/reference, but --with-vm-classes completely overrides this.  Then,
in addition, the enclosing build can override specific files (eg
String.java) with its own versions.

This is pretty much completely ad hoc, but, say, if kaffe were to
switch to this build model it ought to work fine there as well.  Hint,
hint.

Tom


___
Classpath mailing list
Classpath@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath


Re: JamVM 1.3.3 released

2005-09-15 Thread Tom Tromey
 Robert == Robert Lougher [EMAIL PROTECTED] writes:

Robert Ubuntu definately has a libffi-dev package, which I installed (header
Robert file).  So the lib I guess is part of gcc?

Yeah.  But in gcc it is built for libgcj as a convenience library.
Hmm, I guess it does actually install some files -- I didn't remember
that.  I suppose the RPMs leave these out though.

Tom


___
Classpath mailing list
Classpath@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath


Re: GNU Classpath and JVMs

2005-09-15 Thread Dalibor Topic
Tom Tromey wrote:
Stuart == Stuart Ballard [EMAIL PROTECTED] writes:
 
 
 Stuart Makes me wonder, since the need to override certain files and/or
 Stuart packages in Classpath for a particular VM is such a common scenario,
 Stuart whether Classpath's build system shouldn't include native support for
 Stuart this.
 
 Stuart I think gcj already has something like this, because since the Big
 Stuart Merge they're actually using classpath in a subdirectory, but they
 Stuart still need to override some classes. But it seems like something that
 Stuart would be useful beyond gcj and kaffe and having each VM roll their own
 Stuart solution to the same problem seems silly.
 
 I added --with-vm-classes to solve this problem for the
 classpath-in-libgcj build.  Basically by default we use the stuff in
 vm/reference, but --with-vm-classes completely overrides this.  Then,
 in addition, the enclosing build can override specific files (eg
 String.java) with its own versions.
 
 This is pretty much completely ad hoc, but, say, if kaffe were to
 switch to this build model it ought to work fine there as well.  Hint,
 hint.

Well, in true Kaffe fashion, I use to go with a suboptimal solution, and
then switch over to something better as soon as it's there, and ... your
gcj big merge is the way to go. I'm looking forward to grab your code
after 1.1.6 :)

cheers,
dalibor topic


___
Classpath mailing list
Classpath@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath


[Bug classpath/23863] mprec buffer overwrite bug

2005-09-15 Thread cvs-commit at developer dot classpath dot org

--- Additional Comments From cvs-commit at developer dot classpath dot org  
2005-09-15 17:14 ---
Subject: Bug 23863

CVSROOT:/cvsroot/classpath
Module name:classpath
Branch: 
Changes by: Tom Tromey [EMAIL PROTECTED]  05/09/15 17:10:29

Modified files:
.  : ChangeLog 
native/fdlibm  : mprec.h 

Log message:
Workaround for PR classpath/23863:
* native/fdlibm/mprec.h (MAX_BIGNUM_WDS): Define as 128 on
non-Pack_32 platforms.

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/ChangeLog.diff?tr1=1.4799tr2=1.4800r1=textr2=text
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/native/fdlibm/mprec.h.diff?tr1=1.4tr2=1.5r1=textr2=text






-- 


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


___
Bug-classpath mailing list
Bug-classpath@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-classpath


Re: GNU Classpath and JVMs

2005-09-15 Thread Dalibor Topic
Stuart Ballard wrote:
 Makes me wonder, since the need to override certain files and/or
 packages in Classpath for a particular VM is such a common scenario,
 whether Classpath's build system shouldn't include native support for
 this. Obviously this doesn't jive with the eventual goal of a single
 glibj.zip shared between all runtimes, but until that point is
 reached, it might save Dalibor in particular lots of work ;)

Actually, both goals are complementary, afaict. I mean, you can have a
single core class library shared betwen the runtimes, and some runtimes
overriding bits and pieces as they need it.

 Unfortunately my build-system-fu is non-existant so I'd be completely
 incapable of implementing this myself. Perhaps everyone already thinks
 it's a good idea and the only reason it hasn't happened yet is
 nobody's volunteered, in which case this mail was kind of pointless ;)

My plan is to emulate Tom, whenever I can :)

The idea would be after 1.1.6 to roll in the classpath check out into
Kaffe and then see how I need to tweak Kaffe's build system to deal with
it. It should not be that hard, it just hasn't been done until a few
weeks ago in gcj, and I wanted to see how it works out first. Breaking
Kaffe's build system is something I do regularly and with passion, but I
wanted to avoid it while I was dragging in bits and piecses for the next
release. Still a few patches to go there, but it's almost ready.

I'd also eventually like to merge in gcjx into kaffe, since the jikes
situation is detoriorating rapidly (crashes going unfixed) on odd
architectures, and I'd prefer to feed bug reports into a maintained
compiler :) I've written up how to build kaffe's class lib with gcjx,
and those writeups should also be gone, once it's all switched over :)

cheers,
dalibor topic


___
Classpath mailing list
Classpath@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath


Re: GNU Classpath and JVMs

2005-09-15 Thread Christian Thalinger
On Thu, 2005-09-15 at 16:51 +0200, Dalibor Topic wrote:
 Yes. That's part of the necessity of being a work-in-progress, though: 
 the VM interface is still in huge flux, and will be until GNU Classpath 
 is finished. Since GNU Classpath is fortunately not tied to a single 
 runtime, the VM interface is regularly improved upon to fix design 
 decisions that cause problems on one runtime or another.
 
 That obviously puts a price on some design decisions by the runtime 
 developers: if they maintain their own copy of GNU Classpath, then they 
 miss out on the latest features, but nothing breaks ;) If they go with 
 CVS head, then they need to keep their VM up with the changes in the VM 
 interface in close step. The simplest solution, afaict, is to go with 
 the tested releases of GNU Classpath, and update your VM interface 
 accordingly. That's what CACAO and JikesRVM do, afaik.

Exactly.  If the VM interface does not change (or only minor changes),
you can configure CACAO to use a external classpath installation (which
can be a CVS version or a newly realeased one), like it's done for
jamvm.  Just use the --with-external-classpath=cir configure switch.

TWISTI



___
Classpath mailing list
Classpath@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath


[Bug swing/23527] JMenu with shortcut/accelerator looks bad

2005-09-15 Thread pinskia at gcc dot gnu dot org


-- 
   What|Removed |Added

   Target Milestone|--- |0.19


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


___
Bug-classpath mailing list
Bug-classpath@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-classpath


[Bug swing/16540] GlassPane intercepting of MouseEvents flaky.

2005-09-15 Thread pinskia at gcc dot gnu dot org


-- 
   What|Removed |Added

   Target Milestone|--- |0.19


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


___
Bug-classpath mailing list
Bug-classpath@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-classpath


[Bug swing/22966] swing: JTextArea.setText() causes StringIndexOutOfBoundsException later

2005-09-15 Thread pinskia at gcc dot gnu dot org


-- 
   What|Removed |Added

   Target Milestone|--- |0.19


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


___
Bug-classpath mailing list
Bug-classpath@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-classpath


[Bug swing/23036] Swing: JFileChooser look-in-box problem

2005-09-15 Thread pinskia at gcc dot gnu dot org


-- 
   What|Removed |Added

   Target Milestone|--- |0.19


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


___
Bug-classpath mailing list
Bug-classpath@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-classpath


[commit-cp] classpath ./ChangeLog javax/swing/plaf/basic/Ba...

2005-09-15 Thread David Gilbert
CVSROOT:/cvsroot/classpath
Module name:classpath
Branch: 
Changes by: David Gilbert [EMAIL PROTECTED]   05/09/15 13:19:10

Modified files:
.  : ChangeLog 
javax/swing/plaf/basic: BasicButtonUI.java 
javax/swing/plaf/metal: MetalLookAndFeel.java 
MetalToggleButtonUI.java 

Log message:
2005-09-15  David Gilbert  [EMAIL PROTECTED]

* javax/swing/plaf/basic/BasicButtonUI.java
(installDefaults): set font,
(uninstallDefaults): clear font,
* javax/swing/plaf/metal/MetalLookAndFeel.java
(initComponentDefaults): update ToggleButton defaults,
* javax/swing/plaf/metal/MetalToggleButtonUI.java
(instance): removed field,
(createUI): just return new instance every time,
(MetalToggleButtonUI): look up defaults directly,
(getFocusColor): return value from field initialised in
constructor,
(getSelectColor): likewise,
(getDisabledTextColor): likewise,
(installDefaults): override to make public,
(paintButtonPressed): implemented,
(paintText): implemented,
(paintFocus): implemented.

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/ChangeLog.diff?tr1=1.4792tr2=1.4793r1=textr2=text
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/javax/swing/plaf/basic/BasicButtonUI.java.diff?tr1=1.24tr2=1.25r1=textr2=text
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/javax/swing/plaf/metal/MetalLookAndFeel.java.diff?tr1=1.55tr2=1.56r1=textr2=text
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/javax/swing/plaf/metal/MetalToggleButtonUI.java.diff?tr1=1.3tr2=1.4r1=textr2=text





[commit-cp] classpath ./ChangeLog javax/swing/JOptionPane.j...

2005-09-15 Thread Lillian Angel
CVSROOT:/cvsroot/classpath
Module name:classpath
Branch: 
Changes by: Lillian Angel [EMAIL PROTECTED]   05/09/15 14:03:36

Modified files:
.  : ChangeLog 
javax/swing: JOptionPane.java 
javax/swing/plaf/basic: BasicOptionPaneUI.java 

Log message:
2005-09-15  Lillian Angel  [EMAIL PROTECTED]

Fixes #23873
* javax/swing/plaf/basic/BasicOptionPaneUI.java
(createMessageArea): Changed orientation of message from EAST to
CENTER. Also, fixed empty border values to make message more centered.
* javax/swing/JOptionPane.java
(showConfirmDialog): Added check for pane.getValue, since clicking on
'x' of window does not have an initialized value. Was causing a
ClassCastException.
(showConfirmDialog): Likewise.
(showConfirmDialog): Likewise.
(showConfirmDialog): Likewise.

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/ChangeLog.diff?tr1=1.4793tr2=1.4794r1=textr2=text
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/javax/swing/JOptionPane.java.diff?tr1=1.16tr2=1.17r1=textr2=text
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/javax/swing/plaf/basic/BasicOptionPaneUI.java.diff?tr1=1.22tr2=1.23r1=textr2=text





[commit-cp] classpath ChangeLog

2005-09-15 Thread Anthony Green
CVSROOT:/cvsroot/classpath
Module name:classpath
Branch: 
Changes by: Anthony Green [EMAIL PROTECTED]   05/09/15 14:43:37

Modified files:
.  : ChangeLog 

Log message:
Remove somebody's old conflict marker.

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/ChangeLog.diff?tr1=1.4796tr2=1.4797r1=textr2=text





[commit-cp] classpath ./ChangeLog java/io/PushbackInputStre...

2005-09-15 Thread Anthony Green
CVSROOT:/cvsroot/classpath
Module name:classpath
Branch: 
Changes by: Anthony Green [EMAIL PROTECTED]   05/09/15 15:25:34

Modified files:
.  : ChangeLog 
java/io: PushbackInputStream.java 

Log message:
* java/io/PushbackInputStream.java (available, read, skip): Handle
closed stream operations gracefully.

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/ChangeLog.diff?tr1=1.4797tr2=1.4798r1=textr2=text
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/java/io/PushbackInputStream.java.diff?tr1=1.16tr2=1.17r1=textr2=text





[commit-cp] classpath ./ChangeLog java/awt/Component.java j...

2005-09-15 Thread Anthony Balkissoon
CVSROOT:/cvsroot/classpath
Module name:classpath
Branch: 
Changes by: Anthony Balkissoon [EMAIL PROTECTED]  05/09/15 16:49:02

Modified files:
.  : ChangeLog 
java/awt   : Component.java Window.java 

Log message:
2005-09-15  Anthony Balkissoon  [EMAIL PROTECTED]

* java/awt/Component.java:
(isDisplayable): Return true if peer != null.
* java/awt/Window.java:
(isDisplayable): Removed this method. Now inherits from Component.

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/ChangeLog.diff?tr1=1.4798tr2=1.4799r1=textr2=text
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/java/awt/Component.java.diff?tr1=1.72tr2=1.73r1=textr2=text
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/java/awt/Window.java.diff?tr1=1.54tr2=1.55r1=textr2=text





[commit-cp] classpath ./ChangeLog javax/swing/plaf/basic/Ba...

2005-09-15 Thread Anthony Balkissoon
CVSROOT:/cvsroot/classpath
Module name:classpath
Branch: 
Changes by: Anthony Balkissoon [EMAIL PROTECTED]  05/09/15 18:08:52

Modified files:
.  : ChangeLog 
javax/swing/plaf/basic: BasicInternalFrameUI.java 

Log message:
2005-09-15  Anthony Balkissoon  [EMAIL PROTECTED]

* javax/swing/plaf/basic/BasicInternalFrameUI.java:
Reformatted file.

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/ChangeLog.diff?tr1=1.4802tr2=1.4803r1=textr2=text
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/javax/swing/plaf/basic/BasicInternalFrameUI.java.diff?tr1=1.16tr2=1.17r1=textr2=text





[commit-cp] classpath ChangeLog

2005-09-15 Thread Anthony Balkissoon
CVSROOT:/cvsroot/classpath
Module name:classpath
Branch: 
Changes by: Anthony Balkissoon [EMAIL PROTECTED]  05/09/15 18:10:37

Modified files:
.  : ChangeLog 

Log message:
Typo in email address in ChangeLog.

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/ChangeLog.diff?tr1=1.4803tr2=1.4804r1=textr2=text





[commit-cp] classpath ./ChangeLog java/lang/EnumConstantNot... [generics-branch]

2005-09-15 Thread Tom Tromey
CVSROOT:/cvsroot/classpath
Module name:classpath
Branch: generics-branch
Changes by: Tom Tromey [EMAIL PROTECTED]  05/09/15 19:06:10

Modified files:
.  : ChangeLog 
Added files:
java/lang  : EnumConstantNotPresentException.java 

Log message:
* java/lang/EnumConstantNotPresentException.java: New file.

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/ChangeLog.diff?only_with_tag=generics-branchtr1=1.2386.2.129tr2=1.2386.2.130r1=textr2=text
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/java/lang/EnumConstantNotPresentException.java?only_with_tag=generics-branchrev=1.1.2.1





[commit-cp] classpath ./ChangeLog java/lang/EnumConstantNot...

2005-09-15 Thread Tom Tromey
CVSROOT:/cvsroot/classpath
Module name:classpath
Branch: 
Changes by: Tom Tromey [EMAIL PROTECTED]  05/09/15 19:20:00

Modified files:
.  : ChangeLog 
Added files:
java/lang  : EnumConstantNotPresentException.java 

Log message:
* java/lang/EnumConstantNotPresentException.java: New file.

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/ChangeLog.diff?tr1=1.4804tr2=1.4805r1=textr2=text
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/java/lang/EnumConstantNotPresentException.java.diff?tr1=1.1tr2=1.2r1=textr2=text





[commit-cp] classpath ./ChangeLog javax/swing/plaf/basic/Ba...

2005-09-15 Thread Lillian Angel
CVSROOT:/cvsroot/classpath
Module name:classpath
Branch: 
Changes by: Lillian Angel [EMAIL PROTECTED]   05/09/15 19:58:43

Modified files:
.  : ChangeLog 
javax/swing/plaf/basic: BasicComboBoxRenderer.java 
BasicComboBoxUI.java 

Log message:
2005-09-15  Lillian Angel  [EMAIL PROTECTED]

* javax/swing/plaf/basic/BasicComboBoxRenderer.java
(getListCellRendererComponent): Added code in to check if string
is larger than comboBox. If it is, the string is truncated and
'...' is drawn at the end of it.
* javax/swing/plaf/basic/BasicComboBoxUI.java
(getDefaultSize): Initially too small, still not fully implemented.
(getLargestItemSize): Made private, not in API.
(minimumLayoutSize): Implemented properly.
(intervalAdded): ComboBox should not be resized with every new
component. This is fixed.

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/ChangeLog.diff?tr1=1.4805tr2=1.4806r1=textr2=text
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/javax/swing/plaf/basic/BasicComboBoxRenderer.java.diff?tr1=1.4tr2=1.5r1=textr2=text
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/javax/swing/plaf/basic/BasicComboBoxUI.java.diff?tr1=1.11tr2=1.12r1=textr2=text





[commit-cp] classpath ./ChangeLog javax/swing/SwingUtilitie...

2005-09-15 Thread David Gilbert
CVSROOT:/cvsroot/classpath
Module name:classpath
Branch: 
Changes by: David Gilbert [EMAIL PROTECTED]   05/09/15 20:24:14

Modified files:
.  : ChangeLog 
javax/swing: SwingUtilities.java 
javax/swing/plaf/basic: BasicButtonUI.java 
BasicInternalFrameTitlePane.java 

Log message:
2005-09-15  David Gilbert  [EMAIL PROTECTED]

* javax/swing/SwingUtilities.java
(layoutCompoundLabel): check for empty text string,
* javax/swing/plaf/basic/BasicButtonUI.java
(paint): check isBorderPainted() when calculating view rect,
* javax/swing/plaf/basic/BasicInternalFrameTitlePane.java
(CloseAction): new constructor,
(IconifyAction): new constructor,
(MaximizeAction): new constructor,
(MoveAction): new constructor,
(RestoreAction): new constructor,
(SizeAction): new constructor,
(TitlePaneLayout.layoutContainer): calculate button widths from
icon
widths,
(installDefaults): initialise icon fields,
(uninstallDefaults): clear icon fields,
(createButtons): set button text to null,
(setButtonIcons): use icon fields.

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/ChangeLog.diff?tr1=1.4806tr2=1.4807r1=textr2=text
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/javax/swing/SwingUtilities.java.diff?tr1=1.34tr2=1.35r1=textr2=text
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/javax/swing/plaf/basic/BasicButtonUI.java.diff?tr1=1.25tr2=1.26r1=textr2=text
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/javax/swing/plaf/basic/BasicInternalFrameTitlePane.java.diff?tr1=1.14tr2=1.15r1=textr2=text





[commit-cp] classpath ./ChangeLog java/awt/Component.java

2005-09-15 Thread Anthony Balkissoon
CVSROOT:/cvsroot/classpath
Module name:classpath
Branch: 
Changes by: Anthony Balkissoon [EMAIL PROTECTED]  05/09/15 21:59:02

Modified files:
.  : ChangeLog 
java/awt   : Component.java 

Log message:
2005-09-15  Anthony Balkissoon  [EMAIL PROTECTED]

* java/awt/Component.java:
(isDisplayable): Don't check the parent's displayability, only return
true if peer is non-null and false if peer is null.

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/ChangeLog.diff?tr1=1.4807tr2=1.4808r1=textr2=text
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/java/awt/Component.java.diff?tr1=1.73tr2=1.74r1=textr2=text





[commit-cp] classpath ./ChangeLog javax/swing/text/html/par...

2005-09-15 Thread Tom Tromey
CVSROOT:/cvsroot/classpath
Module name:classpath
Branch: 
Changes by: Tom Tromey [EMAIL PROTECTED]  05/09/15 23:12:18

Modified files:
.  : ChangeLog 
javax/swing/text/html/parser: DTD.java 

Log message:
* javax/swing/text/html/parser/DTD.java (FILE_VERSION): Now
final.

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/ChangeLog.diff?tr1=1.4809tr2=1.4810r1=textr2=text
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/javax/swing/text/html/parser/DTD.java.diff?tr1=1.4tr2=1.5r1=textr2=text





[commit-cp] classpath ./ChangeLog java/awt/Color.java java/...

2005-09-15 Thread Anthony Green
CVSROOT:/cvsroot/classpath
Module name:classpath
Branch: 
Changes by: Anthony Green [EMAIL PROTECTED]   05/09/16 01:11:39

Modified files:
.  : ChangeLog 
java/awt   : Color.java Point.java Rectangle.java 

Log message:
* java/awt/Color.java (RGBtoHSB): Don't use integer division when
calculating saturation.
* java/awt/Rectangle.java (equals): Explain why hashCode() isn't
required.
* java/awt/Point.java (equals): Ditto.

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/ChangeLog.diff?tr1=1.4811tr2=1.4812r1=textr2=text
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/java/awt/Color.java.diff?tr1=1.12tr2=1.13r1=textr2=text
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/java/awt/Point.java.diff?tr1=1.10tr2=1.11r1=textr2=text
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/java/awt/Rectangle.java.diff?tr1=1.15tr2=1.16r1=textr2=text





[commit-cp] classpath ChangeLog

2005-09-15 Thread Anthony Green
CVSROOT:/cvsroot/classpath
Module name:classpath
Branch: 
Changes by: Anthony Green [EMAIL PROTECTED]   05/09/16 01:12:18

Modified files:
.  : ChangeLog 

Log message:
Remove conflict marker.

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/ChangeLog.diff?tr1=1.4812tr2=1.4813r1=textr2=text





[commit-cp] classpath ./ChangeLog java/util/zip/ZipFile.java

2005-09-15 Thread Anthony Green
CVSROOT:/cvsroot/classpath
Module name:classpath
Branch: 
Changes by: Anthony Green [EMAIL PROTECTED]   05/09/16 01:07:21

Modified files:
.  : ChangeLog 
java/util/zip  : ZipFile.java 

Log message:
* java/util/zip/ZipFile.java (checkZipFile): Make sure we read the
4 byte magic number.

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/ChangeLog.diff?tr1=1.4810tr2=1.4811r1=textr2=text
http://savannah.gnu.org/cgi-bin/viewcvs/classpath/classpath/java/util/zip/ZipFile.java.diff?tr1=1.26tr2=1.27r1=textr2=text