LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 11-07-2008, 01:33 PM   #1
ahurd
Member
 
Registered: Sep 2007
Posts: 76

Rep: Reputation: 15
Want panel button for stand alone java program


I am on Kubuntu 8.04. I have downloaded (unixmacrosx.jar) and installed (jar xf unixmacrosx.jar) a stand alone java program. I can run it with terminal command

java -cp jts.jarluginsupport.jar:riskfeed.jar:hsqldb.jar:jcommon-1.0.12.jar:jfreechart-1.0.9.jar:jhall.jarther.jar:rss.jar -Xmx256M jclient.Login

but would like to have a button on toolbar panel to click to launch it. How can I achieve this? Thanks.
 
Old 11-07-2008, 02:20 PM   #2
David the H.
Bash Guru
 
Registered: Jun 2004
Location: Osaka, Japan
Distribution: Arch + Xfce
Posts: 6,852

Rep: Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037
It should be fairly easy. Just add a program button shortcut to the toolbar (using the "non-kde application launcher" applet) and put the startup line in the "executable" field. If the command runs in a terminal, then in most cases it will also run when the shortcut is clicked.

Edit: apparently the non-kde applet works a bit differently from the regular kde launcher. It looks like add only the "java" command to the "executable" field, and put the rest of the command arguments in the next field below it.

BTW, if for whatever reason a command won't work from the shortcut, but does run from the console, you can also check the "run in terminal" box so that it opens up a console first, then runs the command in it.

Last edited by David the H.; 11-07-2008 at 02:29 PM.
 
Old 11-07-2008, 03:59 PM   #3
ahurd
Member
 
Registered: Sep 2007
Posts: 76

Original Poster
Rep: Reputation: 15
Many thanks. Will try that.
 
Old 11-07-2008, 05:06 PM   #4
ahurd
Member
 
Registered: Sep 2007
Posts: 76

Original Poster
Rep: Reputation: 15
Problem. When I click on Add Applet to Panel I do not see "non-kde application launcher" anywhere. What is happening?
 
Old 11-08-2008, 11:32 PM   #5
ahurd
Member
 
Registered: Sep 2007
Posts: 76

Original Poster
Rep: Reputation: 15
Must be blind. Found non-kde application launcher by scrolling down. Put java command in as executable and got panel button. However when it is clicked nothing happens. Is this possibly because in terminal I needed to cd to a directory before executing jave command. If so how do I set up a cd to appropriate directory in setting up appln launcher?
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Missing button in gnome panel! tauro_kpo Linux - Software 4 06-05-2007 10:48 PM
desktop access button on panel sailu_mvn Linux - Software 5 03-30-2006 05:14 AM
how to add desktop access button to panel? host Fedora 2 02-28-2006 09:46 PM
The button of the window disappeared from bottom panel septanla Linux - General 2 01-24-2006 09:46 PM
Is there a way to get a 'new terminal' button on the panel? Tyir Linux - General 4 11-02-2003 12:21 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 09:32 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration