Skip to content

Automatic Colors for Pitch Accent

The pitch accent downstep (lines and drop number) is automatically colored based on the word’s pitch accent pattern. Depending on your settings, this coloring can apply only to the downstep itself, extend to the entire word and its reading, or be fully disabled. Sentence highlights can also optionally inherit the word’s pitch color.

Word Pitch Coloring

Enabled

Alt Style

Disabled

Sentence Highlight Pitch Coloring

Enabled

Disabled

Pitch Patterns

Pattern Word Reading Drop Position
heiban (平板) 承認
0
atamadaka (頭高) 運命 1
nakadaka (中高) 喜んで 3
odaka (尾高) 役目
3
kifuku (起伏) 可笑しい 3

Customization

You can change how the pitch downstep, word, and sentence highlight are colored via the variables in the /* PITCH ACCENT SETTINGS */ section of the CSS:

--pitch-style:              default; /* "alt" to color the entire word + reading instead of only the downstep */
--pitch-colors:             true;    /* "false" to disable pitch downstep coloring */
--sentence-pitch-highlight: false;   /* "true" to make pitch colors overwrite sentence highlights */
  • Pitch downstep coloring is enabled by default. To completely disable pitch colors, set -pitch-colors to false
  • With the pitch style set to default. only the downstep is colored. To apply the pitch color to the entire word and its reading, set --pitch-style to alt.
  • By default, the target word in sentences uses the theme’s standard highlight color. To instead highlight it using the word’s pitch color, set --sentence-pitch-highlight to true.