[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1076
  • Last Modified:

My Color Chooser

I have been trying to teach myself java.  I have been using the Deitel & Deitel book Java How to Program, 5th Edition.  Does anyone know where I can find the solutions to the problems at the end of the chapters?  I wish I could look at the finished examples.  Anyway, I have been trying to do problem 14.12 and need to know how to do it.  Here is the question:

Declare a subclass of JPanel called MyColorChooser that provides three JSlider objects and three JTextField objects.  Each JSlider represents the values from 0-255 for the red, green and blue parts of a color.  Use the red, green and blue values as the arguments to the Color constructor to create a new Color object.  Display the current value of each JSlider, the JTextField should be changed accordingly.  Declare class MyColorChooser so it can be reused in other applications or applets.  Use your new GUI component as part of an applet that displays the current Color value by drawing a filled rectangle.
0
brassmon
Asked:
brassmon
  • 2
  • 2
3 Solutions
 
JavatmCommented:
Friend;

You might need to work for that on your own then. Anyways Im also using a Deitel & Deitel book
Java How to Program but I'm using the 3rd edition which is also good.

Here are some sites which can help you :

For Color Chooser :
http://java.sun.com/docs/books/tutorial/uiswing/components/colorchooser.html

For JSlider :
http://www.apl.jhu.edu/~hall/java/Swing-Tutorial/Swing-Tutorial-JSlider.html

For JTextField :
http://java.sun.com/docs/books/tutorial/uiswing/components/textfield.html

This old questions in EE will help you :

http://www.experts-exchange.com/Programming/Programming_Languages/Java/Q_11970879.html
http://www.experts-exchange.com/Programming/Programming_Languages/Java/Q_20449365.html

Hope it helps . . .
Javatm

0
 
JavatmCommented:
If you find it hard to do the old questions on EE can help you
with that just follow the links, thank you.

Javatm
0
 
jimmackCommented:
Considering the cost of the book, I think that this is probably a bit of a con, but it looks like the solutions are published in yet another book:

http://www.amazon.com/exec/obidos/tg/detail/-/013142579X/ref=pd_sim_books_2/104-9942625-3144764?v=glance&s=books
0
 
f_98Commented:
0
 
jimmackCommented:
;-)
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now