vscode-plantuml icon indicating copy to clipboard operation
vscode-plantuml copied to clipboard

Preview current diagram no longer working

Open ponaroth opened this issue 1 year ago • 5 comments

I see a blank when I used the preview current diagram feature. I need to hover over the error message to see the preview. Please check the screenshots attached. Screenshot 2024-04-08 at 9 48 08 AM Screenshot 2024-04-08 at 9 48 19 AM

ponaroth avatar Apr 08 '24 16:04 ponaroth

A downgrade to 2.17.6 made the extension work again for me.

j-lebek avatar Apr 12 '24 13:04 j-lebek

For me it's working fine with OpenJDK 21.0.2 2024-01-16.

mkfrey avatar Apr 19 '24 08:04 mkfrey

I encountered the same issue, but I managed to resolve it. It seems like that the new version of the extension now locates java in the $PATH and the incompatible one(such as Java 8 in my case) will cause this issue.

To fix this, ensure the latest OpenJDK is installed and prioritized in the $PATH. Add the following to your .bashrc or .zshrc:

export JAVA_HOME=$(/usr/libexec/java_home) # Returns, for example, /opt/homebrew/Cellar/openjdk/22.0.1/libexec/openjdk.jdk/Contents/Home
export PATH=$JAVA_HOME/bin:$PATH

FunJim avatar Jul 02 '24 10:07 FunJim

Al least you have a error-message. On my Win10 the Preview ist showing nothing. Just a black background. Can't mark anything to make it visible or something to hover for some information. Downgraded to 2.17.6 without any change. On top of that I can't export any diagram to pdf, svg or png. But that is a another topic. Didn't worked before and after I installed Java 8.

Using a PlantUML Previewer by Mebrahtom Guesh atm, but with bigger diagrams you will problems with font-Size and scolling horizontally.

mcstumpfi avatar Aug 12 '24 11:08 mcstumpfi

Al least you have a error-message. On my Win10 the Preview ist showing nothing. Just a black background. Can't mark anything to make it visible or something to hover for some information. Downgraded to 2.17.6 without any change. On top of that I can't export any diagram to pdf, svg or png. But that is a another topic. Didn't worked before and after I installed Java 8.

Using a PlantUML Previewer by Mebrahtom Guesh atm, but with bigger diagrams you will problems with font-Size and scolling horizontally.


Nevermind. installed the wrong java 8 packages. After installing openjdk8u422-b05 it is working :)

mcstumpfi avatar Aug 12 '24 11:08 mcstumpfi