| Modifier and Type | Class and Description |
|---|---|
| public static enum | |
| public static enum |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| private int | |
| public void | setDarkModeForWindowFrame(Window window, boolean darkMode)
Implements com.
|
| public void | |
| public void | setWindowBorderColor(Window window, Color color)
BELOW STILL NOT WORKING public void setWindowIconVisible(Stage window, boolean isVisible) { NativeLong windowStyle = new NativeLong(0x00000001L); // User32Support.INSTANCE.SetWindowLongPtrA( // WindowUtils.getNativeHandleOfStage(window), // GWL_EXSTYLE, // windowStyle // ); BaseTSD.LONG_PTR style = User32.INSTANCE.GetWindowLongPtr(WindowUtils.getNativeHandleOfStage(window), GWL_EXSTYLE); Pointer pointer = new WinDef.LONGByReference(new WinDef.LONG(0x00000001L)).getPointer(); User32.INSTANCE.SetWindowLongPtr( WindowUtils.getNativeHandleOfStage(window), GWL_EXSTYLE, pointer); User32.INSTANCE.SetWindowPos(WindowUtils.getNativeHandleOfStage(window), null, 0, 0, 0, 0, SWP_FRAMECHANGED | SWP_NOMOVE | SWP_NOSIZE | SWP_NOZORDER); window.setResizable(true); } |
| public void | setWindowCornerPreference(Window
the window which you want to change window, Win11ThemeWindowManager.the corner preference of the window cornerPreferenceSets the "roundness" of the corners of the window according to the passed in CornerPreference. |
| public void | |
| public void | |
| private int | toRGBInt(final Color color)
BELOW STILL NOT WORKING public void setWindowBackdrop(Dialog dialog, Backdrop backdrop) { Stage dialogStage = (Stage) dialog.getDialogPane().getScene().getWindow(); String tempTitle = "XYUZADCSD"; String dialogTitle = dialogStage.getTitle(); dialogStage.setTitle(tempTitle); WinDef.HWND hWnd = User32.INSTANCE.FindWindow(null, tempTitle); dialogStage.setTitle(dialogTitle); switch (backdrop) { case NONE -> DwmSupport.INSTANCE.DwmSetWindowAttribute( hWnd, DWMA_WINDOW_ATTRIBUTE.DWMWA_SYSTEMBACKDROP_TYPE.getValue(), new WinDef.DWORDByReference(new WinDef.DWORD(DWM_SYSTEMBACKDROP_TYPE.NONE.getValue())), WinDef.DWORD.SIZE ); case MICA -> DwmSupport.INSTANCE.DwmSetWindowAttribute( hWnd, DWMA_WINDOW_ATTRIBUTE.DWMWA_SYSTEMBACKDROP_TYPE.getValue(), new WinDef.DWORDByReference(new WinDef.DWORD(DWM_SYSTEMBACKDROP_TYPE.MICA.getValue())), WinDef.DWORD.SIZE ); case MICA_ALT -> DwmSupport.INSTANCE.DwmSetWindowAttribute( hWnd, DWMA_WINDOW_ATTRIBUTE.DWMWA_SYSTEMBACKDROP_TYPE.getValue(), new WinDef.DWORDByReference(new WinDef.DWORD(DWM_SYSTEMBACKDROP_TYPE.MICA_ALT.getValue())), WinDef.DWORD.SIZE ); case ACRYLIC -> DwmSupport.INSTANCE.DwmSetWindowAttribute( hWnd, DWMA_WINDOW_ATTRIBUTE.DWMWA_SYSTEMBACKDROP_TYPE.getValue(), new WinDef.DWORDByReference(new WinDef.DWORD(DWM_SYSTEMBACKDROP_TYPE.ACRYLIC.getValue())), WinDef.DWORD.SIZE ); } DWM.setWindowAttribute( hWnd, DWMA_WINDOW_ATTRIBUTE.DWMWA_USE_IMMERSIVE_DARK_MODE.getValue(), true ); } |
| Win11ThemeWindowManager | back to summary |
|---|---|
| public Win11ThemeWindowManager() | |
| doubleTo8Bit | back to summary |
|---|---|
| private int doubleTo8Bit(final double number) | |
| setDarkModeForWindowFrame | back to summary |
|---|---|
| public void setDarkModeForWindowFrame(Window window, boolean darkMode) Implements com. | |
| setWindowBackdrop | back to summary |
|---|---|
| public void setWindowBackdrop(Window window, Win11ThemeWindowManager. | |
| setWindowBorderColor | back to summary |
|---|---|
| public void setWindowBorderColor(Window window, Color color) BELOW STILL NOT WORKING public void setWindowIconVisible(Stage window, boolean isVisible) { NativeLong windowStyle = new NativeLong(0x00000001L); // User32Support.INSTANCE.SetWindowLongPtrA( // WindowUtils.getNativeHandleOfStage(window), // GWL_EXSTYLE, // windowStyle // ); BaseTSD.LONG_PTR style = User32.INSTANCE.GetWindowLongPtr(WindowUtils.getNativeHandleOfStage(window), GWL_EXSTYLE); Pointer pointer = new WinDef.LONGByReference(new WinDef.LONG(0x00000001L)).getPointer(); User32.INSTANCE.SetWindowLongPtr( WindowUtils.getNativeHandleOfStage(window), GWL_EXSTYLE, pointer); User32.INSTANCE.SetWindowPos(WindowUtils.getNativeHandleOfStage(window), null, 0, 0, 0, 0, SWP_FRAMECHANGED | SWP_NOMOVE | SWP_NOSIZE | SWP_NOZORDER); window.setResizable(true); } | |
| setWindowCornerPreference | back to summary |
|---|---|
| public void setWindowCornerPreference(Window window, Win11ThemeWindowManager. Sets the "roundness" of the corners of the window according to the passed in CornerPreference. Setting the corners of a transparent or undecorated Stage to be round will also make it display native window decorations (drop shadows, etc).
| |
| setWindowFrameColor | back to summary |
|---|---|
| public void setWindowFrameColor(Window window, Color color) | |
| setWindowTextColor | back to summary |
|---|---|
| public void setWindowTextColor(Window window, Color color) | |
| toRGBInt | back to summary |
|---|---|
| private int toRGBInt(final Color color) BELOW STILL NOT WORKING public void setWindowBackdrop(Dialog dialog, Backdrop backdrop) { Stage dialogStage = (Stage) dialog.getDialogPane().getScene().getWindow(); String tempTitle = "XYUZADCSD"; String dialogTitle = dialogStage.getTitle(); dialogStage.setTitle(tempTitle); WinDef.HWND hWnd = User32.INSTANCE.FindWindow(null, tempTitle); dialogStage.setTitle(dialogTitle); switch (backdrop) { case NONE -> DwmSupport.INSTANCE.DwmSetWindowAttribute( hWnd, DWMA_WINDOW_ATTRIBUTE.DWMWA_SYSTEMBACKDROP_TYPE.getValue(), new WinDef.DWORDByReference(new WinDef.DWORD(DWM_SYSTEMBACKDROP_TYPE.NONE.getValue())), WinDef.DWORD.SIZE ); case MICA -> DwmSupport.INSTANCE.DwmSetWindowAttribute( hWnd, DWMA_WINDOW_ATTRIBUTE.DWMWA_SYSTEMBACKDROP_TYPE.getValue(), new WinDef.DWORDByReference(new WinDef.DWORD(DWM_SYSTEMBACKDROP_TYPE.MICA.getValue())), WinDef.DWORD.SIZE ); case MICA_ALT -> DwmSupport.INSTANCE.DwmSetWindowAttribute( hWnd, DWMA_WINDOW_ATTRIBUTE.DWMWA_SYSTEMBACKDROP_TYPE.getValue(), new WinDef.DWORDByReference(new WinDef.DWORD(DWM_SYSTEMBACKDROP_TYPE.MICA_ALT.getValue())), WinDef.DWORD.SIZE ); case ACRYLIC -> DwmSupport.INSTANCE.DwmSetWindowAttribute( hWnd, DWMA_WINDOW_ATTRIBUTE.DWMWA_SYSTEMBACKDROP_TYPE.getValue(), new WinDef.DWORDByReference(new WinDef.DWORD(DWM_SYSTEMBACKDROP_TYPE.ACRYLIC.getValue())), WinDef.DWORD.SIZE ); } DWM.setWindowAttribute( hWnd, DWMA_WINDOW_ATTRIBUTE.DWMWA_USE_IMMERSIVE_DARK_MODE.getValue(), true ); } | |
| Modifier and Type | Field and Description |
|---|---|
| public static final Win11ThemeWindowManager. | |
| public static final Win11ThemeWindowManager. | |
| public static final Win11ThemeWindowManager. | |
| public static final Win11ThemeWindowManager. |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public static Win11ThemeWindowManager. | |
| public static Win11ThemeWindowManager. |
| ACRYLIC | back to summary |
|---|---|
| public static final Win11ThemeWindowManager. | |
| MICA | back to summary |
|---|---|
| public static final Win11ThemeWindowManager. | |
| MICA_ALT | back to summary |
|---|---|
| public static final Win11ThemeWindowManager. | |
| NONE | back to summary |
|---|---|
| public static final Win11ThemeWindowManager. | |
| Backdrop | back to summary |
|---|---|
| private Backdrop() | |
| valueOf | back to summary |
|---|---|
| public static Win11ThemeWindowManager. | |
| values | back to summary |
|---|---|
| public static Win11ThemeWindowManager. | |
| Modifier and Type | Field and Description |
|---|---|
| public static final Win11ThemeWindowManager. | |
| public static final Win11ThemeWindowManager. | |
| public static final Win11ThemeWindowManager. |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public static Win11ThemeWindowManager. | |
| public static Win11ThemeWindowManager. |
| RECTANGULAR | back to summary |
|---|---|
| public static final Win11ThemeWindowManager. | |
| ROUND | back to summary |
|---|---|
| public static final Win11ThemeWindowManager. | |
| ROUND_SMALL | back to summary |
|---|---|
| public static final Win11ThemeWindowManager. | |
| CornerPreference | back to summary |
|---|---|
| private CornerPreference() | |
| valueOf | back to summary |
|---|---|
| public static Win11ThemeWindowManager. | |
| values | back to summary |
|---|---|
| public static Win11ThemeWindowManager. | |