ColorCmd(3U)

πŸ’– ColorCmd(3U) πŸ’–

okay bestie, welcome to the InterViews Reference Manual ✨ this lil page is all about ColorCmd, and honestly? she's giving glow-up energy πŸŽ€


✨ NAME ✨

ColorCmd β€” the command for setting components' color attributes 🌈


✨ SYNOPSIS ✨

#include <Unidraw/Commands/color.h>

✨ DESCRIPTION ✨

so like, ColorCmd is a purely interpretive command, no cap πŸ’… and what does she do? she sets the foreground and background color attributes of your selected components. that's it, that's the whole vibe. iconic behavior fr fr πŸ¦‹


✨ PUBLIC OPERATIONS ✨

  • ColorCmd(ControlInfo*, PSColor* fg = nil, PSColor* bg = nil)
  • ColorCmd(Editor* = nil, PSColor* fg = nil, PSColor* bg = nil) β€” make yourself a ColorCmd 🫢 you can optionally pass in the foreground (fg) and background (bg) PSColors that your components should adopt. and yeah, both of them default to nil, so no pressure 🌸
  • virtual void Execute() β€” ColorCmd extends Execute so it sets the value of the affected editor's ColorVar instance, if it defines one. that "if" is doing a lot of work bestie, don't skip it πŸ‘‘
  • PSColor* GetFgColor()
  • PSColor* GetBgColor() β€” hand over the PSColors you supplied in the constructor. that's it, that's the tea β˜•

✨ SEE ALSO ✨

Command(3U), pspaint(3U), statevars(3U) β€” go read these too, they're the friend group πŸ’œ


and that's the whole page!! this one came from Unidraw, dated 23 January 1991 (yes she's vintage, yes she still ate πŸ’…), and the manual name is ColorCmd(3U) in case you forgot already πŸ™ˆ mwah, go color something pretty πŸŽ€βœ¨