Colour a specific area


I have created the code below for a Squeeze indicator:

BolUp = BBandTop(Close,20,2);
BolDown = BBandBot(Close,20,2);

TypPrice = MA((High + Low + Close) / 3,20);

KeltUp = (ATR(20) * 1.5) + TypPrice;
KeltDown = TypPrice - (ATR(20) * 1.5);

SqueezeUp = BolUp - KeltUp;
SqueezeDown = BolDown - KeltDown;

Filter = Close > 1;

Plot( SqueezeUp,"SqueezeUp",colorBlue);
Plot( SqueezeDoeDown",colorRed);

I would like to colour the area between the SqueezeUp line and the 1 line in
one colour, and the area between the SqueezeDown line and the 1 line in a
different colour.

How can I do this? Thanful for all help!

Leif Axelsson

You should use code tags if adding code!

style = styleCloud | styleNoLabel;

PlotOHLC( SqueezeUp, SqueezeUp, 1, 1,"SqueezeUp", colorBlue, style );
PlotOHLC( 1, 1, SqueezeDown, SqueezeDown, "SqueezeDown", colorRed, style);



Many thanks!


IMO, this is an example where in AmiBroker we miss the possibility of having transparent colors that overlap.

@Tomasz, is there any hope for colors with an alpha channel in a future version?

Transparency is supported now via Z ordering and hollow fill Color.

Translucency which is different from transparency is not available in windows GDI, but it is possible in QuickGFX and will arrive pretty soon