Re: EventListener
One way is to store your frame somewhere in your MIActionListener. With minimum changes in your code you can write like this menulistener.addActionListener(new MIActionListener(this)); class MIActionListener implements ActionListener{ Frame f; MIActionListener(Frame f) { this.f = f; } public void actionPerformed(ActionEvent Ae){ f.setBounds(...); //... } } Commonly used (but probably not the best) way to shorten code is to use anonymous internal class in this manner: menulistener.addActionListener(new MIActionListener() { public void actionPerformed(ActionEvent Ae){ JFrame.this.setBounds(...); //... } }); Hope this helps All the Best Pavel ALPESH KOTHARI wrote: > > Hello all, > > I am developing a GUI using JAVA 2 on linux. > > There is one menuitem, which when pressed should resize my main window. > But I am not exactly able to write the resize code in the > actionlistener.. > > class xxx extends JFrame{ > . > . > . > > menulistener.addActionListener(new MIActionListener()); > > . > . > > } > > class MIActionListener implements ActionListener{ > public void ActionPerformed(ActionEvent Ae){ > //To write a code so as the resize the > //main window of xxx. > } > } > > So what can I do? > > This may be a silly question, but I would thank if someone answers it. > THanking YOU > Alpesh > > > > === > KOTHARI ALPESH D. > STUDENT M. TECH. > CEDT > INDIAN INSTITUTE OF SCIENCE > BANGALORE-560 012 > INDIA > __ > Do You Yahoo!? > Bid and sell for free at http://auctions.yahoo.com > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Coredump
Hi. I installed jre1.2 pre-v2 on my slackware machine running glibc 2.0.4. Everytime I try to run "java", i get a coredump. Has anyone else had this problem before? Thanks. Shu Wei [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
jdk for alpha (redhat 6.0)?
Hi, does anyone know if there is a port in the works for Alpha (EV56) running RedHat 6.0? I saw a message about it from a couple months ago and I was wondering if there was any update. I don't see anything about it on the JCK page. Also will it support JNI? Thanks. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Status of JDK1.2
Hi, for about three months, I did not see any updates of the Blackdown 1.2 port status page Since 1.2 is more than buggy, I really would like to know where the Blackdown guys are at right now Maybe holidays? :) Whats going on with 1.2? Does anybody know? Greetings, Oli -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
RH5.0 and JDK1.2 -> Segmentation fault
Hello! I've got a RH5.0 running on a I386. I previously installed JDK117 and it was running perfect. Now a customer needs JDK1.2 and I downloaded glibc2.0-version last week. The first problem running ./java in the /bin-directory was libjava.so. I fixed it by editing the .wrapper...-file and hardcoding APPHOME-Path. When I now try to run ./java or java I get a "segmentation fault (Core dumped)"-error instead of the usage. Where is the problem ?? Thanks in advance, Holger -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
RE: Problems installing JDK 1.1.7 and JDK 1.2 pre-v2
Hi guys... I have finally managed to install JDK1.1.7_v1a and JDK1.2... You won't imagine what I was doing wrong! As I previously wrote, I did download the proper archives (all of them, and not only the native threads one, as somebody suggested). Also, I wasn't running from the /bin directory (which is problematic only for JDK 1.2, anyway). What happened is that, to download the tar files, I used an NT machine, linked to my Linux PC via Samba. So far so good. But, being lazy in typing "tar -xvf" under Linux, I used WinZip to un-tar and then copied the extracted files into the Linux JDK directory (1.1.7 or 1.2, respectively) directly. Well, I don't know why (please somebody explain), but with this procedure I kinda "lost" files during the WinZip extraction!!! The jdk/bin directory contained only a few of the scripts, (.java_wrapper, java-rmi.cgi, checkVersions, and jre for JDK1.1.7 and only the first two of these for JDK 1.2)!!! Weird! So far I have un-tared several archives with WinZip, without any problems. Is there any shell script automatically running after un-taring with tar, which (reasonably) WinZip cannot execute? I know have a silly problem with JDK 1.1.7. Namely, while I can compile my application (containing several .java files organised in a number of packages), when I attempt to run it, it doensn't run! My environment is $JAVA_HOME = $CLASSPATH = .:$JAVA_HOME/lib/classes.zip:$JAVA_HOME/swingall.jar I can compile the source files from whichever directory I want (typing $JAVA_HOME/bin/javac /*.java) without any problems. However, when I try running a (just compiled) class, even from its directory, I get a "Can't find class" message. When I attempt the (not-so-redundant-as-I-believed) command $JAVA_HOME/bin/java -classpath $CLASSPATH I get a "Unable to initialize threads: Can't find java/lang/Thread" message. I have even played with the scripts in $JAVA_HOME/bin, inserting debugging comments, and they seem to be after the correct path... This must be a really silly error, could someone please help? I suspect all this has to do with paths, since JDK 1.2 works just fine... > Also, is version 3 of the Linux jdk1.1.7 implementation for libc2.0 (as > well as libc2.1) or not? I tried to use v3, but refuses to find > "javax.swing" (i.e., seems as if it doesn't read the swingall.jar file, > which, however, is contained in the CLASSPATH...) > Thanks, Dimitris -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Is JVMDI supported ?
Does JDK 1.2pre2 support Java Virtual Machine Debug Interface (JVMDI)? My understanding is that it is a C API described in JDK_ROOT/include-old/jvmdi.h. I'm under review in using JVMDI to reconstruct a thread migration system I'v developed. And how about JVMPI? Kazuyuki SHUDO Happy Hacking! Muraoka Lab., School of Sci. & Eng., Waseda Univ. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
RE: Problems installing JDK 1.1.7 and JDK 1.2 pre-v2
+I know have a silly problem with JDK 1.1.7. Namely, while I can compile my +application (containing several .java files organised in a number of +packages), when I attempt to run it, it doensn't run! My environment is + $JAVA_HOME = + $CLASSPATH = .:$JAVA_HOME/lib/classes.zip:$JAVA_HOME/swingall.jar + potentially silly error, some potentially silly solutions, which I occasionally have to remember : - when you run the class file do you include the package name ? eg.. cd javac -d . RunDammit.java java com.nortelnetworks.RunDammit - Check that it creates a directory structure approp to yo source.. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: IBM's Java/Linux agenda
Linux runs well on PowerPC which is CPU for AIX, OS/390, and OS/400. So for IBM Linux could be MVS (their mainframe OS) for 21 centure as well. Jacob Charles Forsythe wrote: > > > And who thinks that the big heads at IBM have other reasons for supporting > > java [than] ... java hurts M$. > > I don't work for IBM, but here is my best guess at a better reason for > them to support Java: the "write once run anywhere" promise. > > Consider all of the systems that IBM *currently* ships: AIX, OS/390, > OS/400, OS/2, and now (drum roll please) Linux. Not only that, but IBM > also makes sure that its systems integrate with Windows. > > Maybe they support Linux just to piss of Microsoft, but Java is "the > Cobol of the 21st Century"* for IBM. For this reason, IBM has taken > control of its own Java destiny and is producing the best JVMs around. > > -Charles > * Rough quote from "Java and the AS/400" (and IBM white paper). BTW, > IBM's new Java support for the AS/400 is really cool; it's NOT a JVM. > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Swing version w/ 1.2 pre-2?
[EMAIL PROTECTED] wrote: > > I've been doing 1.1 programming with Swing 1.1.1 beta2, and now am > upgrading to Swing 1.2. I've noticed, though, that some of Swing's > newer features aren't there - so moving to 1.2 is actually a > "downgrade" as far as Swing is concerned. > > The feature that I was using is the ability to use HTML for text in > components. > > Anyone know about this, and when it'll get resolved? Yes I have asked for this Swing upgrade in the next linux 1.2.l release that mentioned a few posts agao -- Cheers Peter - import std.Disclaimer; // More Java for your Lava, Mate. "Old Trafford, the theatre of dreams (that finally came true)." -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
RE: Problems installing JDK 1.1.7 and JDK 1.2 pre-v2
Hello again... I think I 've solved most of the silly problems I was experiencing, thanks for your help and advises... The only one remaining is a NullPointerException I 'm getting when launching my application from JDK 1.1.7. It has to do with the initial JFrame. The interpreter resolves this to the Motif peer, so I suspect it is related to Swing (JFC 1.1.1). I haven't seen any Linux-specific JFC port, so what I did is I included the swingall.jar file from the Javasoft Solaris distribution of JFC 1.1.1 (which is an identical file to the Win32 distribution, by the way). Is anyone aware of any bugs/problems (and solutions) in Swing 1.1.1 support for JDK 1.1.7 in Linux? Cheers, Dimitris -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
RE: Problems installing JDK 1.1.7 and JDK 1.2 pre-v2
> +I know have a silly problem with JDK 1.1.7. Namely, while I can compile my > +application (containing several .java files organised in a number of > +packages), when I attempt to run it, it doensn't run! My environment is > + $JAVA_HOME = > + $CLASSPATH = .:$JAVA_HOME/lib/classes.zip:$JAVA_HOME/swingall.jar > + > > potentially silly error, some potentially silly > solutions, which I occasionally have to remember : > > > - when you run the class file do you include the package name ? > > eg.. > > cd > javac -d . RunDammit.java > java com.nortelnetworks.RunDammit You 're right, I typed nortelnetworks/RunDammit instead (which worked for JDK 1.2!!!). Thanks! :-) -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Problems installing JDK 1.1.7 and JDK 1.2 pre-v2
>From: "Dimitris Terzis" <[EMAIL PROTECTED]> >Date: Mon, 23 Aug 1999 14:53:03 +0100 >Hi guys... > >I have finally managed to install JDK1.1.7_v1a and JDK1.2... You won't >What happened is that, to download the tar files, I used an NT machine, >linked to my Linux PC via Samba. So far so good. But, being lazy in typing >"tar -xvf" under Linux, I used WinZip to un-tar and then copied the >extracted files into the Linux JDK directory (1.1.7 or 1.2, respectively) >directly. Well, I don't know why (please somebody explain), but with this >procedure I kinda "lost" files during the WinZip extraction!!! The jdk/bin kinda? If they weren't really lost, but corrupted, I've had the same "experience". If you don't set the "TAR LF to CR/LF Translation" to off within WinZip, any ascii files within your tar-file will be changed. The default is set to ON in WinZip (unfortunately). -Larry Gates -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Problems installing JDK 1.1.7 and JDK 1.2 pre-v2
Actually, I believe the problem is related to the fact the NT doesn't support symbolic links. Almost all the files in the ($JAVA_HOME)/bin directory are symbolic links to .java_wrapper. The only two files that aren't symbolic links are .java_wrapper and java-rmi.cgi (atleast on 1.2). On Mon, 23 Aug 1999, Larry Gates wrote: > > >From: "Dimitris Terzis" <[EMAIL PROTECTED]> > >Date: Mon, 23 Aug 1999 14:53:03 +0100 > > >Hi guys... > > > >I have finally managed to install JDK1.1.7_v1a and JDK1.2... You won't > > >What happened is that, to download the tar files, I used an NT machine, > >linked to my Linux PC via Samba. So far so good. But, being lazy in typing > >"tar -xvf" under Linux, I used WinZip to un-tar and then copied the > >extracted files into the Linux JDK directory (1.1.7 or 1.2, respectively) > >directly. Well, I don't know why (please somebody explain), but with this > >procedure I kinda "lost" files during the WinZip extraction!!! The jdk/bin > > kinda? If they weren't really lost, but corrupted, I've had the same > "experience". If you don't set the "TAR LF to CR/LF Translation" to > off within WinZip, any ascii files within your tar-file will be > changed. The default is set to ON in WinZip (unfortunately). > > -Larry Gates > > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] > -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: IBM's Java/Linux agenda: why JDK1.1.6 port?
Do you know why IBM ported JDK1.1.6 instead of 1.1.8? I could understand why they did not pick up 1.2, but 1.1.8 is very stable and capable of. Jacob Aravind Selvaraje wrote: > > Agreed. > > Currently, IBM spends more money on Java and Java related products than Sun. > > With their EJB marketing they are promoting the fact that you can develop > beans on your laptop, test them and when ready to scale drop them on to a > mid range AIX or AS/400 box or if you want huge grunt, put them on a OS/390. > The return of the mainframe > Of course, you need to look no farther than their support for Linux and Java > so that they can't be blackmailed by M$ for their dev platforms. > > -- Aravind > > > -Original Message- > > From: Charles Forsythe [mailto:[EMAIL PROTECTED]] > > Sent: Friday, 20 August 1999 15:32 > > To: [EMAIL PROTECTED] > > Subject: IBM's Java/Linux agenda > > > > > > > And who thinks that the big heads at IBM have other reasons for > > supporting > > > java [than] ... java hurts M$. > > > > I don't work for IBM, but here is my best guess at a better reason for > > them to support Java: the "write once run anywhere" promise. > > > > Consider all of the systems that IBM *currently* ships: AIX, OS/390, > > OS/400, OS/2, and now (drum roll please) Linux. Not only that, but IBM > > also makes sure that its systems integrate with Windows. > > > > Maybe they support Linux just to piss of Microsoft, but Java is "the > > Cobol of the 21st Century"* for IBM. For this reason, IBM has taken > > control of its own Java destiny and is producing the best JVMs around. > > > > -Charles > > * Rough quote from "Java and the AS/400" (and IBM white paper). BTW, > > IBM's new Java support for the AS/400 is really cool; it's NOT a JVM. > > > > > > -- > > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > > with a subject of "unsubscribe". Trouble? Contact > > [EMAIL PROTECTED] > > > > > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
RE: IBM's Java/Linux agenda: why JDK1.1.6 port?
They just took their stable AIX port and modified to Linux. The JIT code comes from their Intel Win32 platform. Time to market (release) was the esence. -- Aravind > -Original Message- > From: Jacob Nikom [mailto:[EMAIL PROTECTED]] > Sent: Monday, 23 August 1999 17:42 > To: [EMAIL PROTECTED] > Cc: [EMAIL PROTECTED] > Subject: Re: IBM's Java/Linux agenda: why JDK1.1.6 port? > > > Do you know why IBM ported JDK1.1.6 instead of 1.1.8? I could understand > why they did not pick up 1.2, but 1.1.8 is very stable and capable of. > > Jacob > > Aravind Selvaraje wrote: > > > > Agreed. > > > > Currently, IBM spends more money on Java and Java related > products than Sun. > > > > With their EJB marketing they are promoting the fact that you > can develop > > beans on your laptop, test them and when ready to scale drop > them on to a > > mid range AIX or AS/400 box or if you want huge grunt, put them > on a OS/390. > > The return of the mainframe > > Of course, you need to look no farther than their support for > Linux and Java > > so that they can't be blackmailed by M$ for their dev platforms. > > > > -- Aravind > > > > > -Original Message- > > > From: Charles Forsythe [mailto:[EMAIL PROTECTED]] > > > Sent: Friday, 20 August 1999 15:32 > > > To: [EMAIL PROTECTED] > > > Subject: IBM's Java/Linux agenda > > > > > > > > > > And who thinks that the big heads at IBM have other reasons for > > > supporting > > > > java [than] ... java hurts M$. > > > > > > I don't work for IBM, but here is my best guess at a better reason for > > > them to support Java: the "write once run anywhere" promise. > > > > > > Consider all of the systems that IBM *currently* ships: AIX, OS/390, > > > OS/400, OS/2, and now (drum roll please) Linux. Not only > that, but IBM > > > also makes sure that its systems integrate with Windows. > > > > > > Maybe they support Linux just to piss of Microsoft, but Java is "the > > > Cobol of the 21st Century"* for IBM. For this reason, IBM has taken > > > control of its own Java destiny and is producing the best JVMs around. > > > > > > -Charles > > > * Rough quote from "Java and the AS/400" (and IBM white paper). BTW, > > > IBM's new Java support for the AS/400 is really cool; it's NOT a JVM. > > > > > > > > > -- > > > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > > > with a subject of "unsubscribe". Trouble? Contact > > > [EMAIL PROTECTED] > > > > > > > > > > -- > > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > > with a subject of "unsubscribe". Trouble? Contact > [EMAIL PROTECTED] > -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
display problem I need some advice and help
Hello, I use JDK 1.1.7 v3 linux and latest version of all program and libs that ship with redhat I devlop program using a windows GUI (powerJ) I want to use my what I develop in MS windows under linux. I have 2 problems (i am using the same screen resolution under MS win and X) : - The windows are not the same size under MS win it depend on the pixel and it seems that under X it depend on the font used for X.(I have not a good idea how to control those fonts and how to make a match between the screens MS win => X) Is there any solution ? - Under MS win a SetEnable(false) text field is readable it only change color. Under X not but i want to be able to read it. Using setEditable() might have been the solution but then when you "TAB" between text field it entre the also the non editable field which is use less and i want to avoid that. I know that it is X that deal with the disable, enable text look/font/display Is there a way to work around this ? Thanks Marc (PS : not sure my message was correctly sent the first time ) -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Poll: Which Java/Linux IDE?
Hi - maybe this has been asked before (sorry if that's the case), but I am wondering which Java/Linux IDE, if any, people are using? I tried Netbeans, and like it a lot (nice interface, writes clean code, installed without hassle) although it seems a bit too much for my little 133mhz/96MB machine, and actually crashes when I try to enter its help system. Any pros and cons on this or any other IDEs? Thanks! Renzo -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Coredump
> > Hi. I installed jre1.2 pre-v2 on my slackware machine running glibc > > 2.0.4. Everytime I try to run "java", i get a coredump. Has anyone else > > had this problem before? > > There has been some discussion about pixel depth in X windows causing > problems. try starting X with -bpp 16. > > try the list archives for more details > > Regards > Gordon I found out what the problem is. Everything worked fine when I installed glibc 2.0.7-19. Thanks. Shu Wei -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Poll: Which Java/Linux IDE?
An excellent IDE that is free for Linux and comparable to VisualAge is AnyJ, I came across it and fell in love with it. You can do all sorts of editing including HTML to make your applet/servlet creation and deployment easier. Here is the url: http://www.netcomputing.de/ -Riyad Renzo Pecoraro wrote: > Hi - > > maybe this has been asked before (sorry if that's the case), but I am > wondering which Java/Linux IDE, if any, people are using? I tried > Netbeans, and like it a lot (nice interface, writes clean code, > installed without hassle) although it seems a bit too much for my little > 133mhz/96MB machine, and actually crashes when I try to enter its help > system. Any pros and cons on this or any other IDEs? > > Thanks! > Renzo > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- [ Riyad Kalla ] [ University of Arizona ] [ CS Major] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]