Skip to content

CUSTOM_CLASS_COLORS

CI edited this page Jul 14, 2021 · 1 revision

This is a community developed standard, and is intended to be a drop-in replacement for Blizzard's RAID_CLASS_COLORS. It's purpose is to allow the user to change the in-game class colors without tainting the default UI. ClassColors, created by Phanx, was the original implementation of this idea.


CUSTOM_CLASS_COLORS:RegisterCallback(handler or method, handler)

Registers a function to be called when values in CUSTOM_CLASS_COLORS are changed.

Args:

  • handler - the function to be called (function)

or

Args:

  • method - the name of a method (string)
  • handler - the method handler (table or Frame)

CUSTOM_CLASS_COLORS:UnregisterCallback(handler or method, handler)

Removes a function from the callback registry, so it will no longer be called when class colors are changed.

Args:

  • handler - a function previously registered (function)

or

Args:

  • method - the name of a registered method (string)
  • handler - the method handler (table or Frame)

CUSTOM_CLASS_COLORS:NotifyChanges()

Notifies other addons that class colors have changed.


CUSTOM_CLASS_COLORS:GetClassToken(className)

Returns the locale-independent token (eg. "WARLOCK") for the specified localized class name (eg. "Warlock" or "Hexenmeister").