Show ‘n Tell Thursday: Maximizing tabs in DDE (20 October 2011)


It has been a looooooooooooooooong time since I did a SnTT but I found it fitting for this week. The tip is short and very straight forward but will make it easier and more productive for you to work in Domino Designer on Eclipse (DDE).

If you are like me like the navigator in DDE is on the left, and the outline/controls/data views are on the right. You realize that you do not have much space left for code in the center editor. Bummer! 😦 To help remedy that you may either minimize or close the views on the right but that really isn’t ideal as it takes time and some times you need the views e.g. for XPages work. As an alternative you could figure out which views you use for what tasks and create custom perspectives in DDE for those tasks which isn’t for the Eclipse-superuser. You could also choose the easy solution – simply maximize the editor.

Maximizing the editor is easy. You simply double-click the tab or press Ctrl-M to make the editor go fullscreen. When done you simply double-click the tab again or press Ctrl-M to return it to being “in the middle”. Easy and quick.

Hope it works as nicely for you as it does for me.

Ytria EZ Suite 10 – now with DDE integration

A couple of days ago I received an e-mail from Ytria telling me that a new version of the Ytria tools was available and that I could go a read about what’s new in EZ Suite 10. I did and I was impressed. Now I have been a user of the Ytria tools for a couple of years and have always been impressed by the ease of use and the power of the tools.

The EZ Suite has always been separate applications and something you launched alongside Notes or Domino Designer (albeit from a SmartIcon) but in version 10 they take it to the next level by providing integration directly into Domino Designer on Eclipse (DDE). This is really cool and provides right-click action to many of of the tools include nifty stuff such as signing a design element with another id-file. Good work by the team at Ytria and the tools is definitely still part of my arsenal.

Disclaimer: I have a free version of the EZ Suite courtesy of Ytria.

Extending DDE – creating custom context menus

Part of my new LotusScript.doc release is of course finding ways to make it even easier to use and use the API that’s now supplied as part of LotusScript.doc. Central to all this is extending DDE to make LotusScript.doc accessible in a variety of ways. Today I’ll show you how to add context, i.e. right-click, menus to the DDE navigator on the left as you can see below.

Doing this is actually very easy and only comprises of an IViewActionDelegate (the code; implement org.eclipse.ui.IViewActionDelegate) and a entry in plugin.xml to indicate where to stick the action. In this case it’s an objectContribution to org.eclipse.ui.popupMenus:

<extension point="org.eclipse.ui.popupMenus">
   <objectContribution adaptable="true"
      id="com.lekkimworld.dde.navctxmenu.objectContribution"
      objectClass="org.eclipse.core.resources.IFile">
      <action
         class="com.lekkimworld.dde.navctxmenu.MyContextAction"
         enablesFor="2+"
         id="com.lekkimworld.dde.navctxmenu.action"
         label="DDE context stuff (select min. 2 design elements)"
         menubarPath="additions"
         style="push">
      </action>
   </objectContribution>
</extension>

The above should be pretty much self-explanatory.

The example code is available for download as an Eclipse project: com.lekkimworld.dde.navctxmenu.zip

DDE keybindings and preferences

Domino Designer on Eclipse (DDE) is a huge leap in the right direction for our IDE of choice. I agree there is room for improvement but be sure that IBM Lotus knows this as well. Having DDE is a big help in my day-to-day work and with the right key-combinations and the right tweaks to the preferences it can become even better. Below are some of the nice keybindings I find myself using all the time and the preference tweaks I always do.

  • Ctrl-F6
    Switch view – allows me to easily switch between editors using the keyboard
  • Alt-<arrow back>
    Back in history, not within same editor (i.e. when jumping lines) but between editors
  • Alt-<arrow forward>
    Forward in history, same as above
  • Ctrl-Alt-L
    Goto correct Erl() line

