Interface Theme

All Known Implementing Classes:
CupertinoDark, CupertinoLight, Dracula, NordDark, NordLight, PrimerDark, PrimerLight

public interface Theme
The basic theme interface.
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns theme name.
    Returns the path to the theme user-agent stylesheet.
    @Nullable String
    Returns the path to the theme user-agent stylesheet in binary (BSS) format.
    boolean
    Signifies whether the theme uses a light font on a dark background or vise versa.
    default boolean
    Returns whether the theme is a standard theme provided by the OpenJFX or a custom theme.
    static Theme
    of(String name, String userAgentStylesheet, boolean darkMode)
    A simple factory method for instantiating a new theme.
  • Method Details

    • getName

      String getName()
      Returns theme name.
    • getUserAgentStylesheet

      String getUserAgentStylesheet()
      Returns the path to the theme user-agent stylesheet. See Application.setUserAgentStylesheet(String) for more info.
    • getUserAgentStylesheetBSS

      @Nullable @Nullable String getUserAgentStylesheetBSS()
      Returns the path to the theme user-agent stylesheet in binary (BSS) format. See Application.setUserAgentStylesheet(String) for more info. All built-in themes are available in BSS format, but custom themes may not, hence the method may return null value.
    • isDarkMode

      boolean isDarkMode()
      Signifies whether the theme uses a light font on a dark background or vise versa.
    • of

      static Theme of(String name, String userAgentStylesheet, boolean darkMode)
      A simple factory method for instantiating a new theme.
    • isDefault

      default boolean isDefault()
      Returns whether the theme is a standard theme provided by the OpenJFX or a custom theme.