My question is a bit strange.
I want my created form (with JFrame) coloration should be like to this picture:
Should i use a special look and feel ?
My question is a bit strange.
I want my created form (with JFrame) coloration should be like to this picture:
Should i use a special look and feel ?
there is no such built-in Look&Feel available as much as i know. However for "Look&Feel", "Look" refers to the appearance of GUI widgets (more formally, JComponents) and "feel" refers to the way the widgets behave. If so, then we can always make our Swing component to be appeared as we want in the GUI.
Advanced responsive applications which are graphically rich ooze cool, sucking users in from the outset and hang onto them with a death grip of excitement. They make users tell their friends about the applications.
However, to develop graphically rich Swing application we must know how to render custom graphics on component, making them to appear as we want( with shiny color, beautiful texture, moving animation, nice typography). We need to learn how to layout the component properly to arrange them one relative to another. From answering your various question, i came to understand that you want to be a swing geek. Well:
JPanel, JLabel, JButton, JList, JTable, JTextPane
etc) and various type of Event listeners and how they responds with the component.Layout Managers
. There are other advanced level layout manager available which makes life easier but learn about the standard managers first.Graphics
andGraphics2D
class for rendering carious type of geometric object, image rendering, texturing, gradient painting etc.Now, A Demo Example for you:
I have tried to make the application as much short and simple as possible. But there are somethings i have done to achieve your requested GUI, which you should not do, if you don't know how they work, (for example overriding the
paint()
function). In this example i could not collect a texture as the image you have provided. But i have used a fabric texture. The application needs to load the texture image first. keep your eye on the console. It will show following message prior to run the application:I have used:
GridBagLayout
as the MainContainer's pane layout manager. Have a look at the code thoroughly and read about corresponding extension(extending JCompononent and JButton) and painting i have made to achieve a nicer GUI(Well not so much nicer to many critics, but for DEMO....)Demo Source code: