xcfsdf / universal-pokemon-randomizer

Automatically exported from code.google.com/p/universal-pokemon-randomizer
0 stars 0 forks source link

Randomizer will not work with certain custom Windows skins. #2

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. "C:\Program Files\Java\jdk1.8.0\bin\java.exe" -jar randomizer.jar
2. or just java -jar randomizer.jar (JRE 7u10)
3.

What is the expected output? What do you see instead?

A window.

C:\Users\NivthK\PKMNRNDM>"C:\Program Files\Java\jdk1.8.0\bin\java.exe" -jar 
randomizer.jar
Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
        at com.sun.java.swing.plaf.windows.XPStyle.getTypeEnumName(XPStyle.java:155)
        at com.sun.java.swing.plaf.windows.XPStyle.getBorder(XPStyle.java:277)
        at com.sun.java.swing.plaf.windows.WindowsLookAndFeel$XPBorderValue.getXPValue(WindowsLookAndFeel.java:2402)
        at com.sun.java.swing.plaf.windows.WindowsLookAndFeel$XPValue.createValue(WindowsLookAndFeel.java:2357)
        at javax.swing.UIDefaults.getFromHashtable(UIDefaults.java:232)
        at javax.swing.UIDefaults.get(UIDefaults.java:162)
        at javax.swing.MultiUIDefaults.get(MultiUIDefaults.java:64)
        at javax.swing.UIDefaults.getBorder(UIDefaults.java:480)
        at javax.swing.UIManager.getBorder(UIManager.java:756)
        at javax.swing.border.TitledBorder.getBorder(TitledBorder.java:416)
        at javax.swing.border.TitledBorder.getBorderInsets(TitledBorder.java:349)
        at javax.swing.border.AbstractBorder.getBorderInsets(AbstractBorder.java:75)
        at javax.swing.JComponent.getInsets(JComponent.java:1824)
        at javax.swing.GroupLayout.adjustSize(GroupLayout.java:1109)
        at javax.swing.GroupLayout.preferredLayoutSize(GroupLayout.java:879)
        at java.awt.Container.preferredSize(Container.java:1789)
        at java.awt.Container.getPreferredSize(Container.java:1773)
        at javax.swing.JComponent.getPreferredSize(JComponent.java:1662)
        at javax.swing.GroupLayout$ComponentSpring.calculateNonlinkedPreferredSize(GroupLayout.java:3019)
        at javax.swing.GroupLayout$ComponentSpring.calculateNonlinkedMinimumSize(GroupLayout.java:3005)
        at javax.swing.GroupLayout$ComponentSpring.calculateMinimumSize(GroupLayout.java:2972)
        at javax.swing.GroupLayout$Spring.getMinimumSize(GroupLayout.java:1336)
        at javax.swing.GroupLayout$ComponentSpring.calculatePreferredSize(GroupLayout.java:2979)
        at javax.swing.GroupLayout$Spring.getPreferredSize(GroupLayout.java:1346)
        at javax.swing.GroupLayout$Group.getSpringSize(GroupLayout.java:1638)
        at javax.swing.GroupLayout$Group.calculateSize(GroupLayout.java:1624)
        at javax.swing.GroupLayout$Group.calculatePreferredSize(GroupLayout.java:1602)
        at javax.swing.GroupLayout$Spring.getPreferredSize(GroupLayout.java:1346)
        at javax.swing.GroupLayout$Group.getSpringSize(GroupLayout.java:1638)
        at javax.swing.GroupLayout$Group.calculateSize(GroupLayout.java:1625)
        at javax.swing.GroupLayout$Group.calculatePreferredSize(GroupLayout.java:1602)
        at javax.swing.GroupLayout$Spring.getPreferredSize(GroupLayout.java:1346)
        at javax.swing.GroupLayout$Group.getSpringSize(GroupLayout.java:1638)
        at javax.swing.GroupLayout$Group.calculateSize(GroupLayout.java:1625)
        at javax.swing.GroupLayout$Group.calculatePreferredSize(GroupLayout.java:1602)
        at javax.swing.GroupLayout$Spring.getPreferredSize(GroupLayout.java:1346)
        at javax.swing.GroupLayout$Group.getSpringSize(GroupLayout.java:1638)
        at javax.swing.GroupLayout$Group.calculateSize(GroupLayout.java:1622)
        at javax.swing.GroupLayout$Group.calculatePreferredSize(GroupLayout.java:1602)
        at javax.swing.GroupLayout$Spring.getPreferredSize(GroupLayout.java:1346)
        at javax.swing.GroupLayout$Group.getSpringSize(GroupLayout.java:1638)
        at javax.swing.GroupLayout$Group.calculateSize(GroupLayout.java:1622)
        at javax.swing.GroupLayout$Group.calculatePreferredSize(GroupLayout.java:1602)
        at javax.swing.GroupLayout$Spring.getPreferredSize(GroupLayout.java:1346)
        at javax.swing.GroupLayout.calculateAutopadding(GroupLayout.java:1071)
        at javax.swing.GroupLayout.prepare(GroupLayout.java:1058)
        at javax.swing.GroupLayout.preferredLayoutSize(GroupLayout.java:878)
        at java.awt.Container.preferredSize(Container.java:1789)
        at java.awt.Container.getPreferredSize(Container.java:1773)
        at javax.swing.JComponent.getPreferredSize(JComponent.java:1662)
        at javax.swing.JRootPane$RootLayout.preferredLayoutSize(JRootPane.java:920)
        at java.awt.Container.preferredSize(Container.java:1789)
        at java.awt.Container.getPreferredSize(Container.java:1773)
        at javax.swing.JComponent.getPreferredSize(JComponent.java:1662)
        at java.awt.BorderLayout.preferredLayoutSize(BorderLayout.java:719)
        at java.awt.Container.preferredSize(Container.java:1789)
        at java.awt.Container.getPreferredSize(Container.java:1773)
        at java.awt.Window.pack(Window.java:809)
        at com.dabomstew.pkrandom.gui.RandomizerGUI.initComponents(RandomizerGUI.java:2048)
        at com.dabomstew.pkrandom.gui.RandomizerGUI.<init>(RandomizerGUI.java:94)
        at com.dabomstew.pkrandom.gui.RandomizerGUI$18.run(RandomizerGUI.java:3364)
        at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:251)
        at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:720)
        at java.awt.EventQueue.access$200(EventQueue.java:103)
        at java.awt.EventQueue$3.run(EventQueue.java:681)
        at java.awt.EventQueue$3.run(EventQueue.java:679)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:75)
        at java.awt.EventQueue.dispatchEvent(EventQueue.java:690)
        at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:244)
        at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:163)
        at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:151)
        at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:147)
        at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:139)
        at java.awt.EventDispatchThread.run(EventDispatchThread.java:97)

