« April 2008 | Main | June 2008 »

May 2008

May 29, 2008

Up to my neck in SWT GUI

Last week, I discovered, to my dismay, that I need to write my own list widgets instead of using the built-in SWT widgets. The breaking point occurred when I found that I cannot have lists with variable height rows. I decided that this is something I cannot accept in my UI. I'm a strong believer in usability.

One week later, I'm a smarter man. Building my own list was nothing short of an eye-opening experience with SWT programming. Up until now I was on the SWT expressway. Sure, it will get you from A to B in the quickest way. However, you'll be missing out on everything around you. If you want to get to know a place, you need to take the B-roads, visit the small villages and... well, metaphor exhausted. 

Looking back at the journey, here's some thoughts:

  • SWT is very complex, especially if you don't have previous experience with similar widget frameworks like Swing, AWT, etc.
  • SWT is poorly documented, considering its' complexity and magnitude. Quality information on the net is scarce. I found myself digging into the sources of SWT again and again. True, the public interfaces and methods have good Javadoc. However, the rest of the code is poorly document. It sure make things harder.
  • From the reasons above, I found that it is much quicker to take a trial and error approach than to fully understand what's going on. My "SWT enlightenment" came when I decided to ditch that approach and really understand what's going on.

Bottom line: my UI works exactly as I wanted. I took advantage of the effort and added a couple more features which I couldn't with the oh-so-limited list widgets.

May 22, 2008

The Platform Ends Here

Dead-end I apologize for the somewhat grim title. I just couldn't help it. I'm working on my Eclipse plug-in, deep into shaping my UI. Working with SWT is fine, I don't have many complaints. Well, until I reached the border. SWT controls have many limitations. It's natural for a framework to have limitations. However, SWT is a framework suited for running on multiple platforms, which means it's the lowest common denominator.

I reached one of these borders this week - I found out that I cannot have a list with variable row height. All rows must be of the same height. Since I want a list with fixed width and word wrap and this is simply impossible without having huge gaps between the lines (each line will have the height of the tallest line). It's not the first time I come across such a limitation. For example, a few weeks ago I found that I cannot have a list without scrollbars. Yep. Even if I don't need them, they will always be there.

Each time I encounter such a block, it usually takes me time just to understand that this is a platform limitation. These limitations are tucked inside the Eclipse Bugzilla or in the Eclipse discussion forums (both not indexed by Google regular search, by the way). It is very time consuming.

My main option now is to simply create a list myself by using more basic controls. This means I'm going to have to write a lot of code which is already written inside the framework. That's mostly because the framework is very hard to extend. Most of the classes implementing the controls are specifically marked as "do not extend". That's mainly because of the implementation which is platform specific. I can understand the rationale.

What I can't understand is JFace. JFace is a neat little framework that works on top and with SWT to provide common tasks like working with lists, trees, etc. There are many important features there. However, this framework simply cannot be extended. It is fixed to the SWT widgets, which cannot be extended, so extending it is out of the question. Needless to say, there is no documentation what so ever on the topic.

Designing a reusable framework is a delicate task. It is far more complex than designing a framework which is to be used as is, without extensions. A reusable framework is measured by the amount of code you have to rewrite. In the case of JFace, it simply failed.

May 19, 2008

Upgrading to Leopard (finally)

Toleopard Almost 8 months after its' debut, I'm finally moving forward to Leopard, Mac OS X 10.5. For those not familiar with the Mac OS X versions, it's much like upgrading from Windows XP to Vista. I bought my copy a long time ago, but I've been postponing my transition because of several reasons:

  • I want to fully backup my system before upgrading and I didn't have the means. I'm glad to say that my new 500 GB Time Capsule is making its' way to me as I write these lines.
  • Since my Mac is not a home machine, but rather a critical business machine, I decided not to be an innovator in this case, although I did feel the itch. The third update (10.5.3, think of as SP3, how long did it take in XP?) will be released shortly and I think Apple engineers had enough time to squash most of the bugs.
  • Eclipse does not officially support Leopard. This will change with Ganymede (Eclipse 3.4), which is due in the upcoming weeks.

I read a lot about Leopard. I think the main features I'm looking forward to are:

  • Time machine. I like simplicity. I need backup but I don't like caring about it.
  • The new QuickLook for browsing documents without opening them.
  • Spaces, the virtual desktop support. I usually have a number of window "sets". It will be cool to be able to switch between them.
  • The updated Preview application with the ability to rearrange PDFs and resize images.
  • DTrace which supports Java.

