@Override
	public void initialize() {
		// do not initialize if this is not the current look and feel
		//    This is only necessary for special Laf usage. E.g. in GUI builders,
		//    which may use multiple Lafs and may invoke this method directly.
		//    This avoids that listeners and factories are installed multiple times.
		//    In case of the NetBeans GUI builder, which does not invoke uninitialize(),
		//    this also avoids that listeners stay registered in the system.
		if( UIManager.getLookAndFeel() != this )
			return;

		if( SystemInfo.isMacOS )
			initializeAqua();

		super.initialize();

		// install popup factory
		oldPopupFactory = PopupFactory.getSharedInstance();
		PopupFactory.setSharedInstance( new FlatPopupFactory() );

		// install mnemonic handler
		mnemonicHandler = new MnemonicHandler();
		mnemonicHandler.install();

		// install submenu usability helper
		subMenuUsabilityHelperInstalled = SubMenuUsabilityHelper.install();

		// install Linux popup menu canceler
		if( SystemInfo.isLinux )
			linuxPopupMenuCanceler = new LinuxPopupMenuCanceler();

		// listen to desktop property changes to update UI if system font or scaling changes
		if( SystemInfo.isWindows ) {
			// Windows 10 allows increasing font size independent of scaling:
			//   Settings > Ease of Access > Display > Make text bigger (100% - 225%)
			desktopPropertyName = "win.messagebox.font";
		} else if( SystemInfo.isLinux ) {
			// Linux/Gnome allows changing font in "Tweaks" app
			desktopPropertyName = "gnome.Gtk/FontName";

			// Linux/Gnome allows extra scaling and larger text:
			//   Settings > Devices > Displays > Scale (100% or 200%)
			//   Settings > Universal access > Large Text (off or on, 125%)
			//   "Tweaks" app > Fonts > Scaling Factor (0,5 - 3)
			desktopPropertyName2 = "gnome.Xft/DPI";
		}
		if( desktopPropertyName != null ) {
			desktopPropertyListener = e -> {
				if( !FlatSystemProperties.getBoolean( FlatSystemProperties.UPDATE_UI_ON_SYSTEM_FONT_CHANGE, true ) )
					return;

				String propertyName = e.getPropertyName();
				if( desktopPropertyName.equals( propertyName ) || propertyName.equals( desktopPropertyName2 ) )
					reSetLookAndFeel();
				else if( DESKTOPFONTHINTS.equals( propertyName ) ) {
					if( UIManager.getLookAndFeel() instanceof FlatLaf ) {
						putAATextInfo( UIManager.getLookAndFeelDefaults() );
						updateUILater();
					}
				}
			};
			Toolkit toolkit = Toolkit.getDefaultToolkit();

			// make sure that AWT desktop properties are initialized (on Linux)
			// before invoking toolkit.addPropertyChangeListener()
			// https://github.com/JFormDesigner/FlatLaf/issues/405#issuecomment-960242342
			toolkit.getDesktopProperty( "dummy" );

			toolkit.addPropertyChangeListener( desktopPropertyName, desktopPropertyListener );
			if( desktopPropertyName2 != null )
				toolkit.addPropertyChangeListener( desktopPropertyName2, desktopPropertyListener );
			toolkit.addPropertyChangeListener( DESKTOPFONTHINTS, desktopPropertyListener );
		}

		// Following code should be ideally in initialize(), but needs color from UI defaults.
		// Do not move this code to getDefaults() to avoid side effects in the case that
		// getDefaults() is directly invoked from 3rd party code. E.g. `new FlatLightLaf().getDefaults()`.
		postInitialization = defaults -> {
			// update link color in HTML text
			Color linkColor = defaults.getColor( "Component.linkColor" );
			if( linkColor != null ) {
				new HTMLEditorKit().getStyleSheet().addRule(
					String.format( "a, address { color: #%06x; }", linkColor.getRGB() & 0xffffff ) );
			}
		};
	}
Returns whether FlatLaf supports custom window decorations.
This depends on the operating system and on the used Java runtime.
<p>
This method returns {@code true} on Windows 10/11 (see exception below)
and on Linux, otherwise returns {@code false}.
<p>
Returns also {@code false} on Windows 10/11 if
FlatLaf native window border support is available (requires Windows 10/11).
<p>
In these cases, custom decorations are enabled by the root pane.
Usage of {@link JFrame#setDefaultLookAndFeelDecorated(boolean)} or
{@link JDialog#setDefaultLookAndFeelDecorated(boolean)} is not necessary.
flatlaf-core/src/main/java/com/formdev/flatlaf/FlatLaf.java