chikoski / sqs

The repository of SQS project
http://smp.sfc.keio.ac.jp/
1 stars 1 forks source link

簡単リーダー:しきい値の設定ができない #3

Closed chikoski closed 12 years ago

chikoski commented 12 years ago

GUIの「設定」ボタンを押すと次のExceptionが発生する。

Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException at javax.swing.plaf.metal.MetalSliderUI.installUI(MetalSliderUI.java:92) at javax.swing.JComponent.setUI(JComponent.java:662) at javax.swing.JSlider.setUI(JSlider.java:300) at net.sqs2.omr.swing.RangeConfigurationPanel.createSlider(RangeConfigurationPanel.java:274) at net.sqs2.omr.swing.RangeConfigurationPanel.(RangeConfigurationPanel.java:240) at net.sqs2.omr.swing.MarkRecognitionConfigurationInnerPanel.(RangeConfigurationPanel.java:168) at net.sqs2.omr.swing.MarkRecognitionConfigurationDialog.(RangeConfigurationPanel.java:78) at net.sqs2.omr.swing.MarkRecognitionConfigurationDialog.(RangeConfigurationPanel.java:55) at net.sqs2.omr.swing.MarkReaderPanelController.showDensityConfigurationDialog(MarkReaderPanelController.java:82) at net.sqs2.omr.swing.MarkReaderSessionPanelController$2.actionPerformed(MarkReaderSessionPanelController.java:217) at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2028) at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2351) at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:387) at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:242) at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:236) at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:272) at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:272) at java.awt.Component.processMouseEvent(Component.java:6375) at javax.swing.JComponent.processMouseEvent(JComponent.java:3267) at java.awt.Component.processEvent(Component.java:6140) at java.awt.Container.processEvent(Container.java:2083) at java.awt.Component.dispatchEventImpl(Component.java:4737) at java.awt.Container.dispatchEventImpl(Container.java:2141) at java.awt.Component.dispatchEvent(Component.java:4565) at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4619) at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4280) at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4210) at java.awt.Container.dispatchEventImpl(Container.java:2127) at java.awt.Window.dispatchEventImpl(Window.java:2482) at java.awt.Component.dispatchEvent(Component.java:4565) at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:684) at java.awt.EventQueue.access$000(EventQueue.java:85) at java.awt.EventQueue$1.run(EventQueue.java:643) at java.awt.EventQueue$1.run(EventQueue.java:641) at java.security.AccessController.doPrivileged(Native Method) at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87) at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:98) at java.awt.EventQueue$2.run(EventQueue.java:657) at java.awt.EventQueue$2.run(EventQueue.java:655) at java.security.AccessController.doPrivileged(Native Method) at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87) at java.awt.EventQueue.dispatchEvent(EventQueue.java:654) at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296) at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211) at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188) at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

chikoski commented 12 years ago

http://stackoverflow.com/questions/6236998/jslider-go-to-clicked-position-problem-only-on-macintosh の質問と同様のエラー。

chikoski commented 12 years ago

http://www.tohoho-web.com/java/swing.htm SwingではLook & Feelを選択できて、その中にMetalがある模様。 直接Metalのクラスを読んでいるから?

chikoski commented 12 years ago

http://www.leepoint.net/JavaBasics/gui/gui-commentary/guicom-main-thread.html http://docs.oracle.com/javase/tutorial/uiswing/concurrency/

ここら辺をよめとのこと。

chikoski commented 12 years ago

とりあえずsetUIしているのをやめたら動いた。

chikoski commented 12 years ago

修正済ということとなった。 見た目の修正に関しては、必要あれば再度issueとする。