Java Reference
In-Depth Information
Abiding by coding standards is made even easier with
IDEA
's ability to help
manage JavaDoc and naming in
J2EE
applications. Configuration options for
these are located in the
Project Code Style
dialog; consult
IDEA
's documentation
to best take advantage of these features.
12.3 Customizing your color scheme
You've already seen the syntax highlighting features in the editor. As with code
styles,
IDEA
recognizes that everyone has their own color preferences. With this
in mind,
IDEA
provides a flexible system for specifying the color and style of
code in the editor. The color scheme you define determines not only the color
used in your source code, but also interface-related color properties such as the
current row, the cursor, line numbers, and so forth.
12.3.1
How IDEA uses color schemes
Syntax highlighting does more than make your code look pretty. It reveals code
structure, increases readability, and can alert you to errors in both syntax and
logic.
IDEA
uses your selected color scheme in the editor window and (to a lesser
extent) in your search results.
To get to the color scheme settings, bring up the
Settings
and click the
Colors
& Fonts
option. The color scheme editor is shown in figure 12.4. You can select
the scheme to edit through the
Scheme name
drop-down at the top of the panel.
A default scheme is provided, but it isn't editable; so, the first thing you should do
is to use the
Save As
button to save a copy of the default scheme using whatever
name you choose. Select the name to begin editing. You can change your color
scheme at any time, or define several and switch between them.
12.3.2
Editor properties
There are several sets of color scheme properties, organized into tabs by the type
of document they affect. Click the corresponding tab in the
Colors & Fonts
win-
dow to access the properties you can configure:
General—
Default text and backgrounds, editor markup, interface elements
■
Java—
Syntax and
API
usage used in Java files, and Java code in
JSP
s
■
HTML
—
Tags and comments in
HTML
files, and
HTML
tags in
JSP
s
■
XML
—
Ta g s i n
XML
documents
■
JSP
—
Tags specific to the
JSP
API
■