[ANN] IDEA Doc RC1 + Article on writing plugins

About two weeks ago I uploaded IDEA Doc plugin RC1. I haven't announced it here yet, because first I wanted to finish my article on writing IDEA plugins, which is based on the IDEA Doc plugin.

I just finished writing that article. You can read it on http://www.piraya.nl/IDEAPlugins.html

Comments are welcome. English is not my first language and IDEA Doc is my first plugin, so there's bound to be some mistakes in there :o)

The manual for the IDEA Doc plugin can be found at http://www.piraya.nl/ideadocManual.html.

4 comments
Comment actions Permalink

Hello Onno,

OS> About two weeks ago I uploaded IDEA Doc plugin RC1. I haven't
OS> announced it here yet, because first I wanted to finish my article
OS> on writing IDEA plugins, which is based on the IDEA Doc plugin.
OS>
OS> I just finished writing that article. You can read it on
OS> http://www.piraya.nl/IDEAPlugins.html

Thanks a lot for publishing this article! Would you mind if we post a link
to it from the http://www.jetbrains.com/idea/plugins/plugin_developers.html
page?

Some clarifications and notes on plugin code:
- means that the ]]> tag can be used
- AnActionEvent.getDataContext() is never null and doesn't need to be checked
- much of the code in JavadocInserter.run() can be replaced with a call to
PsiUtil.getTopLevelClass()
- instead of the isWritable() check, you should call ReadonlyStatusHandler.getInstance().ensureFilesWritable()
to initiate automatic checkout for files under version control, and check
the returned result
- instead of FileTypeManager.getInstance().getFileTypeByExtension("java"),
you should use StdFileTypes.JAVA
- IdeaDocConfiguration.getIcon() should use the IconLoader class
- you can use DefaultJDOMExternalizer to implement readExternal()/writeExternal(),
although if you do that, it's better to split the configurable and the configuration
into two different classes

Anyone else want a code review of their plugins? :)

--
Dmitry Jemerov
Software Developer
http://www.jetbrains.com/
"Develop with Pleasure!"


0
Comment actions Permalink

Thanks a lot for publishing this article! Would you
mind if we post a link to it from the
http://www.jetbrains.com/idea/plugins/plugin_developers.html
page?


Hi Dmitry,

I don't mind if you add a link to it. That's what it's there for. I hope it may be helpful to as many people as possible.

And thanks for the feedback on the code, I'll try to fix these issues as soon as possible.

Regards,

Onno

0
Comment actions Permalink

Dmitry Jemerov wrote:

Anyone else want a code review of their plugins? :)


Are you starting a new business? :)) I maintain this tiny 726 source
file plugin called InspectionGadgets you might want to take a look at;-)
And will you still provide this service when the "IntelliJ IDEAL Plugin"
contest starts tomorrow?

0
Comment actions Permalink

Hello Bas,

>> Anyone else want a code review of their plugins? :)
>>
BL> Are you starting a new business? :)) I maintain this tiny 726
BL> source file plugin called InspectionGadgets you might want to take a
BL> look at;-) And will you still provide this service when the
BL> "IntelliJ IDEAL Plugin" contest starts tomorrow?

I think that most of the code of IG is good enough as it is now, and doesn't
really need a review that much. :)

--
Dmitry Jemerov
Software Developer
http://www.jetbrains.com/
"Develop with Pleasure!"


0

Please sign in to leave a comment.