ctakes-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "melvin ma (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CTAKES-442) npe in simple piper fabricator gui
Date Wed, 11 Oct 2017 17:28:00 GMT

    [ https://issues.apache.org/jira/browse/CTAKES-442?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16200630#comment-16200630
] 

melvin ma commented on CTAKES-442:
----------------------------------

It appears that the fix is really simple, when calling "getTableCellRendererComponent", we
should pass in "fakeTable" as the first variable insteasd of null. Thanks! 

--------------------- Source from ctakes code 
final Component header = fakeHeader.getDefaultRenderer().getTableCellRendererComponent( null,
            "Available Pipe Bits", false, false, -1, -1 );
---------------------- source code from [here](http://grepcode.com/file/repository.grepcode.com/java/root/jdk/openjdk/8u40-b25/javax/swing/plaf/synth/SynthTableHeaderUI.java#SynthTableHeaderUI)
            public Component More ...getTableCellRendererComponent(JTable table, Object value,
226                                                       boolean isSelected,
227                                                       boolean hasFocus,
228                                                       int row, int column) {
229
230            boolean hasRollover = (column == getRolloverColumn());
231            if (isSelected || hasRollover || hasFocus) {
232                SynthLookAndFeel.setSelectedUI((SynthLabelUI)SynthLookAndFeel.
233                             getUIOfType(getUI(), SynthLabelUI.class),
234                             isSelected, hasFocus, {color:#d04437}table.isEnabled(),{color}
235                             hasRollover);
236            } else {
237                SynthLookAndFeel.resetSelectedUI();
238            }
----------------------
ERROR:

Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
	at javax.swing.plaf.synth.SynthTableHeaderUI$HeaderRenderer.getTableCellRendererComponent(SynthTableHeaderUI.java:234)
	at org.apache.ctakes.gui.pipeline.MainPanel2.createWestPanel(MainPanel2.java:94)
	at org.apache.ctakes.gui.pipeline.MainPanel2.createMainPanel(MainPanel2.java:139)
	at org.apache.ctakes.gui.pipeline.MainPanel2.<init>(MainPanel2.java:76)
	at org.apache.ctakes.gui.pipeline.PiperCreator.createMainPanel(PiperCreator.java:40)
	at org.apache.ctakes.gui.pipeline.PiperCreator.lambda$main$0(PiperCreator.java:53)
	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)



> npe in simple piper fabricator gui
> ----------------------------------
>
>                 Key: CTAKES-442
>                 URL: https://issues.apache.org/jira/browse/CTAKES-442
>             Project: cTAKES
>          Issue Type: Bug
>          Components: ctakes-gui
>    Affects Versions: 4.0.0
>            Reporter: Sean Finan
>            Assignee: Sean Finan
>             Fix For: 4.0.1
>
>
> From David Kincaid:
> I'm getting a NullPointerException while trying to launch the Piper Creator GUI from
a Linux command line. I have Ubuntu Linux 16.10 and using Oracle JVM 1.8.0_131. Here is the
stacktrace I get when I run bin/runPiperCreator.sh from the cTAKES 4.0 root:
> Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException at
> javax.swing.plaf.synth.SynthTableHeaderUI$HeaderRenderer.getTableCellRendererComponent(SynthTableHeaderUI.java:234)
> at
> org.apache.ctakes.gui.pipeline.MainPanel2.createWestPanel(MainPanel2.java:94)



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Mime
View raw message