I am looking for a control code to create orange text in a terminal using ANSI or some other standard, is this possible? I only see yellow and red available, and I don't think you can mix red and yellow for the same character :)
Strictly speaking, no: ANSI never standardized anything (for a terminal's control sequences) which was called "orange". Some terminals can do this, but that lies outside the scope of the standards.
xterm (see XTerm Control Sequences) uses control sequences following the "ANSI" (actually withdrawn from standardization long ago) ECMA-48 syntax.
Orange can be composed by an RGB code. For instance X's rgb.txt file defines it as
255 165 0 orange
(bright red plus a moderately bright green). To get that in a shell script, one could use
#!/bin/sh
printf "\033[48:2:255:165:0m%s\033[m\n" "Hello world"
printf "\033[48;2;255;165;0m%s\033[m\n" "Hello world"
The difference between the two lines is the use of colon as a parameter separator (ECMA-48 has some verbiage which prefers that, for subparameters as used in xterm, which was overlooked early on). For compatibility (including with terminals copied from xterm's early implementation), xterm honors both.
xterm also supports a "non-ANSI" scheme referred to as dynamic colors, which accepts a color name, but that sets the text color for the whole screen.
Finally, xterm can assign colors to display instead of blink, bold, italics, reverse and underline (see the discussion of colorBD
for instance). That is done though X resource settings (with some help from escape sequences). The colors assigned to those resources can be set via the same 88/256 color extension.