Java Reference
In-Depth Information
If you're developing
JSP
applications, you'll most likely benefit from these new
web content features either in the context of the
JSP
pages or through content
associated with those pages as just described. Consider for a moment, however,
that using
IDEA
as your development environment for other types of web projects
also offers plenty of benefits, even for projects that don't involve any Java or
JSP
code. In addition to the improved integration and new features for web content
in
IDEA
5.0, you can take advantage of these other
IDEA
features:
Integrated version control and local history
■
A powerful, customizable source code editor
■
Rich search, replace, and navigation features
■
Familiar keystrokes and interface
■
Editor bookmarks, macros, templates, and other features
■
11.5.2
Basic editor features
Many of the core features of
IDEA
's editor are available to web content files. Some
of these, such as search and replace, macros, bookmarks, navigation, and selec-
tion, are language agnostic and work as well with
HTML
or JavaScript as they do
with Java or
JSP
. We've covered these features in detail earlier in the topic, so no
additional commentary is necessary, other than pointing out that they're avail-
able when you're editing web content files. Other features, although they work
similarly to the way they do in Java, are worth elaborating on.
Editor options
Most of the relevant editor options, such as Smart Keys, brace and scope high-
lighting, paired tags, quotes, brackets, and so forth, are now active in web content
files. The standard code-folding features of the
IDEA
editor are also supported.
These are available in
HTML
,
CSS
stylesheets and blocks, and JavaScript files and
embedded scripts.
Formatting web content files
You can format JavaScript,
CSS
, and
HTML
files through the
Code | Reformat
Code
feature (
Ctrl+Alt+L
). You control the formatting, as with Java files,
through the
Code Style
settings panel. Although each of these file types inherits
basic code style settings such as tab size, indention rules, and blank line handling
from the core code style settings,
HTML
has its own tab under
Code Style
settings
that lets you fine-tune its formatting, as shown in figure 11.23. Additional options
for formatting
CSS
and JavaScript files were planned for the final release.