import java.awt.*; import java.awt.event.*; import java.awt.image.*; import com.sun.image.codec.jpeg.*; import java.applet.Applet; import java.io.*; public class PildiredaktorS extends Applet implements MouseListener, ActionListener{ int pildilaius=800, pildikorgus=600; int suurendus=2; Button nupp1=new Button("Salvesta"); Button nupp2=new Button("Ava pilt"); TextField tf=new TextField("", 20); String nimi="pilt.jpg"; BufferedImage pilt=new BufferedImage(pildilaius, pildikorgus, BufferedImage.TYPE_INT_RGB); Graphics2D piltg=pilt.createGraphics(); BufferedImage puhver; Choice varvivalik=new Choice(); String[] varvinimed={"Punane", "Sinine", "Kollane"}; Color[] varvid={Color.red, Color.blue, Color.yellow}; Choice kujundivalik=new Choice(); String[] kujundid={"Ring tühi", "Ring täidetud", "Ruut tühi", "Ruut täidetud", "Joon", " - "}; int allaX, allaY; Choice CopyPaste=new Choice(); String[] CopyPasteMenu={" - ", "Lõika", "Kopeeri", "Aseta"}; Choice suurendamine=new Choice(); String[] zoomin={"100%", "50%", "200%"}; public PildiredaktorS(){ tf.setText(nimi); addMouseListener(this); for(int i=0; i