[Fwd: Java Help Request, et caetera!]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



-------- Original Message --------
Subject: [Fwd: Java Help Request, et caetera!]
From: <joseph.north@xxxxxxxxxxxxxx>
Date: Tue, September 21, 2004 8:55 pm
To: <gcc-help@xxxxxxxxxxx>
Cc: <joseph.north@xxxxxxxxx>


Dear gcc-help:


   Mayday, m'aider, s'il vous plait (see below)!
   Tempus fugit et ad augusta per angusta.




                       Nil desparare (Gauss),


                       Joseph Roy D. North

Scientia est Potentia!


-------- Original Message --------
Subject: Java Help Request, et caetera!
From: <joseph.north@xxxxxxxxxxxxxx>
Date: Mon, September 20, 2004 2:39 pm
To: <llee4@xxxxxxxxxxxxx>
Cc: "Danny Dineen" <ddineen@xxxxxxx>,
<joseph.north@xxxxxxxxx>


Hi Lance,


   Please look at the attached file, and help me to get it
to work, please!  You could come over, or I could visit
you.
   I am running under Red Hat Linux Fedora Core 1.
   Do you want to try Knoppix 3.4 on live CD, and KStars
1.0, which I told you I have when I last returned your
Java book?  Can you now burn a copy for yourself, please?



                       Thanks,


                       Joseph Roy D. North
                       3220 Duval Road, Apt. 1110
                       Austin, TX 78759-3524, USA

Scientia est Potentia!


[jos1@JNorth java1]$ date
Mon Sep 20 11:32:33 CDT 2004
[jos1@JNorth java1]$ cat StandaloneScribble.java
import java.applet.*;
import java.awt.*;
import java.awt.event.*;
 
public class StandaloneScribble extends Applet
{
    public static void main(String[] args)
    {
        Frame f = new Frame();
        Applet a = new StandaloneScribble();
        f.add(a, "Center");
        a.init();
        f.setSize(400, 400);
        f.show();
        f.addWindowListener(new WindowAdapter()
            {
                public void windowClosing(WindowEvent e) {System.exit(0);}
            });
    }
 
    public void init()
    {
        this.addMouseListener(new MouseAdapter()
            {
        public void MousePressed(MouseEvent e)
            {
                lastx = e.getX();
                lasty = e.getY();
            }
    });
 
        this.addMouseMotionListener(new MouseMotionAdapter()
            {
        public void MouseDragged(MouseEvent e)
            {
                Graphics g = getGraphics();
                int x = e.getX(), y = e.getY();
                g.setColor(Color.black);
                g.drawLine(lastx, lasty, x, y);
                lastx = x;
                lasty = y;
            }
    });
    }
    protected int lastx, lasty;
}
[jos1@JNorth java1]$ gcj --main=StandaloneScribble  StandaloneScribble.java
[jos1@JNorth java1]$ a.out
Exception in thread "main" java.awt.AWTError: Cannot load AWT toolkit: gnu.awt.
gtk.GtkToolkit not found in [file:./, core:/]
   at java.awt.Toolkit.getDefaultToolkit() (/usr/lib/libgcj.so.4.0.0)
   at java.awt.Window.getToolkit() (/usr/lib/libgcj.so.4.0.0)
   at java.awt.Container.addImpl(java.awt.Component, java.lang.Object, int)
(/usr/lib/libgcj.so.4.0.0)
   at java.awt.Container.add(java.awt.Component, java.lang.Object)
(/usr/lib/libgcj.so.4.0.0)
   at StandaloneScribble.main(java.lang.String[]) (Unknown Source)
[jos1@JNorth java1]$ emacs javas1.txt &
[1] 8173
[jos1@JNorth java1]$


[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux