Skip to main content

I Still Haven't Found What I'm Looking For

Posted by editor on March 27, 2007 at 7:03 AM PDT


Finding your way around at zoom == 500%

OK, a personal grudge: I hate horizontal scrollbars. Hate, hate, hate, hate, hate them. When I see a GUI that uses both vertical and horizonal scrollbars, particularly around a table, my first thought is always that the GUI needs a profound rethink. See Hack #21 in Swing Hacks for an example of how much I hate inappropriate horizontal scrolling: it tells readers to hit themselves in the head with the book if they think horizontal scrolling is the correct fix to the example's column-sizing problem. IMHO, the only defense is when the scrollbars are a view onto a single cohesive "thing", like a spreadsheet or an image... and even then they still tend to suck.

Author Slav Boleslawski agrees with me on this latter point. He's taking on the issue of providing better navigation and viewing of zoomed images in today's Feature Article, in which he writes:

When an image is larger than its container's display area, a scroll pane with scroll bars is commonly used to allow the user to move the image around the container's view. Scroll bars also give rough indication about the zoom level and how far away the displayed area of the image is from the top, bottom, left, and right edges of the image.

Scroll bars do not work well with zoomed images, especially at large zoom levels. In most cases, the user needs to use both the horizontal and vertical scroll bars to bring various areas of the image into the view. Scroll bars are also of little value when it comes to "having a larger picture": they say nothing about the areas adjacent to the area currently in the view.

What Slav offers instead is the topic of his article, A Navigable Image Panel. With a combination of GUI concepts drawn from the world of consumer electronics, plus a lot of Java 2D graphic cleverness, he offers a compelling GUI component that not only makes it easier to work with zoomed images, but also uses smart decisions about scaling algorithms to provide an optimal perforfmance/appearance trade-off.


In Java Today,

A new SDN article takes a look at International Enhancements in Java SE 6. "One important strength of the Java Platform, Standard Edition (Java SE) has always been its internationalization and localization support. The platform continues to evolve, and Java SE 6 provides developers even more control over how they access and use locale-sensitive resources in their applications. Java SE 6 provides the following major enhancements to its internationalization support..."

As noted by The Register and Slashdot, the JPC project at Oxford University has managed to emulate an x86 PC in Java. "JPC is a pure Java emulation of an x86 PC with fully virtual peripherals. It runs anywhere you have a JVM, whether x86, RISC, mobile phone, set-top box, possibly even your refrigerator!" An online demo applet will boot you into DOS, and doing a c: will take you to some game demos.

Pieter-Jan Savat has duplicated a popular graphic effect in his blog entry JBookPanel and the page turn effect: "Probably every magazine or newspaper that is available online uses a Flash animation together with the page turn effect to make the experience as realistic as possible for its readers. So I thought it might be neat to try and recreate this effect in Java. The result is the JBookPanel. It's basically a JPanel that uses a fixed set of images to draw its pages."


In today's Weblogs.

Brian