---
name: "ColorCmd"
section: "3"
platform: "linux"
package: "ivtools-dev"
version: "1.1.3-4"
release: "Debian 3.1 (Sarge)"
platforms: ["linux"]
url: "https://new.carta.tech/ColorCmd"
---

# ColorCmd(3)

command for setting components' color attributes

## NAME

ColorCmd - command for setting components' color attributes

## SYNOPSIS

**#include \<Unidraw/Commands/color.h\>**

## DESCRIPTION

ColorCmd is a purely interpretive command for setting the foreground and background color attributes of selected components.

## PUBLIC OPERATIONS

- **ColorCmd(ControlInfo\*, PSColor\* fg = nil, PSColor\* bg = nil)**

  - **ColorCmd(Editor\* = nil, PSColor\* fg = nil, PSColor\* bg = nil)**

  Create a ColorCmd, optionally specifying the foreground (*fg*) and background (*bg*) PSColors that components should adopt.

- **virtual void Execute()**

  ColorCmd extends Execute to set the value of the affected editor's ColorVar instance, if it defines one.

- **PSColor\* GetFgColor()**

  - **PSColor\* GetBgColor()**

  Return the PSColors supplied in the constructor.

## SEE ALSO

Command(3U), pspaint(3U), statevars(3U)
