Unidentified subject!

1998-09-06 Thread Reinhard Simon

Hello Java-linux-freaks!

Java and linux are really good!

My question: Is it possible to append text to an existing file?
(like >>filename in the shell)


Thanks


Reinhard Simon
HTL Wr. Neustadt Austria
[EMAIL PROTECTED]




Image-Button

1998-11-03 Thread Reinhard Simon

Hi!

Together with JDK 1.0 Event Handling I used an Image Button from the
Java Work Shop 1.0.
Now I can' t find an Image Button for JDK 1.1 Event Handling.

Has someone a java-file for it?

--
Reinhard Simon

HTL Wr. Neustadt Abt. EDVO  email: [EMAIL PROTECTED]





Problems with German characters

1998-07-01 Thread Reinhard Simon

I am from Germany
With java for linux 1.1.3 I was able to write our special Characters
like oe in a java.awt.Textfield. With java for linux 1.1.5 it is not
possible any more. What can I do?
 

Reinhard Simon

HTL Wr. Neustadt Abt. EDVO  email: [EMAIL PROTECTED]



java.awt.Printjob

1998-07-01 Thread Reinhard Simon

I want to print a Canvas with a picture (gif) directly from a frame.
So I use a Printjob, but it does not work on both of my linux-systems.
After the frame Print Dialog, I get a frame "Print Error" with
the message : Could not execute pring command (L_java.lang.String...)
If I write the output to a file and pipe it into lpr it works, but it
is no solution.

I append the Java-Source Krankenschein_Test.java
I hope someone can help me!

 
Reinhard Simon

HTL Wr. Neustadt Abt. EDVO  email: [EMAIL PROTECTED]


import java.awt.*;
import java.awt.event.*;

public class Krankenschein_Test extends Frame
   implements ActionListener {
 Frame frame = null;
 private Canvas canvas = null;
 Image image = null;
 private Toolkit toolkit = null;
 private MediaTracker tracker = null;
 public static void main (String[] args ) {
   new Krankenschein_Test();
 }
 public Krankenschein_Test() {
   super ("Printing Willi");
   this.tracker = new MediaTracker (this);
   this.frame = this;
   this.toolkit = getToolkit();
   try {
 this.image = toolkit.getImage("kschein.gif");
 tracker.addImage (image, 0);
 tracker.waitForID (0);
   }
   catch (InterruptedException is) {
 System.out.println ("Fehler beim Laden!");
 System.exit (0);
   }
   setLayout (new BorderLayout ());
   addWindowListener (
 new WindowAdapter () {
   public void windowClosing (WindowEvent e) {
 Runtime.getRuntime().exit(0);
   }
 }
   );
   Button button = new Button ("Drucken");
   button.addActionListener (this);
   add ("South", button);
   add ("Center", canvas = new Canvas () {
 public void paint (Graphics g) {
   g.drawImage (image, 0, 0,frame);
 }
 public Dimension getPreferredSize () {
   return new Dimension (100, 80);
 }
   });
   pack();
   show ();
 }
 public void actionPerformed( ActionEvent e) {
   PrintJob printJob = toolkit.getPrintJob (this, "Printing Willi", null);
   if (printJob != null) {
 Graphics printGraphics = printJob.getGraphics ();
 if (printGraphics != null) {
   frame.printComponents(printGraphics);
//   canvas.printAll (printGraphics);
   printGraphics.dispose();
 }
 else System.out.println ("No PrintGraphics");
 printJob.end();
   }
   else System.out.println ("No PrintJob");
 }
}




Unidentified subject!

1998-07-13 Thread Reinhard Simon

Hello Everybody!

Is it possible with Java to rotate a font (90 degree)?
I want to write from top to bottom in a canvas.
Perhaps you have another solution.

Thanks

Reinhard Simon
HTL Wr. Neustadt Austria
[EMAIL PROTECTED]