What version of the product are you using? On what operating system?

1.1.0, Windows 7

Please provide any additional information below.

This is making me sad. :(

Original issue reported on code.google.com by Niv...@gmail.com on 15 Jan 2013 at 8:43

GoogleCodeExporter commented 8 years ago
OK, looking at both the trace and the code, I can only think it must be the 
autogenerated code by whatever GUI designer that is (I like Eclipse, and I bet 
thats part of NetBeans. Otherwise, I have no idea.

Original comment by Niv...@gmail.com on 15 Jan 2013 at 9:01

GoogleCodeExporter commented 8 years ago
Also apparently Google code doesn't let you edit issued OR comments, even if 
you made em.

Original comment by Niv...@gmail.com on 15 Jan 2013 at 9:02

GoogleCodeExporter commented 8 years ago
This is indeed part of the autogenerated NetBeans code. I'll try to update 
NetBeans and do other stuff like that and see if a fix can be reached...

Original comment by dabomstew on 16 Jan 2013 at 12:38

GoogleCodeExporter commented 8 years ago
A google search says this exception isn't related to what JRE you're using, but 
is rather an obscure Java bug to do with certain custom Windows themes. Are you 
using one?

Original comment by dabomstew on 16 Jan 2013 at 1:06

GoogleCodeExporter commented 8 years ago
... Yes, I am. imma google it here too snd look for workarounds.

Original comment by Niv...@gmail.com on 16 Jan 2013 at 8:13

GoogleCodeExporter commented 8 years ago
Ok, I think I see where the problem is in the code. D/L ing Netbeans again here.

Original comment by Niv...@gmail.com on 16 Jan 2013 at 8:23

GoogleCodeExporter commented 8 years ago
Yeah, it'll probably work if you remove the code that sets the look and feel to 
system look and feel.

Original comment by dabomstew on 17 Jan 2013 at 10:20

GoogleCodeExporter commented 8 years ago
Yeah, I'm trying to figure out where/how its generated though so if you changed 
the GUI again, it wouldn't be a problem. Semiforgot actually, but I have 
everything now.

Original comment by Niv...@gmail.com on 18 Jan 2013 at 12:08

GoogleCodeExporter commented 8 years ago
Argh, I can't figure out how to add this project to NetBeans.

Original comment by Niv...@gmail.com on 18 Jan 2013 at 1:10

GoogleCodeExporter commented 8 years ago
This is still happening even if I change the look and feel... I'm just changing 
my theme back to default temporarily here. For reference, my theme is Blade 2, 
available here ( 
http://www.downeu.net/software/340524-windows-7-theme-blade.html ), I got it 
from someone else and I can't find who it was again to ask, but it uses a 
program called Theme Resource changer to allow themes to easily automatically 
patch the bitmaps in explorer.exe and other important windows files. I guess 
something with that messes it up.

Original comment by Niv...@gmail.com on 18 Jan 2013 at 2:10

GoogleCodeExporter commented 8 years ago
It's an Eclipse project, I just made the GUI in NetBeans. The set look and feel 
part in main() isn't autogenerated except when the form is first made, so you 
can just remove those lines from each new version and it should be OK.

Original comment by dbs.stew on 19 Jan 2013 at 1:46

GoogleCodeExporter commented 8 years ago

Original comment by dabomstew on 27 Jan 2013 at 12:57