Enum Class SyntaxHighlighter.HighlightTheme
- All Implemented Interfaces:
Serializable, Comparable<SyntaxHighlighter.HighlightTheme>, Constable
- Enclosing class:
SyntaxHighlighter
Each theme corresponds to a CSS file stored as a classpath resource. The CSS styles target elements with hljs-* classes (e.g. hljs-keyword, hljs-string, hljs-comment) produced by the highlighting engine.
Themes are organized into curated and extended sets. Each theme is classified as light, dark, or neutral.
Curated Themes (16)
| Constant | Description |
|---|---|
ATOM_ONE_LIGHT | Atom editor — clean, warm tones |
DEFAULT | Standard highlight.js — minimal |
GITHUB | GitHub code rendering |
INTELLIJ_LIGHT | JetBrains IntelliJ IDEA |
STACKOVERFLOW_LIGHT | Stack Overflow light |
TOKYO_NIGHT_LIGHT | Soft pastel Tokyo Night |
VS | Visual Studio classic |
XCODE | Apple Xcode IDE |
| Constant | Description |
|---|---|
ATOM_ONE_DARK | Atom editor dark palette |
GITHUB_DARK | GitHub dark mode |
MONOKAI | Sublime Text classic |
NIGHT_OWL | Accessibility-optimized dark |
NORD | Arctic-inspired cool tones |
STACKOVERFLOW_DARK | Stack Overflow dark |
TOKYO_NIGHT_DARK | Deep blue-black with vivid accents |
VS2015 | Visual Studio 2015 / VS Code dark |
Extended Themes (61)
An additional 61 themes from the highlight.js catalog, including popular styles such as Dracula, Gruvbox, Solarized, Android Studio, A11y (accessibility), and many more. See the individual enum constants for descriptions.
Theme CSS can be loaded without instantiating the highlighter via SyntaxHighlighter.loadThemeCss(HighlightTheme).
- Author:
- Christopher Mindus
- See Also:
Nested Class Summary
Nested classes/interfaces inherited from class Enum
Enum.EnumDesc<E>Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionA11y Dark — accessibility-focused dark theme with high contrast.A11y Light — accessibility-focused light theme with high contrast.Agate — bold dark theme with vivid syntax colors.An Old Hope — Star Wars-inspired dark theme with warm retro colors.Android Studio — dark theme matching Android Studio's Darcula scheme.Arduino Light — light theme for Arduino IDE style.Arta — dark theme with desaturated earth-tone syntax colors.Ascetic — ultra-minimal light theme with almost no color.Atom One Dark — hugely popular dark theme from the Atom editor.Atom One Dark Reasonable — a more muted variant of Atom One Dark.Atom One Light — clean, warm light theme from the Atom editor family.Brown Paper — a warm brown mid-tone theme resembling aged paper.CodePen Embed — dark theme matching CodePen's embedded code style.Color Brewer — light theme using ColorBrewer palette for data visualization.Dark — the generic dark theme from highlight.js.Default — the standard highlight.js theme; light gray background.Devibeans — a deep black dark theme with vivid accent colors.Docco — light theme inspired by the Docco documentation generator.Dracula — popular dark theme with purple and cyan accents on deep charcoal.Far — dark blue theme inspired by the FAR Manager file manager.Felipec — a minimalist dark theme with muted colors.Foundation — light theme with Zurb Foundation styling.GitHub — the familiar light theme from GitHub's code rendering.GitHub Dark — GitHub's official dark mode code rendering.GitHub Dark Dimmed — a softer, less contrasty variant of GitHub Dark.GML — dark theme for GameMaker Language style.Google Code — light theme inspired by old Google Code syntax highlighting.Gradient Dark — dark theme with subtle gradient backgrounds.Gradient Light — light theme with subtle gradient backgrounds.Grayscale — monochrome light theme using only gray tones.Gruvbox Dark — retro, earthy dark palette with warm tones.Gruvbox Light — retro, earthy light palette with warm tones.Hybrid — a dark theme blending multiple color palettes.IDEA — IntelliJ IDEA classic light scheme.IntelliJ Light — inspired by JetBrains IntelliJ IDEA's default scheme.IR Black — a classic dark terminal-style theme.ISBL Editor Dark — dark variant of the ISBL editor theme.ISBL Editor Light — light variant of the ISBL editor theme.Kimbie Dark — warm dark theme with brown-orange tones.Kimbie Light — warm cream-toned light theme.Lightfair — bright, clean light theme with blue accents.Lioshi — a dark theme with green and cyan accents.Magula — soft light theme with muted colors.Mono Blue — light theme using only shades of blue.Monokai — the iconic dark theme originating from Sublime Text.Monokai Sublime — the Monokai variant popularized by Sublime Text.Night Owl — a dark theme optimized for accessibility and contrast.NNFX Dark — dark variant of the No Nonsense FX theme.NNFX Light — light variant of the No Nonsense FX theme.Nord — an elegant arctic-inspired dark color palette.Obsidian — a dark theme with olive and amber accents.Panda Syntax Dark — dark variant of the popular Panda theme.Panda Syntax Light — light variant of the popular Panda theme.Paraiso Dark — dark variant with warm tropical-inspired colors.Paraiso Light — light variant with warm tropical-inspired colors.Pojoaque — a dark Solarized-like theme with teal backgrounds.PureBasic — light theme styled after the PureBasic IDE.Qt Creator Dark — dark variant of the Qt Creator IDE theme.Qt Creator Light — light variant of the Qt Creator IDE theme.Rainbow — a vivid dark theme with colorful syntax highlighting.RouterOS — light theme inspired by MikroTik RouterOS style.School Book — playful light theme with a notebook-paper feel.Shades of Purple — a vibrant purple-toned dark theme.Solarized Dark — Ethan Schoonover's carefully designed dark palette.Solarized Light — Ethan Schoonover's carefully designed light palette.Srcery — a dark theme inspired by the Gruvbox and Apprentice palettes.Stack Overflow Dark — the dark theme from Stack Overflow.Stack Overflow Light — the clean light theme from Stack Overflow.Sunburst — a classic dark theme with warm highlight colors.Tokyo Night Dark — a deep blue-black theme with vivid accents.Tokyo Night Light — soft pastel light variant of the Tokyo Night family.Tomorrow Night Blue — a deep blue dark theme from the Tomorrow family.Tomorrow Night Bright — a vivid dark theme from the Tomorrow family.Visual Studio — classic Visual Studio light color scheme.VS 2015 — Visual Studio 2015 / VS Code dark theme.Xcode — Apple's Xcode IDE default light theme.XT256 — a retro dark theme inspired by vintage terminal displays.Method Summary
Modifier and TypeMethodDescriptionfileName()Returns the CSS file name without extension (e.g.Finds a theme by its CSS file name (case-insensitive).getName()Returns the human-readable display name for this theme.booleanReturnstrueif this theme is in the curated set.booleanisDark()Returnstrueif this is a dark theme.booleanisLight()Returnstrueif this is a light theme.booleanReturnstrueif this is a neutral (mid-tone) theme.Returns the classpath resource path for this theme's CSS file.themeSet()Returns which set this theme belongs to.Returns the theme type classification.Returns the enum constant of this class with the specified name.static SyntaxHighlighter.HighlightTheme[]values()Returns an array containing the constants of this enum class, in the order they are declared.
Enum Constant Details
ATOM_ONE_LIGHT
Atom One Light — clean, warm light theme from the Atom editor family.DEFAULT
Default — the standard highlight.js theme; light gray background.GITHUB
GitHub — the familiar light theme from GitHub's code rendering.INTELLIJ_LIGHT
IntelliJ Light — inspired by JetBrains IntelliJ IDEA's default scheme.STACKOVERFLOW_LIGHT
Stack Overflow Light — the clean light theme from Stack Overflow.TOKYO_NIGHT_LIGHT
Tokyo Night Light — soft pastel light variant of the Tokyo Night family.VS
Visual Studio — classic Visual Studio light color scheme.XCODE
Xcode — Apple's Xcode IDE default light theme.ATOM_ONE_DARK
Atom One Dark — hugely popular dark theme from the Atom editor.GITHUB_DARK
GitHub Dark — GitHub's official dark mode code rendering.MONOKAI
Monokai — the iconic dark theme originating from Sublime Text.NIGHT_OWL
Night Owl — a dark theme optimized for accessibility and contrast.NORD
Nord — an elegant arctic-inspired dark color palette.STACKOVERFLOW_DARK
Stack Overflow Dark — the dark theme from Stack Overflow.TOKYO_NIGHT_DARK
Tokyo Night Dark — a deep blue-black theme with vivid accents.VS2015
VS 2015 — Visual Studio 2015 / VS Code dark theme.A11Y_LIGHT
A11y Light — accessibility-focused light theme with high contrast.ARDUINO_LIGHT
Arduino Light — light theme for Arduino IDE style.ASCETIC
Ascetic — ultra-minimal light theme with almost no color.COLOR_BREWER
Color Brewer — light theme using ColorBrewer palette for data visualization.DOCCO
Docco — light theme inspired by the Docco documentation generator.FOUNDATION
Foundation — light theme with Zurb Foundation styling.GOOGLECODE
Google Code — light theme inspired by old Google Code syntax highlighting.GRADIENT_LIGHT
Gradient Light — light theme with subtle gradient backgrounds.GRUVBOX_LIGHT
Gruvbox Light — retro, earthy light palette with warm tones.GRAYSCALE
Grayscale — monochrome light theme using only gray tones.IDEA
IDEA — IntelliJ IDEA classic light scheme.ISBL_EDITOR_LIGHT
ISBL Editor Light — light variant of the ISBL editor theme.KIMBIE_LIGHT
Kimbie Light — warm cream-toned light theme.LIGHTFAIR
Lightfair — bright, clean light theme with blue accents.MAGULA
Magula — soft light theme with muted colors.MONO_BLUE
Mono Blue — light theme using only shades of blue.NNFX_LIGHT
NNFX Light — light variant of the No Nonsense FX theme.PANDA_SYNTAX_LIGHT
Panda Syntax Light — light variant of the popular Panda theme.PARAISO_LIGHT
Paraiso Light — light variant with warm tropical-inspired colors.PUREBASIC
PureBasic — light theme styled after the PureBasic IDE.QTCREATOR_LIGHT
Qt Creator Light — light variant of the Qt Creator IDE theme.ROUTEROS
RouterOS — light theme inspired by MikroTik RouterOS style.SCHOOL_BOOK
School Book — playful light theme with a notebook-paper feel.SOLARIZED_LIGHT
Solarized Light — Ethan Schoonover's carefully designed light palette.A11Y_DARK
A11y Dark — accessibility-focused dark theme with high contrast.AGATE
Agate — bold dark theme with vivid syntax colors.AN_OLD_HOPE
An Old Hope — Star Wars-inspired dark theme with warm retro colors.ANDROIDSTUDIO
Android Studio — dark theme matching Android Studio's Darcula scheme.ARTA
Arta — dark theme with desaturated earth-tone syntax colors.ATOM_ONE_DARK_REASONABLE
Atom One Dark Reasonable — a more muted variant of Atom One Dark.CODEPEN_EMBED
CodePen Embed — dark theme matching CodePen's embedded code style.DARK
Dark — the generic dark theme from highlight.js.DEVIBEANS
Devibeans — a deep black dark theme with vivid accent colors.DRACULA
Dracula — popular dark theme with purple and cyan accents on deep charcoal.FAR
Far — dark blue theme inspired by the FAR Manager file manager.FELIPEC
Felipec — a minimalist dark theme with muted colors.GITHUB_DARK_DIMMED
GitHub Dark Dimmed — a softer, less contrasty variant of GitHub Dark.GML
GML — dark theme for GameMaker Language style.GRADIENT_DARK
Gradient Dark — dark theme with subtle gradient backgrounds.GRUVBOX_DARK
Gruvbox Dark — retro, earthy dark palette with warm tones.HYBRID
Hybrid — a dark theme blending multiple color palettes.IR_BLACK
IR Black — a classic dark terminal-style theme.ISBL_EDITOR_DARK
ISBL Editor Dark — dark variant of the ISBL editor theme.KIMBIE_DARK
Kimbie Dark — warm dark theme with brown-orange tones.LIOSHI
Lioshi — a dark theme with green and cyan accents.MONOKAI_SUBLIME
Monokai Sublime — the Monokai variant popularized by Sublime Text.NNFX_DARK
NNFX Dark — dark variant of the No Nonsense FX theme.OBSIDIAN
Obsidian — a dark theme with olive and amber accents.PANDA_SYNTAX_DARK
Panda Syntax Dark — dark variant of the popular Panda theme.PARAISO_DARK
Paraiso Dark — dark variant with warm tropical-inspired colors.POJOAQUE
Pojoaque — a dark Solarized-like theme with teal backgrounds.QTCREATOR_DARK
Qt Creator Dark — dark variant of the Qt Creator IDE theme.RAINBOW
Rainbow — a vivid dark theme with colorful syntax highlighting.SHADES_OF_PURPLE
Shades of Purple — a vibrant purple-toned dark theme.SOLARIZED_DARK
Solarized Dark — Ethan Schoonover's carefully designed dark palette.SRCERY
Srcery — a dark theme inspired by the Gruvbox and Apprentice palettes.SUNBURST
Sunburst — a classic dark theme with warm highlight colors.TOMORROW_NIGHT_BLUE
Tomorrow Night Blue — a deep blue dark theme from the Tomorrow family.TOMORROW_NIGHT_BRIGHT
Tomorrow Night Bright — a vivid dark theme from the Tomorrow family.XT256
XT256 — a retro dark theme inspired by vintage terminal displays.BROWN_PAPER
Brown Paper — a warm brown mid-tone theme resembling aged paper.
Method Details
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
getName
Returns the human-readable display name for this theme.Examples:
"GitHub Dark","VS 2015","Stack Overflow Light","Android Studio","IDEA".- Returns:
- The display name, never
null.
fileName
Returns the CSS file name without extension (e.g."github-dark").themeType
Returns the theme type classification.themeSet
Returns which set this theme belongs to.isLight
public boolean isLight()Returnstrueif this is a light theme.isDark
public boolean isDark()Returnstrueif this is a dark theme.isNeutral
public boolean isNeutral()Returnstrueif this is a neutral (mid-tone) theme.isCurated
public boolean isCurated()Returnstrueif this theme is in the curated set.resourcePath
Returns the classpath resource path for this theme's CSS file.Curated themes are located at
/co/mindus/utils/hl/css/curated/<n>.css, extended themes at/co/mindus/utils/hl/css/extended/<n>.css.forName
Finds a theme by its CSS file name (case-insensitive).- Parameters:
fileName- The CSS file name without extension (e.g."github-dark").- Returns:
- The matching theme, or
nullif not found.