Regarding the above picture. It is an amazing picture, IMHO. Too bad I didn't get it when Leopard was a big issue, I could've made a few bucks. It was shot in India, of course, as you can see from the Devanagari script. I took it in Pune, at the Katraj Zoo. They do have a Leopard there. A dangerous one.

PS. The picture is for sale, contact me for details or travel to Pune and get your own. :-)
 

May 13, 2008

There's more than one way to start

I'm an Israeli and I live in Tel Aviv. Israel has a very vibrant hi-tech community and startups are a huge industry here with many success stories. Nevertheless, Israel is a very small country. Considering that most of the hi-tech is located around the center of the country, the relevant area is much smaller than, say, the San Francisco Bay Area (for comparison, the Bay Area is about 7000 sq miles and Israel is about 8000 sq miles, more than half is a desert).

When it comes to the community of entrepreneurs and investors in Israel, it actually is a very "small world". Personally, I know several people who were part of successful startups that did commendable exists. People feel that, if they had some conversations with people who made it and heard a lecture from Yossi Vardi (to whom I have the utmost respect) they know what needs to be done. It seems that we've formed some acceptable formula which one should follow in order to succeed. When people meet me and I tell them about my startup they immediately ask how much money did I raise and if I have a patent. There seem to be a consensus around the road to success.

That's why I enjoyed the presentation given by David Heinemeier Hansson (DHH) from 37Signals in the Y-Combinator 2008 Startup School.  I recommend this presentation to anyone in this business. I took some notes, which I included hereunder. It fits perfectly with the way I chose, the way of the MicroISV. Maybe I won't make hundreds of millions of dollars, but I will be working for myself and I'll enjoy what I'm doing while making more than enough money in the process, or at least having a better shot at making money.

I find the presentation very inspiring and entertaining. Highly recommended. I hope that me taking notes won't discourage you from watching it anyway. You'll probably get more insights there.

My notes:

  • KISS business model - charge money for your service.
  • This is still hard, but the odds are better than trying to build the next facebook/YouTube. We hear about these exits around us and think - "this can happen to me", much like the fear of a plane crash which is rare...
  • Million dollars is still a lot of money. It's not that hard to make it and the odds are much better than making a billion dollars.
  • For that, you don't need to solve the problems of the world, you can just "open a nice Italian restaurant". Provide a service which does one thing a little better.
  • It's hard to sell services to consumers (example from Backpack). Consumers don't easily open their wallet when it comes to internet services (especially with all the freebies around).
  • The  "Fortune 5,000,000":
    • Essentially, the market segment of small businesses, even 1-5 people. This is the large space between the consumer and the "tiny enterprises".
    • This is an untapped market - many problems waiting to be solved.
    • It's much easier to sell here - people evaluate the product, like it and buy it. No huge investment in red tape, sales reps, etc.
    • Your obligation to the customers paying small amounts is far less binding than to huge customers paying millions (it they call, you'd better answer and do what they say).
    • You can read more about it in this 37Signals post.
  • The purpose is to enjoy your life...
    • There's a great advantage to not making your company huge (by taking VC money): you can call your own shots.
    • You can create a company which you'll enjoy working at and that's key.
    • Don't plan on working hard for two years and selling out for big bucks and leave the good life. It's not clear how good your life will be.
    • Plan to create a workplace you'd like to work in for the next 20 years.
  • You can be a small successful business and enjoy your work, like a small Italian restaurants. Don't use Facebook as your role model.
  • Crashes the term "viral marketing". Just providing a great service can create a "viral" effect, even if you charge money for it. It's just a new hype over something which has been around for ages. It also contradicts the notion that your have to launch fast to create a "viral effect".
  • Having less time is a huge benefit to most people. If you had just 5 hours a day for working you'll focus your time a lot better. You cannot be productive for 14 hours a day.
  • Most companies are not built over night. Don't be in a hurry.
  • It's never gone get less work. The practices your choose to adopt now will stick with you.
  • If you're charging money from your customers, scaling means more users. So scaling problems are a good thing.

About nWire

  • nWire Logo
    Browse & visualize all code association in one extremely powerful view, quick search for methods, fields and more. Boost your coding productivity in Eclipse™.
    Watch a 4 minute demo that will change the way you look at your code.
    Visit nwiresoftware.com

Twitter Updates

    follow me on Twitter
    My Photo

    My Other Accounts

    Delicious Digg Facebook FriendFeed Google Talk LinkedIn Reddit Twitter

    AddThis Social Bookmark Button
    Blog powered by TypePad
    Member since 05/2007