Get Class Coords
UI Utility
Returns class icon atlas coordinates with optional cropping.
NamespaceEModuleCoreLifecyclestable
E:GetClassCoords(classFile, crop, get)Returns class icon atlas coordinates with optional cropping.
Parameters
Section titled “Parameters”- classFile: Class token used by CLASS_ICON_TCOORDS.
- crop: Boolean or numeric crop amount.
- get: Boolean; returns the raw coordinate table when true.
Returns
Section titled “Returns”left, right, top, bottom texture coordinates, or raw table when get is true.
Example
Section titled “Example”local l, r, t, b = E:GetClassCoords("DRUID", true)icon:SetTexCoord(l, r, t, b)Handy for addon class icons that should use ElvUI’s crop conventions.
Source: ElvUI/Game/Shared/General/API.lua:1253