Welcome Guest, please sign in to participate in a discussion. Search | Active Topics |

Explicit color and opacity definition Rate this Topic:
Previous Topic · Next Topic Watch this topic · Print this topic ·
3dbeing
Posted : Wednesday, August 24, 2011 7:39:36 AM
Registered User
Joined: 6/24/2009
Posts: 178
How can I explicitly declare the color and opacity for painting price and indicators?  ie:  rather than choosing color names I would like to use numerical definitions

cheers

-=3db
Bruce_L
Posted : Wednesday, August 24, 2011 7:47:47 AM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138
If you are using a RealCode Paint Scheme, the fromARGB method allows you to define the degree of transparency using an alpha channel and also contain RGB bytes for color information.

PlotColor = Color.fromARGB(255, 255, 255, 255)

The first number is the Alpha (and affects transparency) - 0 is transparent, 255 is solid.
The second number is Red - 0 means no red, 255 means max red.
The third number is Green - 0 means no green, 255 means max green.
The fourth number is Blue - 0 means no blue, 255 means max blue.

Each of the numbers is a byte and must be between 0 and 255 (inclusive).

Paint Schemes

-Bruce
Personal Criteria Formulas
TC2000 Support Articles
3dbeing
Posted : Wednesday, August 24, 2011 9:24:36 AM
Registered User
Joined: 6/24/2009
Posts: 178
Great! Thanks for that...
Bruce_L
Posted : Wednesday, August 24, 2011 9:25:48 AM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138
You're welcome.

-Bruce
Personal Criteria Formulas
TC2000 Support Articles
Users browsing this topic
Guest-1

Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.