Switch between reference and value preview of string resources in the xml editor Switch between reference and value preview of string resources in the xml editor xml xml

Switch between reference and value preview of string resources in the xml editor


Click and bring the cursor to the string resource reference and press Ctrl+- (Cmd for Mac, minus/hyphen) and you'll see the preview.

It basically does a collapse all for the code and collapsed string resource references show the values as preview. Collapse all action can also be done from the menu if you are comfortable with mouse more than keyboard. Right-Click -> Folding > Collapse

To switch back press Ctrl++ (Cmd for Mac) with the cursor still on same reference.


You can go to Preferences => Appearance & Behavior => Editor => General => Code Folding and enable Android String References to always see the value of string resource in the java file.