Q : About Jython & Applet (i'm begginer -_-)
D-Man
dsh8290 at rit.edu
Wed Jan 31 12:47:08 EST 2001
On Wed, Jan 31, 2001 at 10:26:31AM +0900, ç?yç?y wrote:
| hi.. I'm begginer for jython..
|
| I make a simple applet with jython
|
| source is :
|
| import java
| class HelloApplet(java.applet.Applet):
| def paint(self,g):
| g.setColor(java.awt.Color.black)
| g.fill3DRect(5,5,590,100,0)
| g.setFont(java.awt.Font("Arial",0,80))
| g.setColor(java.awt.Color.magenta)
| g.drawString("Hello World", 90, 80)
|
| as you know that it's just print "Hello World"
|
| but, I don't see that result though appletviewer or explorer
How are you using the appletviewer or explorer? To display an applet,
it must first be in an HTML file. Example:
<html><body>
<applet classpath="HelloApplet.class" main="HelloApplet">
</body></html>
|
| I'm using jdk 1.3.0_01, jython 2.0..
|
| I just installed and setted the pass.
|
| .java & .class are OK.
|
| What I have to do something for that?
|
You should check the docs on the applet tag, I may have gotten the
attributes wrong.
HTH,
-D
More information about the Python-list
mailing list