Bug 39003 [JFace] Window exception handler
Hi all, The org.eclipse.jface.window.Window class contains the following sequence of code: public static void setExceptionHandler(IExceptionHandler handler) { if(exceptionHandler instanceof DefaultExceptionHandler) exceptionHandler = handler; } The instanceof check actually prevents setting a custom exception handler. The DefaultExceptionHandler class is made private and cannot be extended to hack around of this code. The DefaultExceptionHandler handles exceptions by printing stacktrace to the standard output. This problem effectively prevents the use of jface Window and it's subclass ApplicationWindow classes in any non trivial application. Regards, Peter.
bundles/org.eclipse.jface/src/org/eclipse/jface/window/Window.java
* This framework method is called by the <code>create</code> framework
	 * method. The default implementation calls <code>getInitialSize</code>
	 * and <code>getInitialLocation</code> and passes the results to
	 * <code>Shell.setBounds</code>. This is only done if the bounds of the
	 * shell have not already been modified. Subclasses may extend or
	 * reimplement.
	 * </p>
	 */
	protected void initializeBounds() {
		if (resizeListener != null) {
			shell.removeListener(SWT.Resize, resizeListener);
		}
		if (resizeHasOccurred) { 
			return;
		}
		Point size = getInitialSize();
		Point location = getInitialLocation(size);
		shell.setBounds(getConstrainedShellBounds(new Rectangle(location.x,
				location.y, size.x, size.y)));
	}
	/**
	 * Opens this window, creating it first if it has not yet been created.
	 * <p>
	 * If this window has been configured to block on open (
	 * <code>setBlockOnOpen</code>), this method waits until the window is
	 * closed by the end user, and then it returns the window's return code;
	 * otherwise, this method returns immediately. A window's return codes are
	 * window-specific, although two standard return codes are predefined:
	 * <code>OK</code> and <code>CANCEL</code>.
	 * </p>