Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions bin/jmeter.properties
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,14 @@
# See https://bz.apache.org/bugzilla/show_bug.cgi?id=52026 for details
# N.B. the LAF can be defined in user.properties.

# Enable custom window chrome for Darklaf Look and Feels.
# defaults to false
# darklaf.decorations=false

# Enables the unified menubar for Darklaf Look and Feels.
# defaults to true
# darklaf.unifiedMenuBar=true

# LoggerPanel display
# default to false
#jmeter.loggerpanel.display=false
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ commons-math3.version=3.6.1
commons-net.version=3.6
commons-pool2.version=2.8.0
commons-text.version=1.8
darklaf.version=2.4.4
darklaf.version=2.4.5
dec.version=0.1.2
dnsjava.version=2.1.9
equalsverifier.version=3.1.13
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -95,10 +95,16 @@ private static MenuItem ofDarklafTheme(Theme theme) {
static {
if (System.getProperty("darklaf.decorations") == null) {
System.setProperty("darklaf.decorations", "false");
} else if ("true".equals(System.getProperty("darklaf.allowNativeCode"))) {
Copy link
Contributor

@FSchumacher FSchumacher Aug 20, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Have you had a look at Boolean.getBoolean(name)? It should do the same as the "true".equals(System.getProperty(...).

// darklaf.allowNativeCode=true is required for darklaf.decorations=true to work.
System.setProperty("darklaf.decorations", "true");
}
if (System.getProperty("darklaf.allowNativeCode") == null) {
System.setProperty("darklaf.allowNativeCode", "false");
}
if (System.getProperty("darklaf.unifiedMenuBar") == null) {
System.setProperty("darklaf.unifiedMenuBar", "true");
}
UIManager.installLookAndFeel(JMeterMenuBar.DARCULA_LAF, JMeterMenuBar.DARCULA_LAF_CLASS);

List<MenuItem> items = new ArrayList<>();
Expand Down
11 changes: 11 additions & 0 deletions xdocs/usermanual/properties_reference.xml
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,17 @@ Defaults to: <code>true</code>
Defaults to: <code>500</code></property>
</properties>
</section>
<section name="&sect-num;.4.1 Darklaf configuration" anchor="darklaf_config">
<properties>
<property name="darklaf.decorations">
Enables custom window chrome when using a Darklaf Look And Feel.
Defaults to: <code>false</code></property>
<property name="darklaf.unifiedMenuBar">
Enables the unified menubar on Windows when using a Darklaf Look and Feel.<br/>
This property only has an effect if <code>darklaf.native</code> is <code>true</code>.
Defaults to: <code>true</code></property>
</properties>
</section>
<section name="&sect-num;.5 Toolbar display" anchor="toolbar_display">
<properties>
<property name="jmeter.toolbar.icons">
Expand Down