aspose file tools*
The moose likes Swing / AWT / SWT and the fly likes combining controls and graphics Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "combining controls and graphics" Watch "combining controls and graphics" New topic
Author

combining controls and graphics

Nirmal JeyaChandra
Greenhorn

Joined: Aug 31, 2005
Posts: 25
How to combine controls and graphics in JApplet it is not working. Controls is not visible.

It works in java.applet but not properly when combined with threads.

Thanks in advance.
Ernest Friedman-Hill
author and iconoclast
Marshal

Joined: Jul 08, 2003
Posts: 24168
    
  30

What are you doing, exactly, that's not working?


[Jess in Action][AskingGoodQuestions]
Nirmal JeyaChandra
Greenhorn

Joined: Aug 31, 2005
Posts: 25

This is my program

[ UD: added CODE tags ]
[ January 09, 2006: Message edited by: Ulf Dittmer ]
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39578
    
  27
The JPanel "p" is never added to the GUI, so it -and everything it contains- won't be drawn.

I have added code tags to your post, which keep code much more readable. Next time you post code, please use them as well - they're accessible through the "CODE" button beneath the text entry field when you post.


Ping & DNS - updated with new look and Ping home screen widget
Nirmal JeyaChandra
Greenhorn

Joined: Aug 31, 2005
Posts: 25
How to add separate panel for drawing lines and separate panel for controls like buttons.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39578
    
  27
This seems more of a Swing question than an applet question, so I'm moving this to our GUI forum. Please continue the discussion there.
[ January 09, 2006: Message edited by: Ulf Dittmer ]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: combining controls and graphics
 
Similar Threads
adding controls to JFrame
Is there any canvas like component in JSF?
Correct this code for event handling.
Mixing Android GUI controls with game graphics
WA #1.....word association