Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » BIRT » Blank space in legend when hidden(A question on how to hide/remove legend items)
Blank space in legend when hidden [message #722885] Wed, 07 September 2011 00:50
akshay.s86 is currently offline akshay.s86
Messages: 1
Registered: September 2011
Junior Member
Hey

I looked around for this question all over the forums but did not come across one.

Basically, I have a bunch of line plots on a graph (say about 10-20) and I am able to mark some lines based on some conditions and not mark the other lines. I am masking these lines because I want to show them in the legend and the lines that are not marked, I dont want to show them in the legend.

In beforeDrawLegendItem method,

if(some-condition-is-met-to-hide-legend-entry) {
lerh.getLabel().setVisible(false);
lerh.getLabel().getCaption().setValue("");
lerh.getLabel().setEllipsis(0);
bounds.setHeight(0);
bounds.setWidth(0);
}

What happens is that this creates blank spaces in the legend. The legend element is hidden but the space allotted to it remains and is unused by the other visible legend elements. I was wondering if there is a solution to this.

Thanks a ton!!
Previous Topic:Multiple child in cascading param group
Next Topic:OutOfMemory when rendering a crosstab report in WebViewer
Goto Forum:
  


Current Time: Thu Aug 21 06:14:00 EDT 2014

Powered by FUDForum. Page generated in 0.01628 seconds