What is color in awt, JAVA Programming

Assignment Help:

What is Color in AWT?

Color is a class in the AWT. Individual colors such as red or mauve are examples of this class, java.awt.Color. Be sure to import it if you want to use other than the default colors. You form new colors using the same RGB triples in which you use to set background colors on web pages. Therefore you use decimal numbers instead of the hex values used through HTML's bgcolor attribute. For instance medium gray is Color(127, 127, 127). Pure white is Color(255, 255, 255). Pure red is (255, 0, 0) and so on. As with any variable you should provide your colors descriptive names. For instance

Color medGray = new Color(127, 127, 127);
Color cream = new Color(255, 231, 187);
Color lightGreen = new Color(0, 55, 0);

A few of the most common colors are available by name. These are

• Color.black
• Color.blue
• Color.cyan
• Color.darkGray
• Color.gray
• Color.green
• Color.lightGray
• Color.magenta
• Color.orange
• Color.pink
• Color.red
• Color.white
• Color.yellow


Related Discussions:- What is color in awt

Compare an abstract class and an interface , You want the base class to rep...

You want the base class to represent only an interface for its derived classes. That means, you don't want anyone to actually instantiate an object of the parent class. You only

Difference between java mail and jms queue, JMS is the ideal high-performan...

JMS is the ideal high-performance messaging stage for intra business messaging, with full programmatic control over quality of service and delivery options. JavaMail gives lowes

Arraya, what is arrays and how do they operate

what is arrays and how do they operate

What are the basic advantages of jms, JMS is asynchronous in nature. Theref...

JMS is asynchronous in nature. Therefore not all the pieces need to be up all the time for the application to function as a whole. Even if the receiver is down the MOM will kept th

About object, How memory allocated for a object

How memory allocated for a object

Describe tostring() methods, Describe toString() Methods ? Print method...

Describe toString() Methods ? Print methods are general in some languages, but most Java programs operate differently. You can use System.out.println() to print any object. The

Add wordpress color picker to plug-in text field, Add WordPress color picke...

Add WordPress color picker to plug-in text field Project Description: I have a simple plug-in that needs the built-in Word Press color picker added to one of the text input f

Explain how many ways businesses monitor their employees, Explain how many ...

Explain how many ways businesses monitor their employees? • Systems are available which monitor almost every key stroke that an employee forms on a computer. • Systems are avai

Define the n-tier architecture or j2ee 3-tier?, Normal 0 false ...

Normal 0 false false false EN-US X-NONE X-NONE

Plug-in for adobe after effects, Plug-in for Adobe after Effects Project...

Plug-in for Adobe after Effects Project Description: We are seeking software engineers to create a plug-in for Adobe after Effects (CS4 and above) that allows 3D extrusions f

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd