Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

Preacher

[java] Look N Feel

This topic is 5421 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi developing a 3DChess game for a college project and i need a funky look n feel, just think to dexters lab. I have found it hard to get any tutorials ( got pointed to one on about.com but its gone now!) and looking at the basicLookNFeel classes can confuse you quickly. If anyone knows where to find any tutorials (sun seem to have nothing but design recomendation articles)or a repository of LookNFeels i can check out and maybe use i''d be very grateful Thanks

Share this post


Link to post
Share on other sites
Advertisement
Thanks Nuffsaid you gave me the address for about.com site before i think, for some reason they removed the book!! meh whatya gonna do, thanks for the help

Share this post


Link to post
Share on other sites
I''m wondering is it worth my while designing my own Look N Feel for the game.

i don''t need a complex one just to be able to handle simple dialogs, i''ve a limited time of four months and i also have to develop a 3DInterface (Xith3D) and design a pluggable architecture(hopfully)

How fast can a simple Look N Feel be developed?

Share this post


Link to post
Share on other sites
A simple one can be built pretty quickly. You just need to subclass one of the existing look and feel.

For example, subclass Metal and change the colours.

To subclass a look and feel you need to subclass every class that it contains. In Metal''s case, there are 39 classes.

It is pretty simple once you get the hang of it. Take a look at javax.swing.plaf.metal.MetalLookAndFeel.java. It is pretty well commented. It sets everything up. It tells the JVM which classes to use to do all the drawing and also sets up colour refs. It also sets up default short cuts/quick keys. The next thing you can look at are the xxxxxUI.java classes. You override the paint method if you want to change the way the component is drawn. In Metal''s case, you need to look at MetalButtonUI and BasicButtonUI(Metal''s parent class) to put it all together. Metal does not draw a fancy button, just overrides some of the actions and the colours.



First make it work, then make it fast. --Brian Kernighan

The problems of this world cannot possibly be solved by skeptics or cynics whose horizons are limited by the obvious realities. We need men and women who can dream of things that never were. - John Fitzgerald Kennedy(35th US President)

Do not interrupt your enemy when he is making a mistake. - Napolean Bonaparte

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!