whitespace COMPANY whitespace SERVICES whitespace PRODUCTS whitespace PURCHASE whitespace SUPPORT whitespace CONTACTS whitespace Home whitespace Contact Us whitespace Site Map whitespace
whitespace
SUPPORT
whitespace
FORUM
whitespace
FAQS
whitespace
SUBSCRIPTION
whitespace
REQUEST ON-LINE
whitespace
whitespace

Technical Support Forum

Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Options
View
Go to last post Go to first unread
ccoroom  
#1 Posted : Wednesday, June 30, 2010 3:54:45 PM(UTC)
ccoroom
Rank: Member

Groups: Registered
Joined: 3/15/2010(UTC)
Posts: 10

Hi,

When I add a legend to the chart with more than two series. It works.
But, when I add a legend that has only one series, it draw all of single point and its value for the legend.

I have solved this problem by adding transparent dummy series. I post this issue for your information. I'm using aichart 1.5.

Code:
        // adding a dummy series
        ChartSeries dummy = new ChartSeries(" ", ChartTypes.CandleStick);
        dummy.setBackColor(Color.TRANSPARENT);
        addSeries(dummy);


Code:
// adding a lenged
ChartLegend legend = new ChartLegend();
        legend.setDock(ChartLayoutElement.Dock.Top);
        legend.setAlignment(ChartLayoutElement.Alignment.Near);
        legend.getTextPaint().setAntiAlias(true);
        legend.getTextPaint().setColor(Color.WHITE);

        mChartView.getLegends().add(legend);


Regards,
Sung Ahn Kim.
Baydalka Volodymyr  
#2 Posted : Wednesday, June 30, 2010 5:00:56 PM(UTC)
Baydalka Volodymyr
Rank: Member

Groups: Registered
Joined: 7/28/2009(UTC)
Posts: 447
Man

Hi,

Please, use next code to change legend items generation behavior.

Code:
legend.setItemsProvider(new LegendItemsProvider.SeriesItemsProvider());


Best regards,
Volodymyr Baydalka
Andriod development and support team
Users browsing this topic
Guest
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.

Company | Services | Practices | Technologies | Career | Contacts | Privacy
© 2005-2017 ArtfulBits. All rights reserved.