> For the complete documentation index, see [llms.txt](https://luadoc.edgetx.org/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://luadoc.edgetx.org/2.11/lua-api-reference/constants/color-constants.md).

# Color Constants

On radios with color display, a color may be added to the flags described above.

There are two types of color constants: one that is an index into a table holding a palette of theme colors, and one that is just a color.

## Indexed colors

These are the theme colors plus CUSTOM\_COLOR, and they can be changed with the function lcd.setColor(color\_index, color). **Please note: if an indexed color is changed, then it changes everywhere that it is used. For the theme colors, this is not only in other widgets, but everywhere throughout the radio's user interface!**

* COLOR\_THEME\_PRIMARY1
* COLOR\_THEME\_PRIMARY2
* COLOR\_THEME\_PRIMARY3
* COLOR\_THEME\_SECONDARY1
* COLOR\_THEME\_SECONDARY2
* COLOR\_THEME\_SECONDARY3
* COLOR\_THEME\_FOCUS
* COLOR\_THEME\_EDIT
* COLOR\_THEME\_ACTIVE
* COLOR\_THEME\_WARNING
* COLOR\_THEME\_DISABLED
* CUSTOM\_COLOR

## Literal colors

These color constants cannot be changed:

* BLACK
* WHITE
* LIGHTWHITE
* YELLOW
* BLUE
* DARKBLUE
* GREY
* DARKGREY
* LIGHTGREY
* RED
* DARKRED
* GREEN
* DARKGREEN
* LIGHTBROWN
* DARKBROWN
* BRIGHTGREEN
* ORANGE

## Deprecated color constants

These should no longer be used, but they are included for backwards compatibility. The old OpenTX API had a large number of indexed theme colors, and these have been mapped to the new theme colors as follows:

* ALARM\_COLOR -> COLOR\_THEME\_WARNING
* BARGRAPH\_BGCOLOR -> COLOR\_THEME\_SECONDARY3
* BARGRAPH1\_COLOR -> COLOR\_THEME\_SECONDARY1
* BARGRAPH2\_COLOR -> COLOR\_THEME\_SECONDARY2
* CURVE\_AXIS\_COLOR -> COLOR\_THEME\_SECONDARY2
* CURVE\_COLOR -> COLOR\_THEME\_SECONDARY1
* CURVE\_CURSOR\_COLOR -> COLOR\_THEME\_WARNING
* HEADER\_BGCOLOR -> COLOR\_THEME\_FOCUS
* HEADER\_COLOR -> COLOR\_THEME\_SECONDARY1
* HEADER\_CURRENT\_BGCOLOR -> COLOR\_THEME\_FOCUS
* HEADER\_ICON\_BGCOLOR -> COLOR\_THEME\_SECONDARY1
* LINE\_COLOR -> COLOR\_THEME\_PRIMARY3
* MAINVIEW\_GRAPHICS\_COLOR -> COLOR\_THEME\_SECONDARY1
* MAINVIEW\_PANES\_COLOR -> COLOR\_THEME\_PRIMARY2
* MENU\_TITLE\_BGCOLOR -> COLOR\_THEME\_SECONDARY1
* MENU\_TITLE\_COLOR -> COLOR\_THEME\_PRIMARY2
* MENU\_TITLE\_DISABLE\_COLOR -> COLOR\_THEME\_PRIMARY3
* OVERLAY\_COLOR -> COLOR\_THEME\_PRIMARY1
* SCROLLBOX\_COLOR -> COLOR\_THEME\_SECONDARY3
* TEXT\_BGCOLOR -> COLOR\_THEME\_SECONDARY3
* TEXT\_COLOR -> COLOR\_THEME\_SECONDARY1
* TEXT\_DISABLE\_COLOR -> COLOR\_THEME\_DISABLED
* TEXT\_INVERTED\_BGCOLOR -> COLOR\_THEME\_FOCUS
* TEXT\_INVERTED\_COLOR -> COLOR\_THEME\_PRIMARY2
* TITLE\_BGCOLOR -> COLOR\_THEME\_SECONDARY1
* TRIM\_BGCOLOR -> COLOR\_THEME\_FOCUS
* TRIM\_SHADOW\_COLOR -> COLOR\_THEME\_PRIMARY1
* WARNING\_COLOR -> COLOR\_THEME\_WARNING


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://luadoc.edgetx.org/2.11/lua-api-reference/constants/color-constants.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
