The XML Editor is included in several of the Eclipse IDE downloads. It has two view modes: in design mode, you can edit your XML as a tree; in source mode, you edit as text. By default, it opens in design mode, which may seem a little weird (Iโve added Bug 480036 to the list of EclipseCon Europe 2015 Hackathon bugs to consider changing this).
I use the XML editor infrequently, but it is based on the same technology as the HTML and PHP Editors (which has embedded HTML support) that I use pretty regularly. All three of these editors have a cool feature that I didnโt know existed until today.
๐ output
Put the cursor inโor highlight the text ofโa tag (either the open or the close tag), and hit ctrl+1. Select โRename in fileโ and type a new tag. Both the open and close tags are updated in one. Just like the similar functionality provided by the Java development tools, this is sensitive to context (i.e. it will change the right closing tag).
This is certainly more handy for XML editing, but I did manage to shave a few seconds off my day using it to convert <ol>..</ol> to <ul>..</ul> in some HTML. #littleVictories
For completeness, the XML Editor is already included in the following Mars Eclipse IDE Packages:
- Eclipse IDE for Java EE Developers
- Eclipse IDE for Java Developers
- Eclipse IDE for PHP Developers
- Eclipse IDE for Java and DSL Developers
- Eclipse IDE for RCP and RAP Developers
- Eclipse IDE for Automotive Software Developers
- Eclipse IDE for Java and Report Developers
- Eclipse IDE for Parallel Application Developers
You can add the XML Editor to any Eclipse IDE by adding the โEclipse XML Editor and Toolsโ feature from the Mars repository.
Thanks to Konstantin Komissarchik for compiling the list of IDEs and to Nitin Dahyabhai for highlighting the functionality.
| Reference: | Ctrl+1 in the Eclipse XML Editor from our JCG partner Wayne Beaton at the Eclipse Hints, Tips, and Random Musings blog. |
Thank you!
We will contact you soon.
Wayne BeatonOctober 21st, 2015Last Updated: October 21st, 2015

This site uses Akismet to reduce spam. Learn how your comment data is processed.