icons
Phosphor icon constants. The phosphor font is registered as a named family `phosphor` in the engine, so render icons by setting `style.fontFamily = "phosphor"` on the label that contains them.
icons
Phosphor icon constants. The phosphor font is registered as a named
family phosphor in the engine, so render icons by setting
style.fontFamily = "phosphor" on the label that contains them.
The font is ALSO appended to the proportional family as a fallback, but
the fallback path is unreliable for PUA codepoints in egui 0.34 (see
issue #2191) — always pass fontFamily = "phosphor" for icons.
Curated set covering DAW transport, media controls, file management, desktop shell, editor chrome, and common state indicators. For icons not listed here, see https://phosphoricons.com — pass the codepoint as a UTF-8 string literal directly.
Exports
Icon.styled(extra: LabelOpts?) -> LabelOpts— build aUI.labelopts table withstyle.fontFamily = "phosphor"applied. Merges with the suppliedextra.Icon.<Name>: string— UTF-8 codepoint constants. Categories:- Transport / media:
Play,Pause,Stop,Record,FastForward,Rewind,SkipForward,SkipBack,Repeat,Shuffle. - Audio / DAW:
Microphone,Headphones,Equalizer,Sliders,Metronome,MusicNote,Waveform,SpeakerHigh,SpeakerLow,SpeakerNone,SpeakerSimpleHigh,SpeakerMuted. - File / folder:
Folder,FolderOpen,File,FileText,FileAudio,FileVideo,FileImage,FileCode,FloppyDisk,Trash,UploadSimple,DownloadSimple. - Desktop / shell:
Desktop,DesktopTower,Monitor,Keyboard,Mouse,House,Sidebar,Cpu. - Editor:
Pencil,Plus,Minus,Check,MagnifyingGlass(Plus|Minus)?,Gear,Power,Eye,EyeSlash,Lock,LockOpen,Bell,Palette,Funnel,Clipboard. - Code / dev:
Code,Terminal,Bug,GitBranch,GitCommit,GitMerge,Database,Cloud. - Arrows / nav:
ArrowUp/Down/Left/Right,ArrowsClockwise,ArrowsIn,ArrowsOut,CaretUp/Down/Left/Right. - Layout / list:
List,GridFour,DotsThree,DotsThreeVertical. - State / status:
Info,Warning,WarningCircle,CheckCircle,XCircle,Question,Heart,Star,Tag,Hash,At. - Shapes:
Circle,Square,Triangle. - Productivity / shell apps:
Calculator,Notepad,NotePencil,Note. - Games / cards:
GameController,Bomb,Cards,Diamond,Spade,Club.
- Transport / media:
Types:
LabelStyle = { fontFamily?: string, fontSize?: number, color?: string, [string]: any }LabelOpts = { style?: LabelStyle, [string]: any }
Usage
local Icon = require("@builtin::modules.icons")
UI.label(Icon.Play, { style = { fontFamily = "phosphor", fontSize = 24 } })
UI.label(Icon.Folder .. " Documents", {
style = { fontFamily = "phosphor", fontSize = 14 },
})
-- Or use the helper to enforce the phosphor family:
UI.label(Icon.Play, Icon.styled({ style = { fontSize = 24, color = "#fff" } }))
Notes
- The constants are plain string values — each is a single UTF-8 Private Use Area codepoint. Concatenate freely with surrounding text.
Icon.styledmutates the supplied opts table (extra.styleis forced). Pass a fresh table per call site if you need to reuse opts.- Curated subset only — for icons outside this set, paste the codepoint from https://phosphoricons.com directly.
Scoped to this part · feeds back into the world's score.