1
votes

The theme gives fatal error loading the resource file java.lang.numberFormatException Not a number: 0.0 error. I can not add/edit uiid, or images etc from the theme. I had zipped the project and used it in netbean (another computer). Then this problem came into existence. How can I fix it?

enter image description here

Update 1:

C:\Users\bijen.codenameone>java -jar designer_1.jar D:\cn1\herb\Neppha\src\them e.res

Feb 02, 2018 12:20:07 PM java.util.prefs.WindowsPreferences <init>
WARNING: Could not open/create prefs root node Software\JavaSoft\Prefs at root 0
x80000002. Windows RegCreateKeyEx(...) returned error code 5.
2018-02-02 12:20:09.685:INFO:oejs.Server:jetty-8.0.y.z-SNAPSHOT
2018-02-02 12:20:09.731:INFO:oejs.AbstractConnector:Started SelectChannelConnect
[email protected]:9000 STARTING
Feb 02, 2018 12:20:09 PM org.jdesktop.application.LocalStorage getId
WARNING: unspecified resource Application.id using ResourceEditorApp
Feb 02, 2018 12:20:09 PM org.jdesktop.application.LocalStorage getId
WARNING: unspecified resource Application.vendorId using UnknownApplicationVendo
r

As soon as Theme btn in gui builder is clicked, the following errors are seen

at java.awt.EventQueue$3.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
[AWT-EventQueue-0] 2:29:47,804 - Error creating style SideCommand. selected: false prefix:
[AWT-EventQueue-0] 2:29:47,806 - Exception: java.lang.NumberFormatException - For input string: "1.0"
java.lang.NumberFormatException: For input string: "1.0"
        at java.lang.NumberFormatException.forInputString(Unknown Source)
        at java.lang.Integer.parseInt(Unknown Source)
        at java.lang.Integer.parseInt(Unknown Source)
        at com.codename1.ui.plaf.UIManager.toIntArray(UIManager.java:1267)
        at com.codename1.ui.plaf.UIManager.createStyle(UIManager.java:1165)
        at com.codename1.ui.plaf.UIManager.getComponentStyleImpl(UIManager.java:274)
        at com.codename1.ui.plaf.UIManager.getComponentStyle(UIManager.java:222)
        at com.codename1.ui.Component.initStyle(Component.java:592)
        at com.codename1.ui.Component.getStyle(Component.java:3953)
        at com.codename1.ui.Component.paintInternalImpl(Component.java:1538)
        at com.codename1.ui.Component.paintInternal(Component.java:1520)
        at com.codename1.ui.Component.paintInternal(Component.java:1488)
        at com.codename1.ui.Component.paintComponent(Component.java:1773)
        at com.codename1.ui.Component.paintComponent(Component.java:1720)
        at com.codename1.designer.ThemeEditor.getUIIDPreviewImage(ThemeEditor.java:2006)
        at com.codename1.designer.ThemeEditor$ThemeRenderer.getTableCellRenderer
