mbien opened a new pull request, #9004:
URL: https://github.com/apache/netbeans/pull/9004

   first commit is the fix, second is just cleanup
   
    - only run x11 workarounds when x11 toolkit is active
    - wakefield may use WLToolkit on wayland (`-Dawt.toolkit.name=WLToolkit`)
   
   The `#183739` might be still useful, unfortunately I don't know what 
`#198639` does since bugzilla isn't loading the issue for me.
   
   symptom: startup failure
   
   <details>
   
   ```
   java.lang.ExceptionInInitializerError
        at java.desktop/sun.awt.X11.XAtom.<init>(XAtom.java:244)
        at java.desktop/sun.awt.X11.XWM.<clinit>(XWM.java:340)
        at java.base/java.lang.Class.forName0(Native Method)
        at java.base/java.lang.Class.forName(Class.java:467)
        at java.base/java.lang.Class.forName(Class.java:458)
        at 
org.netbeans.core.windows.view.ui.MainWindow.init(MainWindow.java:136)
        at 
org.netbeans.core.windows.WindowSystemImpl.init(WindowSystemImpl.java:46)
        at 
org.netbeans.core.GuiRunLevel.initializeMainWindow(GuiRunLevel.java:127)
        at org.netbeans.core.GuiRunLevel.run(GuiRunLevel.java:72)
        at org.netbeans.core.startup.Main.start(Main.java:316)
        at org.netbeans.core.startup.TopThreadGroup.run(TopThreadGroup.java:97)
        at java.base/java.lang.Thread.run(Thread.java:1474)
   Caused by: java.lang.ClassCastException: class 
sun.awt.wl.WLGraphicsEnvironment cannot be cast to class 
sun.awt.X11GraphicsEnvironment (sun.awt.wl.WLGraphicsEnvironment and 
sun.awt.X11GraphicsEnvironment are in module java.desktop of loader 'bootstrap')
        at java.desktop/sun.awt.X11.XToolkit.<clinit>(XToolkit.java:508)
        ... 12 more
   ```
   </details>
   
   I don't think project wakefield has made builds available yet, so to test 
this (linux+wayland) it would require the following:
   
   ```
   git clone -b jdk25-wayland --single-branch --depth 5 
https://github.com/openjdk/wakefield.git
   cd wakefield
   bash configure --with-vulkan
   make images
   ```
   start nb using the wakefield JDK with the following flags:
   ```
   -J-Dawt.toolkit.name=WLToolkit -J-Dsun.java2d.vulkan=True
   ```
   you should see something like this in the log instead of the exception:
   ```
   Vulkan rendering enabled: YES
     Presentation enabled: YES
     Accelerated surface data enabled: YES
     Devices:
       *0: NVIDIA GeForce GTX 1080
   ```
   
   Doesn't look great on my system though. Something is wrong with the font AA, 
popups are all over the place and some overlays (e.g editor highlighting layer) 
doesn't work. It runs at least.
   
   
   thanks to @cstamas for noticing this.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists

Reply via email to