Difference between revisions of "RGB"

From MultiCharts
Jump to navigation Jump to search
(Created page with "Returns an RGB color number that corresponds to the specified combination of red, green, and blue component color values; the number ranges from 0 to 16777215 and represents o...")
 
m
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 
Returns an RGB color number that corresponds to the specified combination of red, green, and blue component color values; the number ranges from 0 to 16777215 and represents one of 16 M colors.   
 
Returns an RGB color number that corresponds to the specified combination of red, green, and blue component color values; the number ranges from 0 to 16777215 and represents one of 16 M colors.   
  
==== Usage ====
+
== Usage ==
<syntaxhighlight>RGB (Red,Green,Blue)</syntaxhighlight>  
+
<syntaxhighlight>RGB(Red, Green, Blue)</syntaxhighlight>  
  
Where: <syntaxhighlight>Red</syntaxhighlight>  – a numerical value from 0 to 255, specifying the Red component of the RGB color
+
Where:  
            <syntaxhighlight>Green</syntaxhighlight> – a numerical value from 0 to 255, specifying the Green component of the RGB color
+
 
            <syntaxhighlight>Blue</syntaxhighlight>  – a numerical value from 0 to 255, specifying the Blue component of the RGB color  
+
:'''Red''' – a numerical value from 0 to 255, specifying the Red component of the RGB color.
 +
 
 +
:'''Green''' – a numerical value from 0 to 255, specifying the Green component of the RGB color.
 +
 
 +
:'''Blue''' – a numerical value from 0 to 255, specifying the Blue component of the RGB color.
 +
 
 +
== Notes ==
 +
See for example [https://en.wikipedia.org/wiki/Web_colors#X11_color_names this Wikipedia entry] or [http://cloford.com/resources/colours/500col.htm this web page] for an extensive list of RGB colors.
 
   
 
   
==== Example ====
+
== Example ==
 
Create an Orange color plot using the RGB color combination:  
 
Create an Orange color plot using the RGB color combination:  
  
 
<syntaxhighlight>Plot1(Open);
 
<syntaxhighlight>Plot1(Open);
SetPlotColor(1,RGB(224,160,32));</syntaxhighlight>
+
SetPlotColor(1, RGB(224, 160, 32));</syntaxhighlight>
 
 
  
 
[[Category:Colors]]
 
[[Category:Colors]]

Latest revision as of 07:42, 19 February 2012

Returns an RGB color number that corresponds to the specified combination of red, green, and blue component color values; the number ranges from 0 to 16777215 and represents one of 16 M colors.

Usage

RGB(Red, Green, Blue)

Where:

Red – a numerical value from 0 to 255, specifying the Red component of the RGB color.
Green – a numerical value from 0 to 255, specifying the Green component of the RGB color.
Blue – a numerical value from 0 to 255, specifying the Blue component of the RGB color.

Notes

See for example this Wikipedia entry or this web page for an extensive list of RGB colors.

Example

Create an Orange color plot using the RGB color combination:

Plot1(Open);
SetPlotColor(1, RGB(224, 160, 32));