<< March 2009 | Home | May 2009 >>

Lotus Notes version to Lotus Symphony version map

Major props to John Head for providing me with the below info - and from memory!! :-)

Notes 8.0.0 --> "IBM Productivity Editors" (pre-Symphony)
Notes 8.0.1 --> Lotus Symphony 1.0
Notes 8.0.2 --> Lotus Symphony 1.1
Notes 8.5.0 --> Lotus Symphony 1.2
Notes 8.0.3 --> ??
Notes 8.5.1 --> Lotus Symphony 1.3

Tags : ,

By popular demand - scaling images in Java for Lotus Connections

After blogging about how Lotus Connetions teaches you to scale images in Java the other day I was contacted by Lotus Support who really would like to see the code as customers were asking for such code. Mitch also forwarded me a response from Lotus Support where they referred to my blog post which I got a real kick out of... :-)

So here's the code. Thanks to the customer for allowing me to blog the code. Use to your hearts content but don't blame me if it doesn't work for you. The disclaimer is there for a reason.

import java.awt.Color;
import java.awt.Graphics2D;
import java.awt.Image;
import java.awt.geom.AffineTransform;
import java.awt.image.BufferedImage;
import java.io.File;
import java.io.FileInputStream;
import java.io.IOError;
import java.io.IOException;

import javax.imageio.ImageIO;

public class ScalePicture {
  
  public static void main(String[] args) {
    try {
      File f = new File("d:\\images");
      File pictSrc = new File(f, "source_photo.jpg");
      File pictDest = new File(f, "destination_photo.jpg");
      if (pictDest.exists()) {
        System.out.println("deleting...");
        pictDest.delete();
      }
      
      // scale image
      BufferedImage img = scaleImage(pictSrc);
      
      // write to target image
      ImageIO.write(img, "jpg", pictDest);
      
    } catch (Throwable t) {
      t.printStackTrace();
    }
  }
  
  private static BufferedImage scaleImage(File source) 
    throws IOException {
    // declarations
    final int width = 115;
    final int height = 115;
    
    // read source image
    BufferedImage imgSrc = ImageIO.read(source);
    
    // calculate scale factor
    double scaleFactor = (double)imgSrc.getWidth() / 
      (double)width;
    
    // scale image
    BufferedImage imgScaled = new BufferedImage((int)
      (scaleFactor * 100), height,
      BufferedImage.TYPE_INT_RGB);
    AffineTransform transform = AffineTransform.
      getScaleInstance(scaleFactor, scaleFactor);
    Graphics2D g = imgScaled.createGraphics();
    g.drawRenderedImage(imgSrc, transform);
    g.dispose();
    
    // create new target image in correct size 
    // with white background
    BufferedImage imgResized = new BufferedImage(width, 
      height, 
      BufferedImage.TYPE_INT_RGB);
    g = imgResized.createGraphics();
    g.setBackground(Color.WHITE);
    g.fillRect(0, 0, width, height);
    
    // calculate offset for scaled image on new image
    int xoffset = (int)((double)(width - imgScaled.getWidth()) / 
      (double)2);
    
    // draw scaled image on new image
    g.drawImage(imgScaled, xoffset, 0, null);
    g.dispose();
    
    // return new image
    return imgResized;
  }

}

Allowing diagnostic data to be sent to IBM

What if the CRASH_SENDTOIBM notes.ini setting was set for all new Domino Server installations; imagine how much diagnostic information that IBM would gather that would make the product better for all of us? I know there are privacy concerns and test servers but still...

"When the Notes.INI setting CRASH_SENDTOIBM=1 is set on the server, no additional configuration is required. When the server restarts after a server crash, diagnostic information is collected and an email is sent to IBM."

Technote 1321120: Allowing diagnostic data to be sent to IBM

JavaPosse episode 245 on OSGi

I listened to the JavaPosse podcast episode 245 today during my commute. The podcast was very interesting as it is an interview with Peter Kriens (of aQute) and B.J. Hargrave (of IBM) the two specification leads on OSGi. OSGi off cause being the bundle management system of Eclipse and hence your most beloved Notes client. Worth a listen for sure.

Tags : ,

Lotus Symphony in-depth product comparison white paper

Received this from a colleague today and thought I would shere. The link takes you into PartnerWorld so I guess you need an account for that to read the document. Although it says "share this paper with your prospects" I don't know I may post an unprotected version.

Lotus Symphony in-depth product comparison white paper
This new white paper provides you and your customers with a broad, detailed comparison of Lotus Symphony 1.2, Microsoft Office 2003, 2007 and OpenOffice.org 3.0. Share this paper with your prospects so they see how Lotus Symphony is the obvious alternative to proprietary office productivity software. Available at no charge, Lotus Symphony is helping businesses control software acquisition and upgrade costs everywhere, supporting over 28 languages.

