You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Randy Layman <ra...@aswethink.com> on 2002/03/05 15:56:11 UTC

RE: How to use swing classes without X-server

	1.  Use JDK1.4 with its new headless command line option
	2.  Use one of the psuedo-X servers (search the list archives, this
has been discussed numerous times and names of options and installation
directions should be listed).

	Randy


> -----Original Message-----
> From: Serge A. Redchuk [mailto:s.redchuk@kse.kiev.ua]
> Sent: Tuesday, March 05, 2002 10:40 AM
> To: tomcat-user@jakarta.apache.org
> Subject: How to use swing classes without X-server
> 
> 
> Hello All !
> 
> I want to use some of Swing classes like
> 
> import javax.swing.tree.TreeModel;
> import javax.swing.tree.TreePath;
> 
> by tomcat in environment where no X-server running.
> 
> And I see in catalina.out:
> 
> java.lang.InternalError: Can't connect to X11 window server 
> using ':0.0' as the
> value of the DISPLAY variable.
>         at sun.awt.X11GraphicsEnvironment.initDisplay(Native Method)
>         at 
> sun.awt.X11GraphicsEnvironment.<clinit>(X11GraphicsEnvironment.java:5
> 9)
>         at java.lang.Class.forName0(Native Method)
>         at java.lang.Class.forName(Class.java:120)
>         at 
> java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvi
> ronment.java:58)
>         at sun.awt.motif.MToolkit.<clinit>(MToolkit.java:57)
>         at java.lang.Class.forName0(Native Method)
>         at java.lang.Class.forName(Class.java:120)
>         at java.awt.Toolkit$2.run(Toolkit.java:512)
>         at java.security.AccessController.doPrivileged(Native Method)
>         at java.awt.Toolkit.getDefaultToolkit(Toolkit.java:503)
>         at java.awt.Toolkit.getEventQueue(Toolkit.java:1150)
>         at java.awt.EventQueue.invokeLater(EventQueue.java:511)
>         at 
> javax.swing.SwingUtilities.invokeLater(SwingUtilities.java:1091)
>         at javax.swing.Timer.post(Timer.java:342)
>         at 
> javax.swing.TimerQueue.postExpiredTimers(TimerQueue.java:195)
>         at javax.swing.TimerQueue.run(TimerQueue.java:231)
>         at java.lang.Thread.run(Thread.java:484)
> 
> Huh !! I do not need X-server !!! I just want to use a pair of Swing
> classes.
> 
> Anybody know what to do ???
> 
> 
> --
> To unsubscribe:   <ma...@jakarta.apache.org>
> For additional commands: <ma...@jakarta.apache.org>
> Troubles with the list: <ma...@jakarta.apache.org>
> 

--
To unsubscribe:   <ma...@jakarta.apache.org>
For additional commands: <ma...@jakarta.apache.org>
Troubles with the list: <ma...@jakarta.apache.org>