Results 1 to 14 of 14
Thread: Desktop Icons Applications
- 06-26-2009, 05:20 AM #1
Member
- Join Date
- Aug 2007
- Posts
- 40
- Rep Power
- 0
Desktop Icons Applications
I have some utilities programs (.jar files that are made in java) for personnel department...Presently I provide the icons of .jar files to the user. Now, I want to club all classes within these .jar files into one single java program.
But I do not want to use Menu Bar OR Tool Bar. Instead, I want to use a desktop screen that contains icons for executing my programs by double click and one status bar that will show Information about my program
How can do such kind of desktop application in JAVA?
JDesktopPane is used for desktop application but I want to put icon within it.
You may understand my exact requirement by attached image.
I also provide you link of program:-
Share your files quickly, secure and easy (simillar program, i want to create in JAVA)
please give me some idea...
- 06-26-2009, 06:21 AM #2
- Join Date
- Jul 2007
- Location
- Colombo, Sri Lanka
- Posts
- 11,374
- Blog Entries
- 1
- Rep Power
- 18
Use a JFrame with undecorated false. Once you set it to false, you cannot see any title bar on the top. Even in default you can't see menu bars in JFrame. Set the size dynamically to same as the desktop you want to place on.
- 06-26-2009, 09:35 AM #3
You can also make a transparent JPanel,drawing on the JPanel an image area which is at the back of the undecorated JFrame, to add the WindowListener to the JFrame, each time when you move the JFrame update this image, such way you will get a transparent window, I did much desktop widgets in this way
- 06-26-2009, 03:12 PM #4
Member
- Join Date
- Aug 2007
- Posts
- 40
- Rep Power
- 0
Thanks for suggessions.
I want to put images/icons with caption into Desktop Pane
Drawing the image in panel is very tough process. Is there any eaisest way as like we can see in VB language where image control is found to place directly into form.
- 06-26-2009, 05:45 PM #5
- Join Date
- Jul 2007
- Location
- Colombo, Sri Lanka
- Posts
- 11,374
- Blog Entries
- 1
- Rep Power
- 18
The way serjant explain is really nice.
On the other way, which I explain you can use labels easily on the frame, and add images to those labels. That's the most easiest way I can see.
- 06-26-2009, 05:45 PM #6
- Join Date
- Jul 2007
- Location
- Colombo, Sri Lanka
- Posts
- 11,374
- Blog Entries
- 1
- Rep Power
- 18
The way serjant explain is really nice.
On the other way, which I explain you can use labels easily on the frame, and add images to those labels. That's the most easiest way I can see.
- 06-26-2009, 09:58 PM #7
Use a GridLayout with JButtons that have setContentAreaFilled(false) and setBorderPainted(false). You may also want to setRolloverEnabled(false).
Set an icon and text to each button, and setHorizontalTextPosition(SwingConstants.CENTER) / setVerticalTextPosition(SwingConstants.TOP)
db
- 06-27-2009, 11:43 AM #8
Member
- Join Date
- Aug 2007
- Posts
- 40
- Rep Power
- 0
JLabel can not be slected
I have already tried it but Two problem with Label is:-
1. We can not select JLable
2. Text/Caption is not appearing at the bottom of Image Label however text position property is set.
Thanks Burke, I will try it; I hope JButton is best to solve my problem and your idea will work.Use a GridLayout with JButtons that have setContentAreaFilled(false) and setBorderPainted(false). You may also want to setRolloverEnabled(false).
Set an icon and text to each button, and setHorizontalTextPosition(SwingConstants.CENTER) / setVerticalTextPosition(SwingConstants.TOP)
- 06-27-2009, 05:53 PM #9
- Join Date
- Jul 2007
- Location
- Colombo, Sri Lanka
- Posts
- 11,374
- Blog Entries
- 1
- Rep Power
- 18
- 06-28-2009, 02:23 AM #10
A year ago I made some Carousel widget(transparent) where you can add launch applications, I will attach it here tomorrow, you can use it free it
- 06-28-2009, 07:53 AM #11
Member
- Join Date
- Aug 2007
- Posts
- 40
- Rep Power
- 0
Sir, I know the uses of mouse listener with JLabel...my meant that when we click on image/icon then it should be look like selected which is not possible with JLabel...Please download the .exe file from CALCULATIONS.exe and then execute it to better understand my problem....Thanks
I am waiting serjant...Last edited by Gajesh Tripathi; 06-28-2009 at 08:36 AM. Reason: Wrong Link was provided
- 06-28-2009, 10:29 AM #12
Here is the jar file:
Carousel.jar
The launchers will not launch the programs, because they are initiated for Linux, but you can edit them in CarouselFinal.java class :
http://rapidshare.com/files/24950544...ck.tar.gz.html
Open the project in Eclipse, Open CarouselFinal class, String[] commands array is the array where you insert the launch command for the application,
carousel.add command adds image and the name of the application. If there are any questions, contact me. I think this application will help you
Here is the source:Last edited by serjant; 06-28-2009 at 10:31 AM.
- 06-29-2009, 09:43 AM #13
Member
- Join Date
- Aug 2007
- Posts
- 40
- Rep Power
- 0
[SOLVED] Desktop Icons Application
Dear Brova, My problem is solved after using your concept with JButton....Thank you very much.
I made a sample program that fulfill my requirement (as per Brova's suggession) and it will be helpful for others that want to create simillar desktop icon application. Please note that I did not register any action listener for buttons. Instead, I used key listener on button: Left,Right,Up,Down key to transfer focus & Enter key to call double click mouse event for that button. {.jar file is also attached to execute this sample program directly}
Dear Serjant, Your program is very impresive. Please provide me .zip link for CarouselFinal.java to open with Windowsbut you can edit them in CarouselFinal.java class
RapidShare: Easy FilehostingLast edited by Gajesh Tripathi; 06-29-2009 at 11:01 AM. Reason: Forgot to attach source file
- 07-01-2009, 09:40 AM #14
Similar Threads
-
how to compare icons
By panic in forum New To JavaReplies: 9Last Post: 05-21-2009, 08:16 AM -
is there anyone how can help me with image icons please?
By xbox_nutter in forum New To JavaReplies: 4Last Post: 03-27-2009, 10:26 AM -
[SOLVED] Turkish Characters in Java desktop Swing applications?
By doganc in forum Advanced JavaReplies: 6Last Post: 03-06-2009, 09:51 PM -
[SOLVED] Icons path
By janpol1 in forum EclipseReplies: 1Last Post: 03-03-2009, 12:31 PM -
Moving icons on your desktop
By Leprechaun in forum New To JavaReplies: 3Last Post: 12-14-2007, 10:07 AM


LinkBack URL
About LinkBacks
Reply With Quote

Bookmarks