Includes aliases you can use to control it, but also has functions so you can add things in triggers/etc. Make as many highlighter categories as you want, each with their own configuration. Has fg, bg, bold, underline, italics options, and the ability to pause all highlighting or just specific categories of highlighting. Any given highlight item can only belong to one category at a time, so if you add it to another it will remove from the old one and add to the new one.
The readme at https://github.com/demonnic/Highlighter has full information on the aliases and API involved.
Code: Select all
hl cat add enemy#fg = "red", bold = true
Code: Select all
hl item add enemy#Bob
Code: Select all
Highlighter:addCategory("quest items", {fg = "purple", italics = true})
Code: Select all
Highlighter:add("a rotting pumpkin", "quest items")
Code: Select all
hl item remove a rotting pumpkin
Code: Select all
hl item add friend#Bob