Is there any eclipse shortcut/trick/plugin/whatever that will allow me to select a section of text and surround it with an arbitrary html/xml tag when using the html editor.
Something like this textmate video
All attributes are optional. The BODY tag surrounds all the content of your site. It allows you to set the look and feel of your site through its attributes.
An opening tag begins a section of page content, and a closing tag ends it. For example, to markup a section of text as a paragraph, you would open the paragraph with an opening paragraph tag <p> and close it with a closing paragraph tag </p> (closing tags always proceed the element with a /).
In general, they make a document easier to read by breaking up a large document into smaller parts, each part having a heading that has different formatting (larger text, bold, etc.), than the rest of the document.
EDIT: not sure If my Eclipse setup is the same as yours, but...
I have the HTML Editor installed, and if I switch to the Java perspective, I can use Edit -> Quick Fix
and then choose Surround with new element
to get exactly the effect in your video. (On a Mac, the shortcut for this is ⌘1).
Hope this is helpful.
In the C++ editor, you can try Source -> Surround With... -> Configure Templates
to add the tag you want.
The following works and allows for entering random/arbitrary tags:
However there is an annoyance, please upvote Bug 494169
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With