In 30-bit color mode on Linux, a fresh PyCharm 5.0.3 installation fails to start:
[06:33 PM][ehvatum@heavenly:~/pycharm-community-5.0.2/bin]> ./pycharm.sh
Java HotSpot(TM) 64-Bit Server VM warning: ignoring option MaxPermSize=350m; support was removed in 8.0
log4j:WARN No appenders could be found for logger (io.netty.util.internal.logging.InternalLoggerFactory).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.
[ 571] ERROR - llij.ide.plugins.PluginManager - Unsupported bit depth: 30
sun.java2d.InvalidPipeException: Unsupported bit depth: 30
at sun.java2d.x11.X11SurfaceData.getSurfaceType(X11SurfaceData.java:611)
at sun.java2d.x11.X11SurfaceData.getSurfaceType(X11SurfaceData.java:516)
at sun.awt.X11GraphicsConfig.getSurfaceType(X11GraphicsConfig.java:178)
at sun.java2d.xr.XRSurfaceData.createData(XRSurfaceData.java:235)
...
Workaround: add
-Dsun.java2d.opengl=true to PyCharm's java call. This can be done by editing pycharm.sh; relevant snippet:
# ---------------------------------------------------------------------
# Run the IDE.
# ---------------------------------------------------------------------
LD_LIBRARY_PATH="$IDE_BIN_HOME:$LD_LIBRARY_PATH" "$JAVA_BIN" \
$AGENT \
"-Xbootclasspath/a:$IDE_HOME/lib/boot.jar" \
-classpath "$CLASSPATH" \
$VM_OPTIONS "-Djb.vmOptionsFile=$vm_options_file" \
"-XX:ErrorFile=$HOME/java_error_in_PYCHARM_%p.log" \
-Djb.restart.code=88 -Didea.paths.selector=PyCharm50 \
-Dsun.java2d.opengl=true \
$IDE_PROPERTIES_PROPERTY \
$IDE_JVM_ARGS \
com.intellij.idea.Main \
"$@"
This trick also works for running CLion in 30-bit mode. It presumably works with the other JetBrains IDEs, though I have not verified this.
Update: this workaround allows JetBrains IDEs to start in 30-bit mode, but they soon crash due to absolutely idiotic bugs in sun.java2d.opengl. Oh well. I guess I'll just delete all JetBrains stuff, never buy any of their products, and spread the word far and wide that they're basically retarded. Until they fix this - which they never will, because the problem lies in the Oracle Java shit stack. Nonetheless, the fault remains with JetBrains for going with Java. Who could have possibly predicted that would be problematic? Yeah, pretty much anybody.
Post a Comment