Bug 139298 [ErrorHandling] eclipse will silently fail to launch with invalid colorDefinition value
I had a color value of "30,14, 231", and the erroneous space after the comma caused Eclipse to silently fail to launch without any error messages other than the following from .metadata/.log. Seems that better error tolerance would be good. Note that the launch was a runtime workbench. !ENTRY org.eclipse.ui 4 0 2006-04-28 12:50:32.565 !MESSAGE For input string: " 231" !STACK 0 org.eclipse.jface.resource.DataFormatException: For input string: " 231" at org.eclipse.jface.resource.StringConverter.asRGB(StringConverter.java:560) at org.eclipse.ui.themes.ColorUtil.getColorValue(ColorUtil.java:122) at org.eclipse.ui.internal.themes.ColorDefinition.getValue(ColorDefinition.java:146) at org.eclipse.ui.internal.themes.ThemeElementHelper.installColor(ThemeElementHelper.java:261) at org.eclipse.ui.internal.themes.ThemeElementHelper.populateRegistry(ThemeElementHelper.java:156) at org.eclipse.ui.internal.Workbench.initializeApplicationColors(Workbench.java:1123) at org.eclipse.ui.internal.Workbench.init(Workbench.java:1065) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1847) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:419) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:143) at org.eclipse.ui.internal.ide.IDEApplication.run(IDEApplication.java:95) at org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:78) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:92) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:68) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:400) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:177) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.eclipse.core.launcher.Main.invokeFramework(Main.java:336) at org.eclipse.core.launcher.Main.basicRun(Main.java:280) at org.eclipse.core.launcher.Main.run(Main.java:977) at org.eclipse.core.launcher.Main.main(Main.java:952)
bundles/org.eclipse.jface/src/org/eclipse/jface/resource/StringConverter.java
/*******************************************************************************
 * Copyright (c) 2000, 2006 IBM Corporation and others.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *     IBM Corporation - initial API and implementation
 *******************************************************************************/
package org.eclipse.jface.resource;
import java.util.ArrayList;
import java.util.NoSuchElementException;
import java.util.StringTokenizer;
import org.eclipse.core.runtime.Assert;
import org.eclipse.swt.SWT;
import org.eclipse.swt.graphics.FontData;
import org.eclipse.swt.graphics.Point;
import org.eclipse.swt.graphics.RGB;
import org.eclipse.swt.graphics.Rectangle;
/**
 * Helper class for converting various data types to and from
 * strings. Supported types include: