Skip to content

Releases: weisJ/darklaf

v3.0.2

30 Sep 14:18
b072844
Compare
Choose a tag to compare

This release updates the svg renderer to be more forgiving with unimplemented features (e.g. filter primitives) or malformed svg.

Addressed issues

  • Stackoverflow when setting the border of a spinner editor to an UIResource border #327
  • Malformed svg files or usage of unsupported svg features may fail during painting

v3.0.1

01 Aug 18:07
69afe2f
Compare
Choose a tag to compare

Visual changes

  • Borderless variants of buttons now paint a focus border for better accessibility. c89d617
  • Some minor layout improvements to the theme settings dialog.

Behavioural changes

  • Borderless variants now implicitly set JComponent.isRequestFocusEnabled to false for less visual noise when clicking them.

API Changes

  • Custom SVG colours can now be declared using the <solidcolor/> tag element. 6484b96
  • Loading indicator icons are now exposed through AllIcons in darklaf-iconset. d6b946f

New components

Other changes

Addressed issues

  • Popupmenu doesn't correctly reports the focus owner resulting in incorrect focus highlights. b979a36
  • Several button types don't respect the JComponent.isRequestFocusEnabled property. 6c875ec
  • #322 Maximize and restore not working on Windows 10. 869b1d5
  • #321 Non relevant error message "Couldn't get HWND of window" on Windows may appear. 57411d7
  • Theme monitoring may not work depending on initialization method. ce4d8c0
  • Top level menu items may not be fully centered. cb93e43
  • #325 Native librarys don't get cleaned up porperly on Windows. ce97823
  • #320 SAXEception when loading icons from outside the ui thread. 664ac79

Support for Modules, Windows 11 and more

01 Aug 17:42
Compare
Choose a tag to compare

Version 3.0.0 enables proper module support by providing a module-info.java for each module.
Note that this release brings some breaking changes as packages have been moved to resolve issues with split packages:

  • In darklaf-property-loader the top level package is now com.github.weisj.darklaf.properties. In particular this affects PropertyLoader, IconLoader and the various (svg)icon classes.
  • com.github.weisj.darklaf.color.DarkColorModel* in darklaf-utils has been moved to com.github.weisj.darklaf.color in darklaf-property-loader
  • Most functions which return/receive an IconLoader now return IconResolver instead.
  • com.github.weisj.darklaf.color.ColorUtil in darklaf-utils has been moved to com.github.weisj.darklaf.util
  • com.github.weisj.darklaf.util in darklaf-core has been moved to com.github.weisj.darklaf.ui.util
  • com.github.weisj.darklaf.platform in darklaf-native-util has been renamed to com.github.weisj.darklaf.nativeutil
  • All icons have moved into the darklaf-iconset project. If you need to use them you can depend on darklaf-iconset and use the IconSet.ICON_LOADER to retrieve them.

New modules

darklaf-iconset

Provides a set of icons optimized for darklaf. They can also be used with other LaFs without any further setup. If you wish to customize the colors used for the icons you have to provide the colors defined in https://github.com/weisJ/darklaf/blob/master/theme/src/main/resources/com/github/weisj/darklaf/theme/icon_presets/light_icons.properties through the UIDefaults in UIManager.

Icons can be conveniently accessed through the AllIcons class.

darklaf-platform-preferences

A module which exposed the native theme detection mechanism as a standalone dependency. It can be used without having to use darklaf itself. Simply create a new SystemPreferencesManager and start listening for changes to the OS theme.

darklaf-platform-decorations

A module which exposed the native decorations feature of darklaf as a standalone dependency. It should be compatible with almost all other laf implementations (mileage may vary). The responsible class is ExternalLafDecorator. By default the implementation tries to derive sensible colors based on other LaF properties. If you want to customize the appearance of the titlebar you can do so by providing a DecorationsColorProvider.
See the discussion in #316 for more informations and use cases.

Contributions

