This week's book giveaway is in the Design forum.
We're giving away four copies of Building Microservices and have Sam Newman on-line!
See this thread for details.
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 Building Microservices this week in the Design 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: 24190
    
  34

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
Rancher

Joined: Mar 22, 2005
Posts: 42958
    
  73
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.
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
Rancher

Joined: Mar 22, 2005
Posts: 42958
    
  73
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’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com
 
subject: combining controls and graphics
 
It's not a secret anymore!