java error no ComponentUI class for javax.swing.JScrollPane

8 visualizaciones (últimos 30 días)
Josette Fabre
Josette Fabre el 18 de Dic. de 2017
Respondida: Mash Knit el 29 de Dic. de 2017
I updated from Matlab 2016a to 2017b on my redhat scientific linux rel 6.6 box, when I run just about anything I get the following errors (and as indicated by the messages, no scroll bars) in my matlab window:
UIDefaults.getUI() failed: no ComponentUI class for: javax.swing.JScrollPane$ScrollBar[,0,0,0x0,invalid,alignmentX=0.0,alignmentY=0.0,border=,flags=4194304,maximumSize=,minimumSize=,preferredSize=,blockIncrement=10,orientation=VERTICAL,unitIncrement=1] java.lang.Error at javax.swing.UIDefaults.getUIError(UIDefaults.java:730) at javax.swing.MultiUIDefaults.getUIError(MultiUIDefaults.java:130) at javax.swing.UIDefaults.getUI(UIDefaults.java:760) at javax.swing.UIManager.getUI(UIManager.java:1016) at javax.swing.JScrollBar.updateUI(JScrollBar.java:227) at javax.swing.JScrollBar.<init>(JScrollBar.java:161) at javax.swing.JScrollBar.<init>(JScrollBar.java:176) at javax.swing.JScrollPane$ScrollBar.<init>(JScrollPane.java:718) at javax.swing.JScrollPane.createVerticalScrollBar(JScrollPane.java:873) at javax.swing.JScrollPane.<init>(JScrollPane.java:299) at javax.swing.plaf.basic.BasicComboPopup.createScroller(BasicComboPopup.java:571) at javax.swing.plaf.basic.BasicComboPopup.<init>(BasicComboPopup.java:335) at com.jgoodies.looks.plastic.PlasticComboBoxUI$PlasticComboPopup.<init>(PlasticComboBoxUI.java:425) at com.jgoodies.looks.plastic.PlasticComboBoxUI$PlasticComboPopup.<init>(PlasticComboBoxUI.java:422) at com.jgoodies.looks.plastic.PlasticComboBoxUI.createPopup(PlasticComboBoxUI.java:169) at javax.swing.plaf.basic.BasicComboBoxUI.installUI(BasicComboBoxUI.java:250) at com.jgoodies.looks.plastic.PlasticComboBoxUI.installUI(PlasticComboBoxUI.java:112) at javax.swing.JComponent.setUI(JComponent.java:666) at javax.swing.JComboBox.setUI(JComboBox.java:257) at javax.swing.JComboBox.updateUI(JComboBox.java:266) at javax.swing.JComboBox.init(JComboBox.java:231) at javax.swing.JComboBox.<init>(JComboBox.java:225) at com.mathworks.widgets.DropdownButton.setupButton(DropdownButton.java:185) at com.mathworks.widgets.DropdownButton.<init>(DropdownButton.java:92) at com.mathworks.widgets.PickerButton.<init>(PickerButton.java:77) at com.mathworks.hg.peer.AbstractSplitButtonPeer.createToolbutton(AbstractSplitButtonPeer.java:73) at com.mathworks.hg.peer.AbstractSplitButtonPeer.doInitializePeer(AbstractSplitButtonPeer.java:135) at com.mathworks.hg.peer.AbstractSplitButtonPeer.access$000(AbstractSplitButtonPeer.java:30) at com.mathworks.hg.peer.AbstractSplitButtonPeer$1.run(AbstractSplitButtonPeer.java:129) at com.mathworks.hg.util.HGPeerQueue$HGPeerRunnablesRunner.runit(HGPeerQueue.java:289) at com.mathworks.hg.util.HGPeerQueue$HGPeerRunnablesRunner.runThese(HGPeerQueue.java:317) at com.mathworks.hg.util.HGPeerQueue$HGPeerRunnablesRunner.run(HGPeerQueue.java:334) at com.mathworks.jmi.AWTUtilities$Invoker$5$1.run(AWTUtilities.java:591) at com.mathworks.mvm.context.ThreadContext$1.call(ThreadContext.java:76) at com.mathworks.mvm.context.ThreadContext.callWithContext(ThreadContext.java:105) at com.mathworks.mvm.context.ThreadContext.runWithContext(ThreadContext.java:73) at com.mathworks.mvm.context.MvmContext.runWithContext(MvmContext.java:107) at com.mathworks.jmi.AWTUtilities$Invoker$5.runWithOutput(AWTUtilities.java:588) at com.mathworks.jmi.AWTUtilities$Invoker$2.watchedRun(AWTUtilities.java:475) at com.mathworks.jmi.AWTUtilities$WatchedRunnable.run(AWTUtilities.java:436) at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:311) at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:756) at java.awt.EventQueue.access$500(EventQueue.java:97) at java.awt.EventQueue$3.run(EventQueue.java:709) at java.awt.EventQueue$3.run(EventQueue.java:703) at java.security.AccessController.doPrivileged(Native Method) at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:80) at java.awt.EventQueue.dispatchEvent(EventQueue.java:726) at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:201) at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116) at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93) at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)

Respuestas (1)

Mash Knit
Mash Knit el 29 de Dic. de 2017
I experienced the same problem, and the following command worked for me. I'm using ubuntu 16.04 LTS.
Open the terminal and type as follows, just before executing the command 'matlab'.
export MATLAB_JAVA=/usr/local/MATLAB/R2017b/sys/java/jre/glnxa64/jre
The problem seems to be occurred from JAVA run-time version mismatch. This site was very helpful. https://jp.mathworks.com/matlabcentral/answers/103089-matlab-java-virtual-machine-jvm

Categorías

Más información sobre Startup and Shutdown en Help Center y File Exchange.

Productos

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by