Properties files
are text files with the
.Properties
extension, containing pairs of keys and values, that can be accessed and rendered in the UI.
These files are denoted with the icon
.
IntelliJ IDEA supports the following features for the properties files:
-
Syntax
key - delimiter - value. IntelliJ IDEA uses=(equal sign) or:(colon) as a delimiter.For example, if you want a field label to read "Your name:", you might create a pair in a properties file like this:
nameLabel=Your name:nameLabel: "Your name:" -
Error highlighting
for errors like duplicate property keys and invalid escape sequences:

-
Inspection and quick fix
for detecting and removing duplicate keys in properties files:

-
Referencing
properties from Java files and Ant build files.
-
Code completion for property keys:

-
Inspection and quick fix
for detecting and creating the missing property keys and values:

-
Goto Declaration
⌘B, ⌘Button1 Click, Button2 Click, ⌘B, ⌘Button1 Click or Button2 Click⌘B, ⌘Button1 Click, Button2 Click, ⌘B, ⌘Button1 Click or Button2 ClickF3, ⌃Button1 Click, F3 or ⌃Button1 ClickF12, ⇧ F2, ^ B, ^ Button1 Click, Button2 Click, F12, ⇧F2, ⌃B, ⌃Button1 Click, Button2 Click, F12, ⇧F2, ⌃B, ⌃Button1 Click or Button2 Click^ ⌥ G, Escape, Period, ⌥ Period, ^ Button1 Click, ⌃⌥G, ⎋, ., ⌥., ⌃Button1 Click, ⌃⌥G, ⎋, ., ⌥. or ⌃Button1 Click
to navigate from
a reference to a key to its declaration:

- Finding usages of the currently selected property.
- Refactoring for properties includes Rename, Move, Copy, Safe Delete, and Migrate.
-
Code completion for property keys:
-
Structure view
for properties files:

-
Quick Definition Lookup
for properties files:
if an action calls a property, you can view the property definition by pressing⌥Space, ⌘Y, ⌥Space or ⌘Y⇧⌘I or ⇧⌘I⌥Space, ⌘Y, ⌥Space or ⌘Y^ ⇧ I, ⌃⇧I or ⌃⇧I^ ⇧ I, ⌃⇧I or ⌃⇧I:

