ASE Home Page Products Download Purchase Support About ASE
ChartDirector Support
Forum HomeForum Home   SearchSearch

Message ListMessage List     Post MessagePost Message

  Problem using Chart::whiteOnBlackPalette
Posted by Ivan Zhang on Jul-19-2011 00:40
Hello,

I'm currently trying to plot a Finance chart on a black background. I put a mainChart on top
of the chart and a volBar indicator at the bottom, and I set the color palette as follows:

mainChart->setColors(Chart::whiteOnBlackPalette);
volBar->setColors(Chart::whiteOnBlackPalette);

However, this results in the black background color of volBar covering part of mainChart. Is
there an easy way to get around this problem?

Thank you!

Best,
Ivan

  Re: Problem using Chart::whiteOnBlackPalette
Posted by Peter Kwan on Jul-19-2011 03:14
Hi Ivan,

As you have already noticed, the XYCharts in the FinanceChart are actually partially overlapping. They does not block each others because the chart background is transparent.

For your case, you may consider to set the XYChart background to transparent, and also apply whiteOnBlackPalette on the FinanceChart object itself. For example:

myFinanceChart->setColors(Chart::whiteOnBlackPalette);

mainChart->setColors(Chart::whiteOnBlackPalette);
mainChart->setBackground(Chart::Transparent);
volBar->setColors(Chart::whiteOnBlackPalette);
volBar->setBackground(Chart::Transparent);

The actual dark background is provided by the FinanceChart container, while the backgrounds of the mainChart and volBar are transparent.

Hope this can help.

Regards
Peter Kwan