[kaffe] Re: Java unter Debian

Frank Küster frank at kuesterei.ch
Thu Feb 17 11:57:32 PST 2005

Michael Koch <konqueror at gmx.de> wrote:

(btw. I found out about /usr/bin/java, stupid me, update-alternatives
--config java, and I had a non-free jre installed)

> On Thu, Feb 17, 2005 at 07:39:53PM +0100, Frank Küster wrote:
>> It's a GPL'ed program, a BibTeX file manager, JabRef:
>> http://jabref.sourceforge.net/
>> Its category would be "Graphical Client Applications", I guess.  As
>> expected, I do get errors:
>> frank at alhambra:~/src$ kaffe -jar JabRef-1.7b.jar 
>> java.lang.NoClassDefFoundError: com/sun/java/swing/plaf/windows/WindowsLookAndFeel
>>    at java.lang.reflect.Method.invoke0 (Method.java)
>>    at java.lang.reflect.Method.invoke (Method.java:255)
>>    at kaffe.jar.ExecJarName.main (ExecJarName.java:67)
>>    at kaffe.jar.ExecJar.main (ExecJar.java:75)
>> frank at alhambra:~/src$ 
>> Doesn't sound very well, WindowsLookAndFeel...
> Hehe, thats a lesson in how to write non-portable apps with java. I
> think this class is only included in the Windows version of the JRE/JDK.

No, I just tried. I installed Sun's sun-j2re1.5, made with make-jpkg,
and it runs fine.  But this might be a bug in kaffe (or in the way it
determines where it is running:

>From GUIGlobals.java:

  // Frame titles.
  public static String
      frameTitle = "JabRef",
      version = "1.7b",
      stringsTitle = "Strings for database",
      //untitledStringsTitle = stringsTitle + Globals.lang("untitled"),
      untitledTitle = "untitled",
      helpTitle = "JabRef help",
      TYPE_HEADER = "entrytype",
      NUMBER_COL = "#",
      encPrefix = "Encoding: ", // Part of the signature in written bib files.
      linuxDefaultLookAndFeel = "com.jgoodies.plaf.plastic.Plastic3DLookAndFeel",
      windowsDefaultLookAndFeel = "com.jgoodies.plaf.windows.ExtWindowsLookAndFeel";

And from Jabref.java:

            if (!Globals.ON_MAC) {
                int fontSizes = prefs.getInt("menuFontSize");

                String defaultLookAndFeel;

                if (Globals.ON_WIN)
                    defaultLookAndFeel = GUIGlobals.windowsDefaultLookAndFeel;
                    defaultLookAndFeel = GUIGlobals.linuxDefaultLookAndFeel;

Oh, strange:

  public static boolean ON_MAC = (osName.equals(MAC)),
      ON_WIN = (osName.startsWith("Windows"));

Regards, Frank

Frank Küster
Inst. f. Biochemie der Univ. Zürich
Debian Developer

More information about the kaffe mailing list