Java Tips Weblog

  • Blog Stats

    • 2,530,125 hits
  • Categories

  • Archives


Thanks for the various comments. We’ll try to keep you updated here when changes are made to the code so you can get a new copy.

The updates listed here have been made more than a month ago.

Recent updates (less than a month old) will be displayed on the blog home page.

August 21, 2011 – Moving Windows

  • Components can now be contained within the bounds of the parent container by using the setEdgeInsets() method.
  • The parent container can be layed out by using the setAutoLayout(…) method.
  • A Webstart demo was added to show some of these features..

June 14, 2011 – Table Button Column

  • The buttons can now display an Icon or text.

November 8, 2010 – Multisort Table Header Cell Renderer and Vertical Table Header Cell Renderer

  • Fixed a similar bug in the getIcon(…) override. Thanks again Mbg.

November 7, 2010 – Default Table Header Cell Renderer

  • Fixed a bug in the getIcon(…) method. Thanks Mbg.

October 30, 2010 – Wrap Layout

  • Components not initially displayed when used on a JDialog as the “owner frame” of the dialog was being validated, not the dialog itself.
  • When using DecoratedLookAndFeel, the frame width could be increased but not decreased. The minimum width calculation has be changed to support this.

Thanks to Piet for the suggestion in this posting

September 14, 2010 – Menu Scroller

  • Two methods added to scroll a specified item or index into the visible portion of the menu.

September 5, 2010 – Visual Font Designer

  • Version 2 released. Can now be used as a Font chooser, much on the lines of JColorChooser
  • Web Start demo lets you play with the new features and get a feel for the simplicity of the code required to use it.

June 16, 2010 – Resizing Components

  • when the bounds of a component are changed the component is also “validated”. This will allow you to resize a JScrollPane and have the component in the viewport also resized at the same time.

June 16, 2010 – HSL Color

  • the method “getComplimentary” was corrected to be “getComplementary”.

April 5, 2010 – Screen Image

  • image was not created correctly when the X/Y coordinates of the specified region where non zero.

February 7, 2010 – Menu Scroller

  • fixed a bug which could affect a menu with a scroll count of 1.
  • added a demo which can be run directly from the web page via JavaT Web Start.

February 4, 2010 – Visual Font Designer

  • can now be run directly from the web page via JavaT Web Start.

December 21, 2009 – Scrollable Panel

  • changed the class to use better variable names as suggested in the comments.
  • updated the code to make sure a revalidate() is done when the ScrollableSizeHint is changed.

November 1, 2009 – Screen Image

  • added better support for creating images on non displayed components
  • fixed the API by removing the writeImage() code from the createImage() methods.

October 20, 2009 – Moving Windows

  • fixed a flickering problem when used in Linux as described by Allen in the first comment

October 18 6, 2009 – Card Layout Actions

  • implemented the suggestion made by Andre in the first comment

September 13, 2009 – Moving Windows

  • has been update to support “snapping” to a location so that it will work more effectively with Resizing Components.

September 6, 2009 – Global Event Listeners

  • a KeyEventPostProcessor example was added.

August 25, 2009 – Menu Scroller

  • Redundant MouseListener removed and code shortened.

July 21, 2009 – Moving Windows

  • setDragInsets(…) method was added. This method allows you to specify an area where mouseDragged events are ignored for the purposes of dragging the component. This will allow the component to support both dragging and resizing.
  • changed constructors such that you now need to specify the parent Component to be moved. This provides more flexibility in choosing which components are movable.

July 7, 2009 – Text Component Line Number

  • added support for multiple fonts and font sizes. That is the line height of the line number will now vary to match the related text component.

June 28, 2009 – Compound Undo Manager

  • attribute changes are only compounded when the caret position hasn’t changed. This indicates a change in attribute as a result of syntax highlighting. Other attribute changes like “bolding” text will involve a caret change as the text is selected and will be considered a separate edit for undo purposes
  • also added a Webstart demo to show the above behaviour

June 10, 2009 – Text Component Line Number

  • fixed a minor bug. The FontMetrics of the text component should be used to determine the height of each line as it is painted.
  • added a PropertyChangeListener – using the setUpdateFont() method you can cause the Font to be updated when the Font of the related text component is changed.

June 10, 2009 – Relative Layout

  • Invisible components are handled properly. They are not included in the size calculation or in the layout process.

May 14, 2009 – Line Painter

  • Now supports highlighting of wrapped lines correctly.

April 27, 2009 – Rotated Icon

  • Functionality was added to support an Icon that will rotate “about its center“. All you need to do is specify the angle of rotation.

April 15, 2009 – UIManager Defaults

  • Improved support for displaying the Icons. More Icons are painted and they are painted at their full size.

April 15, 2009 – Wrap Layout

  • The layout was not wrapping when doing a frame Maximize followed by a Restore

April 6, 2009 – Menu Scroller

  • Added support for freezing items at the top and/or bottom of the menu.

April 2, 2009 – Menu Scroller

  • Addressed the issue of erratic behavior after clicking the up/down scroll items.
  • Added keyboard control for scrolling.
  • Added support for JPopupMenu.

March 19, 2009 – Tabbed Pane Focus

  • the Reset Focus policy was not working as documented.

March 1, 2009 – Relative Layout

  • added setBorderGap(…) and getBorderGap() methods
  • this will allow you to control the gap before the leading component and after the trailing component

February 28, 2009 – Bean Table Model and Row Table Model

  • method, formatMethodNamed() was moved from the BeanTableModel to the RowTableModel
  • at the same time the method was made static and renamed to formatColumnName() to better reflect its purpose.

This will allow all sub classes of the RowTableModel to use this method, if required

February 1, 2009 – Relative Layout

  • fixed a layout bug when using the setFill() method – see second comment in the posting for more details
  • also added a setFillGap() method as suggested in the comment

February 3, 2009 – Relative Layout

  • added getters/setters to follow Java Bean conventions as suggested in comment 5.
  • added getConstraints() method to be consistent with other Layout Managers

December 29, 2008 – Row Number Table

  • Make sure the provided RowNumberRenderer is always used by setting it as the cell renderer for the TableColumn.

December 9, 2008 – SwingUtils

  • getUIDefaultsOfClass methods revised to return UIDefaults instead of Hashtable. This is in view of side effects of methods overridden in UIDefaults that result in inconsistent return values from the methods it inherits from Hashtable.

November 20, 2008 – ComponentTreeModel

  • method getComponentTreeModel updated to add the component subordinate to, instead of at, the node passed in as root. This facilitates adding multiple component hierarchies to the same pre-existing node.

November 19, 2008 – ComponentTreeCellRenderer

  • code updated to add null checks and default values for background colors

November 18, 2008 – Table Column Adjuster

  • post updated to list restrictions when using the setAutoResizeMode() method
  • code updated to better handle the different auto resize modes

November 15, 2008 – SwingUtils

  • code updated to cater to boolean properties
  • Javadoc comments updated to clarify that searches are depth-first


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: