Monday Apr 07, 2008

Some nifty XML editing add-ons

It was a long weekend here in India, and that provided me some time to add some shortcuts which will help users who author XML documents using NetBeans. I wrote a plugin which will add some context sensitive actions to the XML editor. I have just managed to add one action (Delete current attribute), but more are on the way. Actions planned are:

  • Jump to parent tag
  • Jump to next sibling tag
  • Jump to previous sibling tag
  • Jump to end tag (if at start tag)
  • Jump to start tag (if at end tag)
  • Jump to next attribute in a tag
  • Jump to previous attribute in a tag
  • Delete current tag (alongwith children)
  • Delete current attribute (alongwith it's value)
  • Delete value
  • Expand a short tag <a/> into the longer form <a></a>
  • Condense an empty tag <a></a> into it's shorter form <a/>

I am planning to upload the module on the Plugin portal soon. For now, here's a screen shot:

Before the action was selected:

After the action was selected (notice the name attribute is gone):


Monday Feb 25, 2008

XML and NetBeans

NetBeans never boasted of a good editor as compared to IntelliJ IDEA and Eclipse, but things took a complete turn when NetBeans 6.0 came out. And now that NetBeans has conquered Java developers with the shining new editor, NetBeans is going gung-ho for Groovy, Scala, Erlang and what not. Though I totally agree to Groovy and Scala becoming first class citizens in the NetBeans world, I personally feel that NetBeans needs to do something about nicely editing a 10 year old thing - XML.

Why, you might ask. Well, whatever web frameworks I have dealt with, Struts, Struts2, Spring MVC, JSF, require reasonable amount of configuration in XML. Hell, even many non web applications seem to use Spring and it's XML configuration files. Though the deal is now seeming in favor of POJOs with annotations, I don't think developer authored XML is dead, by any means.

In a series of upcoming posts, I plan to compare the XML editing landscape in Eclipse, IntelliJ IDEA and NetBeans. IMO, NetBeans has the weakest XML editor story, but I plan to make a wishlist out of this, hopefully someone will come along and take XML editing in NetBeans to new heights.
 

About

Rohan Ranade's musings on anything and everything.

Search

Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today