Visual changes

  • An JInternalPane outside of a JDesktopPane no longer has a shadow. 4537a68
  • Improved rendering of JSpinner and JComboBox inside a popup menu. 84fceaf
  • The "smaller" and "larger" text in the ThemeSettings are now represented by apropriate icons. #269 c6a3637
  • On Windows 11 rounded scrollbars will be used by default. 4c28099
  • Updated window button icons on Windows 11 to match the native look. 7197d08
  • The border radius of tooltips has been increased on macOS and Windows 11. 212b006
  • #306 On macOS and Windows 11 root panes no longer have borders by default, because they look out of place. 3180dfb

Behavioural changes

  • A JPopupMenu which has no menu items will no longer be displayed. b72f069
  • Improved resizing behaviour on Windwos which custom decorations enabled. c190762 8539c5e
  • Support for snap layouts on Windows 11 (Still has some caveats #311).

API Changes

  • Colors now need to be declared using a # in a .properties file when loaded through PropertyLoader. (Not using # was deprecated before). 1f6eb6e
  • Fallback value declarations in svg icons nowuse a % prefix instead of #. c43cbbc
  • FileTree and corresponding classes have been removed (were deprecated before). 425289e
  • Boolean client properties defined by the theme can now be overwritten. 48b5630
  • The Animator class API has been overhauled to be friendlier to use. 56dcca7
  • Added PanelPopup#addButton to easily add a button the the title bar of a JTrabFrame tab.
  • Added ScrollBarConstants.KEY_BACKGROUND_PAINTER property to provide the means to paint behind a scrollbar e.g. for search highlighting. The value has to be of type SizedPainter<JScrollBar>. See https://github.com/weisJ/darklaf/blob/d7d08139ab6d56a11d0c9a3c61ed73e0d1564510/core/src/test/java/com/github/weisj/darklaf/ui/scrollPane/OverlayRSyntaxScrollPane.java for an example. e9a3502
  • Added FontPrototpye to Theme to specify a prototype font which all default fonts will be based off of. See #303 for more information. This can also be changed through the ThemeSettings class.

Other changes

  • Prevent recursive laf installation. 8f8194e
  • The IconLoader will now release resources if the loaded icon is no longer used anywhere. 126670c
  • The backing implementation for svg icons has been moved to JSVG. Previously svgSalamander has been used. This improves the performance for icons which frequently change color values during runtime.
  • Improved code-singing experience on macOS.
  • Improved compatibility on macOS arm.

Addressed issues

  • Possible ConcurrentModificationException while theme events are dispatched. a9ae43f 85e556f
  • Incorrect selection foreground color in OneDark theme. e3a855c
  • #259 Arrow of disabled menu doesn't look disabled. e68f78e
  • #260 Disabled menu doesn't get painted with disabled text. 45abd4a
  • Adding the menu bar to a different component when the unified menu bar is enabled (Windows only) it becomes invisible. 7369248
  • JInternalFrame outside of JDesktopPane always appears selected. e48f23d
  • #314 NPE when using ScrollPopupMenu. d99c8a2
  • Table may use incorrect cell editor. 42d9476
  • Tooltip shadow is sometimes painted more than once resulting in a darker shadow. 7d6a354
  • With custom decorations enabled popups can be resized on Windows when they shouldn't. 812bf63
  • #275 NPE when uninstalling and a tree is currently being collapsed/expanded. c7ddc1d
  • #274 Black tooltip shadow on Linux and Java 8. 4904d3c
  • #268 System settings are overwritten by settings of ThemeSettings dialog. 32158fe
  • #289 Missing translations when using Java >= 9. e9625ce
  • Window bounds might change when installing/uninstalling decorations on macOS. 378b6f1 af82ec0
  • #298 Tooltips may show an incorrect background color. ff44d37 2ef0cb7
  • The ThemeSettings dialog doesn't reliably respond to changes in locale. 34f3815
  • Custom title bar on Windows uses incorrect font. 3639369
  • Combo box uses incorrect background color in some focus/selection combinations. f9e35e6

A big thank you to everyone who contributed, reported bug or requested features!

v2.7.3

17 Sep 20:18
Compare
Choose a tag to compare

Addressed issues

  • Tooltips have no content on Linux running with Java 8 #274
  • NPE when a tree is collapsed/expanded during laf uninstallation #275

v2.7.2

01 Aug 12:42
Compare
Choose a tag to compare

This version is identical to v2.7.1 and only differs in the fact that it's dependency on com.github.weisj:swing-extensions-laf-support no longer is a SNAPSHOT version. #257

v2.7.1

01 Aug 10:02
Compare
Choose a tag to compare

Addressed issues

v2.7.0 M1 support and module compliance

31 Jul 18:42
Compare
Choose a tag to compare

This release adds support for M1 on macOS. It also makes darklaf compliant with the module system introduced in Java 9.
A future release will add full support for modules.

NOTE:
If you are using JTabFrame with Java 16 or newer you may need to adjust your startup parameters for the best results.
All necessary information can be found in the console log upon startup.

Visual changes

  • Tables in html no longer have a border by default. e55440f
  • The arrow icons now specify visual paddings. 7c0171d
  • Imporved baseline calculation when using DarkSliderUI.KEY_USE_TRACK_AS_BASELINE.
    7762fb1

API Changes

  • Icons based on svg files can now declare visual paddings in teh xml by setting
    the visualPadding="top left bottom right"
    property on the top level xml tag. fe19e2e
  • FileTree is now deprecated. It's implementation will be moved to the swing-dsl
    project. 9b14afb
  • Added DarkPopupMenuUI.KEY_MAX_POPUP_SIZE to specify the maximum size for a JPopupMenu. If the preferred size of
    the popup is larger than that it will be wrapped inside an OverlayScrollPane.
    9ef6d06
  • The macos.useoloredTitleBar property can now be changed per window using DarkRootPaneUI.KEY_COLORED_TITLE_BAR.
    afd246a
  • Add UIManager property ComboBox.maximumRowCount to set the maximum number of rows displayed in a combo-box popup
    per theme. c352040

Other changes

  • Implemented M1 support on macOS.
  • Removed dependencies on internal jdk classes making darklaf almost module compliant.
  • Updated german translation. b71e769 by Peter Lemke
  • Updated polish translation. c9593dc by Pabilo8

Addressed issues

  • JTextArea, JtextPane etc. prevent garbage collection of the component hierarchy.
    3457eeb
  • Usage of UIUpdater prevents garbage collection of the component hierarchy. 8725b20
  • Changing the value of a JSpinner with the mouse wheel doesn't check whether the attempted value is valid.
    afaa9fb
  • The target indicator of a DnD operation of a JTabFrame isn't removed when the operation us canceled.
    5e5bba8
  • Fallback opacity keys of a svg are lost when changing the Laf. 7124da0
  • Non JTrabFrame drop targets may qualify as a valid destination. #236 8bdfbe7
  • Cell hint popups at the top/bottom of cells incorrectly calculate their size to the full area of the cell. #238
    8e6573b
  • Loading a native library which isn't supported results in an incorrect provider being set.
    8215cd1
  • JList paints cells incorrectly after an empty cell is encountered. 40f6bac
  • Fonts may not be replaced during installation for newer jdk versions. 1b0752e

v2.6.1

27 May 14:12
Compare
Choose a tag to compare

Addressed issues

  • palette.* colors are missing in high contrast themes. b01ef6a
  • Possible NPE while painting svg icons if RenderingHints.KEY_TEXT_ANTIALIASING isn't specified in the desktop environment [Linux] b5da5cd

v2.6.0

27 May 12:11
Compare
Choose a tag to compare

Visual changes

  • Generate foreground colors for backgrounds which are derived from accent colors. a94087b de0e9a6
  • The slider variant of 'JToggleButton' will now show the state hints by default for all themes which
    declare Theme.highContrast as true. b152520
  • Windows now supports native selection colors by deriving them from the accent color. d398cb9
  • Changing the theme through the LafManager now supports a nice transition animation. This can be disabled using
    the darkalf.animatedLafChange system property. It's also disabled when disabling all animations through
    darklaf.animations. cd2e474
  • To ensure consistent colors when using custom renderers with JTree the color of the renderer is used for painting
    the row background. However, if selected the color specified in the current theme is used instead. 2a1983d
  • JSlider can now be aligned along the track as its baseline using the KEY_USE_TRACK_AS_BASELINE client-property. a8d9408

API Changes

  • PropertyLoader is now more robust and capable:
    • Other properties can now be referenced in compound statements (i.e. when defining insets).
    • Colors should now be declared using a # prefix to differentiate them from numbers. All uses of the old color
      declaration style will issue warnings.
    • Properties used in svg icons can now make use of literal expression '...', which aren't processed further.
      e.g. '%palette.teal' will be correctly resolved when patching the icons and not be overwritten by laf changes.
  • DarkSVGIcon is now capable if inferring its size based on its content allow. 2cf2cfa
    • This is done by passing a negative number to both the width and height of the icon.
    • By setting only one of width or height the other is calculated relatively to keep the original aspect ratio.
  • Only the Dialog font will now be replaced with the corresponding system font. d9b0de5
  • Added darklaf.macOsColorTitleBar system property to globally set whether colored title bars should be used on macOS.
  • LafManager#enableLogging is now deprecated due to it ignoring changes made to the log level. c757ee5
  • Added hyperlinkAccent property to themes. 8e7b573
  • Focus parents can now be specified solely by settings the focusParent client-property of the component. By default,
    it is assumed that the action upon focus change is repainting the component. 3ff5144
    7615b22

Other changes

  • Updated SVG-Salamander from 1.1.2.3 to version 1.1.2.4. a2456bf
  • SVG icons no longer create redundant copies when deriving with the same size. c050826
  • Added support for the swing-dsl library.
  • Started removal of jdk-internal-api usage. f60be2d a265ef9 75db998 1d7127a 88cbd8a 4b11cc8 e5a5bfd f8f12a0 23ea792 164a9f6 9ee79f4 db7d560
  • Improved error message if native library couldn't be loaded. 6abca5c
  • It's now easier to implement a custom UI for the ThemeSettings using the ThemeSettingsUI class. It provides the
    components used in the default implementation of ThemeSettingsPanel already setup using the appropriate gluing code. 36ecf9c

Addressed issues

  • ThemeSettings don't apply system colors. 6b43390 9e32dfc
  • Insets on JList aren't respected when painting empty rows. 1f9377a
  • Currently open settings dialog doesn't receive focus when requesting the dialog to be opened. 48aa90d
  • Border of JTextField doesn't update when changing the DarkTextUI.KEY_HAS_WARNING property. 59084d3
  • Line numbers in NumberedTextComponent aren't properly aligned. a52cb11 4e5e6de
  • The off-screen buffer of DarkSVGIcon isn't painted using proper antialiasing. #231 c2f9304
  • The off-screen buffer of DarkSVGIcon is created with the wrong size. #231 8fc941b
  • The shadow of balloon tooltips isn't properly aligned to the location of the pointer. 86d1c31
  • NPE while painting the cellhint popup. #232 fe4071d
  • The content of the cellhint popup reports an incorrect size resulting in an possibly unwanted popup. b077e3f
  • QuickColorChooser misses proper spacing between the check box and its label. 75dacb7
  • The text of JTextField shifts when navigating to either end of the content. 8b3c270
  • Navigating left/right in a JTree behaves differently than the default implementation. #228 6406f4a
  • NPE when rendering a null item in SimpleListCellRenderer. 3c9056f
  • NPE when trying to open the ThemeSettings dialog with no themes installed. 4ef86de
  • Insets of JTree are ignored while revealing expanded rows during navigation. 8c08640
  • JTree uses inconsistent meaning of focus during rendering. 8ad14cc

v2.5.5

26 Jan 21:00
Compare
Choose a tag to compare

Visual changes

  • Popup menus now use heavy weight popups by default on linux. 800a889

API Changes

  • Removed support for unused JList client-property JList.shrinkWrap.

Addressed issues

  • DerivableImageIcon might not paint the first time due to lazy and asynchronous loading. (See here) f46e601
  • Shadow on balloon tooltips is cut off at the top. 2b525dd
  • Tooltips are opaque on linux (Gnome) #229.
  • Boolean tree renderers don't display a hint popup when obscured. 5ac3291