The last one is probably one of the most important functions you should know when making the transition to DDE. Many developers have discovered that the error line number reported by the Erl function in Notes isn’t necessarily the correct line when trying to locate the line in DDE. Is problem stems from the way the new LotusScript editor calculates line numbers. This is a *MAJOR* flaw IMHO as line numbering is so basic to an IDE that it should just work! This is however not the case but luckily IBM Lotus has provided us with the next best thing namely a function to convert the Erl() line number to an actual line number in DDE. Knowing the key combination to invoke it makes it less of a hazzle.

In the preferences I normally tweak are the following:

  • GeneralEditorsText Editors
    Show lines numbers
  • Domino DesignerLotusScript EditorFonts and Colors
    Minor tweaks to the default color setup to make code easier to read.
  • Domino DesignerLotusScript EditorRemove existing object code when saving with errors
    In DDE you may save LotusScript code with errors but then what should happen to the compiled object code (the code actually being run). Should it be removed or kept in place?

Besides all of the above a thing to remember is that DDE is a brand new beast and simply sitting down in front of it and using it without investing any time in getting to know it is pretty arrogant and probably also a little stupid. I really suggest spending some time getting to know it and making sure it looks, acts and feels like you want it to.

Why you should develop with the same version as your users use

Got a call from a customer running Notes 7 today. He told me that they were no longer able to search using the “Fill out example form” without getting an error message (“The linked document cannot be found in the view”). After looking into the matter and looking for the obvious first (ie. no default view in the database) I looked more carefully at the Fill Out Example Form dialog and saw some interesting entries in the form dropdown as shown below.

That’s right. Our new psudo-design elements (build.properties, plugin.xml, WEB-INF/faces-config.xml, .classpath, .project) generated by DDE (Domino Designer on Eclipse) shows up as forms in the search dialog and even worse as forms you can use to search with. Now I know it’s impossible to make future-proff software but on that’s not good. Nothing Lotus can do about it though.

So what’s the morale? Well be sure you know what effects using a newer Designer client may have on your users before using it. You have been warned…

Developing plug-ins for Domino Designer in Eclipse (DDE)

With Notes 8.5 just around the corner we also have Domino Designer for Eclipse (DDE) just around the corner. Domino Designer being built on Eclipse opens up the door for plug-in developers and tool vendors to provide tools that plug-in into Designer just like (sidebar) plug-ins plug into the Notes client. The API’s are the same so the stuff you already know can be reused.

Please note: The below requires that you’re running a Notes 8.5 beta with DDE and that your Eclipse IDE is configured for Notes 8.5. See this post for instructions on configuring Eclipse for Notes 8.5.

Developing plug-ins for DDE is however a little tricky as the Expeditor Toolkit or my own instructions will launch the Notes client and not DDE. Unfortunately you can’t just launch DDE once Notes is launched from Eclipse since this will result in a Notes initialization error as Notes is already running and DDE is launched anew. That aside it would also be unnecessarily time consuming for day-to-day development.

The solution is to edit your existing Eclipse launch configuration (or create a new) that launches DDE instead of Notes. So how do you do it? Read on…

First bring up your Notes launch configuration. Now change the “Run a product” dropdown to “com.ibm.designer.domino.product.dde” and then switch to the “Arguments”-tab and change the “Program arguments” field from

-personality com.ibm.rcp.platform.personality
-product com.ibm.notes.branding.notes
-debug
-console
-nl en_US

to

-personality com.ibm.designer.domino.personality
-product com.ibm.designer.domino.product.dde
-debug
-console
-nl en_US

Apply the settings and run the configuration and notice how DDE now launches instead of Notes. Don’t you just love Eclipse?

Now we just need some published extension points…

Launching DDE from the command line

Notes 8.5 brings Domino Designer in Eclipse (DDE) and this means you might want to launch Designer from the command line which is easy once you know the configuration name.

<Notes directory>frameworkrcprcplauncher.exe -config designer

Of cause you can also add the -console command line option to get the OSGi console.