Component(ThemeEditor.java:2042)
        at javax.swing.JTable.prepareRenderer(Unknown Source)
        at org.jdesktop.swingx.JXTable.prepareRenderer(JXTable.java:3545)
        at javax.swing.plaf.basic.BasicTableUI.paintCell(Unknown Source)
        at javax.swing.plaf.basic.BasicTableUI.paintCells(Unknown Source)
        at javax.swing.plaf.basic.BasicTableUI.paint(Unknown Source)
        at javax.swing.plaf.ComponentUI.update(Unknown Source)
        at javax.swing.JComponent.paintComponent(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JViewport.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JSplitPane.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JSplitPane.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JLayeredPane.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paintToOffscreen(Unknown Source)
        at javax.swing.RepaintManager$PaintManager.paintDoubleBuffered(Unknown Source)
        at javax.swing.RepaintManager$PaintManager.paint(Unknown Source)
        at javax.swing.RepaintManager.paint(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at java.awt.GraphicsCallback$PaintCallback.run(Unknown Source)
        at sun.awt.SunGraphicsCallback.runOneComponent(Unknown Source)
        at sun.awt.SunGraphicsCallback.runComponents(Unknown Source)
        at java.awt.Container.paint(Unknown Source)
        at java.awt.Window.paint(Unknown Source)
        at javax.swing.RepaintManager$4.run(Unknown Source)
        at javax.swing.RepaintManager$4.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
        at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
        at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
        at javax.swing.RepaintManager.prePaintDirtyRegions(Unknown Source)
        at javax.swing.RepaintManager.access$1200(Unknown Source)
        at javax.swing.RepaintManager$ProcessingRunnable.run(Unknown Source)
        at java.awt.event.InvocationEvent.dispatch(Unknown Source)
        at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
        at java.awt.EventQueue.access$500(Unknown Source)
        at java.awt.EventQueue$3.run(Unknown Source)
        at java.awt.EventQueue$3.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
        at java.awt.EventQueue.dispatchEvent(Unknown Source)
        at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
        at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
        at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
        at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
        at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
        at java.awt.EventDispatchThread.run(Unknown Source)
[AWT-EventQueue-0] 2:29:47,818 - Error creating style SideNavigationPanel. selec
ted: false prefix:
[AWT-EventQueue-0] 2:29:47,818 - Exception: java.lang.NumberFormatException - Fo
r input string: "0.0"
java.lang.NumberFormatException: For input string: "0.0"
        at java.lang.NumberFormatException.forInputString(Unknown Source)
        at java.lang.Integer.parseInt(Unknown Source)
        at java.lang.Integer.parseInt(Unknown Source)
        at com.codename1.ui.plaf.UIManager.toIntArray(UIManager.java:1267)
        at com.codename1.ui.plaf.UIManager.createStyle(UIManager.java:1165)
        at com.codename1.ui.plaf.UIManager.getComponentStyleImpl(UIManager.java:274)
        at com.codename1.ui.plaf.UIManager.getComponentStyle(UIManager.java:222)

        at com.codename1.ui.Component.initStyle(Component.java:592)
        at com.codename1.ui.Component.getStyle(Component.java:3953)
        at com.codename1.ui.Component.paintInternalImpl(Component.java:1538)
        at com.codename1.ui.Component.paintInternal(Component.java:1520)
        at com.codename1.ui.Component.paintInternal(Component.java:1488)
        at com.codename1.ui.Component.paintComponent(Component.java:1773)
        at com.codename1.ui.Component.paintComponent(Component.java:1720)
        at com.codename1.designer.ThemeEditor.getUIIDPreviewImage(ThemeEditor.java:2006)
        at com.codename1.designer.ThemeEditor$ThemeRenderer.getTableCellRenderer
Component(ThemeEditor.java:2042)
        at javax.swing.JTable.prepareRenderer(Unknown Source)
        at org.jdesktop.swingx.JXTable.prepareRenderer(JXTable.java:3545)
        at javax.swing.plaf.basic.BasicTableUI.paintCell(Unknown Source)
        at javax.swing.plaf.basic.BasicTableUI.paintCells(Unknown Source)
        at javax.swing.plaf.basic.BasicTableUI.paint(Unknown Source)
        at javax.swing.plaf.ComponentUI.update(Unknown Source)
        at javax.swing.JComponent.paintComponent(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JViewport.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JSplitPane.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JSplitPane.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JLayeredPane.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paintToOffscreen(Unknown Source)
        at javax.swing.RepaintManager$PaintManager.paintDoubleBuffered(Unknown Source)
        at javax.swing.RepaintManager$PaintManager.paint(Unknown Source)
        at javax.swing.RepaintManager.paint(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at java.awt.GraphicsCallback$PaintCallback.run(Unknown Source)
        at sun.awt.SunGraphicsCallback.runOneComponent(Unknown Source)
        at sun.awt.SunGraphicsCallback.runComponents(Unknown Source)
        at java.awt.Container.paint(Unknown Source)
        at java.awt.Window.paint(Unknown Source)
        at javax.swing.RepaintManager$4.run(Unknown Source)
        at javax.swing.RepaintManager$4.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
        at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
        at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
        at javax.swing.RepaintManager.prePaintDirtyRegions(Unknown Source)
        at javax.swing.RepaintManager.access$1200(Unknown Source)
        at javax.swing.RepaintManager$ProcessingRunnable.run(Unknown Source)
        at java.awt.event.InvocationEvent.dispatch(Unknown Source)
        at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
        at java.awt.EventQueue.access$500(Unknown Source)
        at java.awt.EventQueue$3.run(Unknown Source)
        at java.awt.EventQueue$3.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionP
rivilege(Unknown Source)
        at java.awt.EventQueue.dispatchEvent(Unknown Source)
        at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
        at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
        at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
        at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
        at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
        at java.awt.EventDispatchThread.run(Unknown Source)
[AWT-EventQueue-0] 2:29:47,831 - Error creating style herbContainerBg. selected:false prefix:
[AWT-EventQueue-0] 2:29:47,831 - Exception: java.lang.NumberFormatException - For input string: "2.5"
java.lang.NumberFormatException: For input string: "2.5"
        at java.lang.NumberFormatException.forInputString(Unknown Source)
        at java.lang.Integer.parseInt(Unknown Source)
        at java.lang.Integer.parseInt(Unknown Source)
        at com.codename1.ui.plaf.UIManager.toIntArray(UIManager.java:1267)
        at com.codename1.ui.plaf.UIManager.createStyle(UIManager.java:1165)
        at com.codename1.ui.plaf.UIManager.getComponentStyleImpl(UIManager.java:274)
        at com.codename1.ui.plaf.UIManager.getComponentStyle(UIManager.java:222)

        at com.codename1.ui.Component.initStyle(Component.java:592)
        at com.codename1.ui.Component.getStyle(Component.java:3953)
        at com.codename1.ui.Component.paintInternalImpl(Component.java:1538)
        at com.codename1.ui.Component.paintInternal(Component.java:1520)
        at com.codename1.ui.Component.paintInternal(Component.java:1488)
        at com.codename1.ui.Component.paintComponent(Component.java:1773)
        at com.codename1.ui.Component.paintComponent(Component.java:1720)
        at com.codename1.designer.ThemeEditor.getUIIDPreviewImage(ThemeEditor.java:2006)
        at com.codename1.designer.ThemeEditor$ThemeRenderer.getTableCellRenderer
Component(ThemeEditor.java:2042)
        at javax.swing.JTable.prepareRenderer(Unknown Source)
        at org.jdesktop.swingx.JXTable.prepareRenderer(JXTable.java:3545)
        at javax.swing.plaf.basic.BasicTableUI.paintCell(Unknown Source)
        at javax.swing.plaf.basic.BasicTableUI.paintCells(Unknown Source)
        at javax.swing.plaf.basic.BasicTableUI.paint(Unknown Source)
        at javax.swing.plaf.ComponentUI.update(Unknown Source)
        at javax.swing.JComponent.paintComponent(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JViewport.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JSplitPane.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JSplitPane.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at javax.swing.JLayeredPane.paint(Unknown Source)
        at javax.swing.JComponent.paintChildren(Unknown Source)
        at javax.swing.JComponent.paintToOffscreen(Unknown Source)
        at javax.swing.RepaintManager$PaintManager.paintDoubleBuffered(Unknown Source)
        at javax.swing.RepaintManager$PaintManager.paint(Unknown Source)
        at javax.swing.RepaintManager.paint(Unknown Source)
        at javax.swing.JComponent.paint(Unknown Source)
        at java.awt.GraphicsCallback$PaintCallback.run(Unknown Source)
        at sun.awt.SunGraphicsCallback.runOneComponent(Unknown Source)
        at sun.awt.SunGraphicsCallback.runComponents(Unknown Source)
        at java.awt.Container.paint(Unknown Source)
        at java.awt.Window.paint(Unknown Source)
        at javax.swing.RepaintManager$4.run(Unknown Source)
        at javax.swing.RepaintManager$4.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
        at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
        at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
        at javax.swing.RepaintManager.prePaintDirtyRegions(Unknown Source)
        at javax.swing.RepaintManager.access$1200(Unknown Source)
        at javax.swing.RepaintManager$ProcessingRunnable.run(Unknown Source)
        at java.awt.event.InvocationEvent.dispatch(Unknown Source)
        at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
        at java.awt.EventQueue.access$500(Unknown Source)
        at java.awt.EventQueue$3.run(Unknown Source)
        at java.awt.EventQueue$3.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
        at java.awt.EventQueue.dispatchEvent(Unknown Source)
        at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
        at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
        at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
        at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
        at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
        at java.awt.EventDispatchThread.run(Unknown Source)
1
Is File -> XML Team Mode on? Is the res file 0 sized? Can you provide the output from codenameone.com/blog/tip-track-designer-guibuilder-issues.html - Shai Almog
yeahhh team mode is on and res file is not 0 (its 22kb) - beck
Can you provide printout from the link? - Shai Almog
I didn't find any .guibuilder folder in the home directory. Theres .cn1, .codenameone etc but not .guibuilder - beck
This is the old designer so you don't need the .guiBuilder directory only the .codenameone directory and the designer jar from within - Shai Almog

1 Answers

0
votes

It looks like you have two different versions of the plugins hence designers in the project.

The other computer saved the new format of the resource file which includes fractional padding/margin and the old machine is still using the old format that expects integer values.

Make sure you have the same IDE plugin version and that designer_1.jar is identical between both machines.