Skip to content

Commit

Permalink
Set java.awt.headless to true due to Windows 11 issues (#312)
Browse files Browse the repository at this point in the history
* set java.awt.headless to true due to Windows 11 issues

* do not force headles mode but us it as default
  • Loading branch information
HeinrichAD authored Sep 6, 2023
1 parent 608b58b commit 46077bf
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,10 @@ public static void init() {
return;
}
initialized = true;
// set headless mode manually since otherwise Windows 11 seems to have some issues with it
// see Issue#311 :: https://github.com/plantuml/plantuml-server/issues/311
// NOTE: This can only be set before any awt/X11/... related stuff is loaded
System.setProperty("java.awt.headless", System.getProperty("java.awt.headless", "true"));
// set security profile to INTERNET by default
// NOTE: this property is cached inside PlantUML and cannot be changed after the first call of PlantUML
System.setProperty("PLANTUML_SECURITY_PROFILE", SecurityProfile.INTERNET.toString());
Expand Down

0 comments on commit 46077bf

Please sign in to comment.