Lotus Symphony in-depth product comparison white paper

Eclipse Talk Podcast

Eclipse Talk Podcast in iTunes. I haven't listened to the podcast yet but it looks interesting.

TwitNotes 1.0.10

Today I saw that suddenly TwitNotes wasn't displaying any tweets. I could tweet and search from it just fine but the main timeline wasn't displayed. I traced the issue to an error with the utc_offset handling in the Twitter JSON API I forked back when... I have now resolved the issue and placed a widget descriptor for TwitNotes 1.0.10 on the blog and corresponding features on the update site.

To update TwitNotes either

  • drag the widget descriptor onto your MyWidgets sidebar panel or...
  • do an update installed features operation (those this solution is right for knows how)

I wish to thank those who kindly reminded me of this problem - nice to see people using it.

At Dannotes today

Today I'm at the Danish Notes User Group (Dannotes) in Korsør here in Denmark. This time there is a very interesting lineup for this two day event as Gabriella Davis from the Tutle Partnership is here to present on admin stuff and Andre Guirard from IBM is here to present on the new an exiting stuff for appdev. I actually just had a nice chat with Andre which was nice.

I'm doing, what I hope will be, an inspirational session on what's possible in the Notes 8 client using widgets and some nice plug-ins. Should be fun.

Tags :

Find string in files on Linux

Note to self: find . | xargs grep 'string' -sl

Tags :

Configuring SSO between Lotus Domino and Lotus Connections

This morning I configured single-sign-on (SSO) between Lotus Connections and Lotus Domino and was again surprised by how easy it is. The steps are simple:

  1. Open the WAS server administration interface and go to Security > Secure administration, applications, and infrastructure > Authentication mechanisms and expiration.
  2. Select "Authentication mechanisms and expiration" in the "Authentication" section on the right hand side.
  3. Now in the "Cross-cell single sign-on" section specify a set of passwords and export the keys to a file on the file system.
  4. Move the file to your local file system.
  5. Now follow the guidelines in the Domino Administrator help for importing the keys into Domino LTPA configuration.

Lotus Connections teaches you how to scale images in Java

Lotus Connections is a little bit screwy when it comes to profile pictures IMHO as they are being forced to be square in Profiles (115x115 pixels). In profiles search results however they are scaled to 55 pixel in width and height is automatic...

In my mind portrait pictures are rectangular and not square.

Yesterday this gave me some grief as I was at a customer where I had to write Java code to import pictures in the PHOTO table of the Lotus Connections PEOPLEDB database. The actual importing the pictures into the database is easy using JDBC but the pictures showed up wrongly in Lotus Connections as they were rectangular (200 x 133 pixels). They clearly had to be scaled but how - clearly not manually!

As with many other things you are gifted with Java as it already contains all the pieces you need to scale pictures. I quickly found some sample code on Google to use java.awt for the resizing. The solution was to

  1. Scale the source image from 200 x 133 pixels to 115 x 76 pixels to keep the aspect ratio
  2. Create a new blank white image sized 115 x 115 pixels
  3. Place the resized source image on top of the white image centered
  4. Upload the resulting image to the database as a byte array

Love Java!

Eclipse match rules

From the Composite Application wiki comes a nice document on Defining feature and match rules. The difference between this an other such documents is that this one actually has some examples to illustrate the difference between Perfect, Equivalent, Compatible and greaterOrEqual.

Twitterbelion?

Received this YouTube video from my Twitter-doubting colleague... :-)

LTPA token generation in Java

Props to Miha Vitorovic for writing the Java code to generate LTPA tokens for cookie authentication in Domino. How that could be very useful. Go get it for yourself at The Domino cookie authentication.

Tags : , ,

Show 'n Tell Thursday: Configuring Ubuntu for Notes 8 plugin development (2 April 2009)

This weeks SnTT post is about configuring Eclipse on Ubuntu 8.0.4 for Notes plug-in development. I use Notes 8.5 but it should work equally well for Notes 8.0.x clients. Wan't to develop plug-ins? Well read on and do it on Ubuntu. Notes 8.x runs freakishly fast on Ubuntu. Read on...

Actually this is a cheat post as the steps are almost the same as for doing it on Windows. Most of the stuff has to do with platform differences. My post for doing it on Windows is here. I have updated this guide with steps for Linux. Enjoy!!

LotusLive.com going commercial - what will that mean for Lotusphere presentations?

So I just received an e-mail from LotusLive.com about the beta moving on to be a 45 day trial. What will that mean? Well for me only that I will no longer use LotusLive.com which isn't too much of a loss for me. The main issue is that I'll no longer have access to the Lotusphere 2009 presentations which is a shame. I thought the beauty of having the presentations there was that they would remain there... Unfortunately not.