|
Simplifying Graphics With Java and Threads
Here's some code that EarthWeb's Alex Chaffee likes to use as an example of how Java can be used to simplify algorithms by combining graphics with threading to render complex graphics.
|
|
Project Swing and JavaTM 2D Graphics
Menus, Layouts, Styled Text, and Simple Geometry
Applications that interact with an end user typically have a graphical user interface (GUI) for presenting information and receiving inputs from users. A well designed GUI goes a long way towards making the user experience positive and productive, and to that end, the JavaTM programming language provides Project Swing and the Abstract Window Toolkit (AWT), which are complete libraries for designing, building, and powering GUIs for applets and applications.
|
|
Developing the Java 2DTM Art Applet Using ForteTM for Java Community Edition
This article takes a detailed look at Java 2DTM Cosmic Art Applet, Java 2DTM/Swing. Cosmic Art Applet was built with ForteTM for Java Community Edition. Forte offers a wide range of capabilities that make coding in the Java programming language faster and easier. At the end of the article, you can run the applet, and download the source code. But first, let's take a look at what the Cosmic Art Applet can do.
|
|
Java 2D Tutorial
This tutorial presents a quick introduction to the basics of Java2D and the use of the Graphics2D class in Java 1.2. It is not a tutorial on general Java programming, a tutorial on all of Java 1.2, or even a tutorial on programming with Swing or JFC.
|
|
Drawing Shapes in Java2D
With the AWT, you generally drew a shape by calling the drawXxx or fillXxx method of the Graphics object. In Java2D, you generally create a Shape object, then call either the draw or fill method of the Graphics2D object, supplying the Shape object as an argument.
|
|
Transparency in Java2D
Java2D permits you to assign transparency (alpha) values to drawing operations so that the underlying graphics partially shows through when you draw shapes or images.
|
|
Using Local Fonts in Java2D
You can use the same logical font names as in Java 1.1, namely Serif (e.g. Times), SansSerif (e.g. Helvetica or Arial), Monospaced (e.g. Courier), Dialog, and DialogInput.
|