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 Search | Active Topics | Log In | Register

How to set the position of title or legends Options · View
hennamullaji
#1 Posted : Thursday, April 29, 2010 4:21:58 PM
Rank: Member

Groups: Registered

Joined: 2/9/2010
Posts: 16
Location: Earth
I want to know how can we set the position of the legends and title in java code of android and not in xml.

Here is my code for the title

Code:

ChartTitle title=new ChartTitle("Patient trend");
chartView.getTitles().add(0, title);


I tried adjusting the value of location as any other number except zero....but it gives me IndexOutOfBounds Exception.
By zero it sets the position of the title below the chart.
What if I want to place it above the chart.
Similar problem with legends.

Any help would be highly appreciated.
Thanks in advance,
Henna
pturchenko
#2 Posted : Thursday, April 29, 2010 4:44:13 PM
Rank: Guest

Groups:

Joined: 7/9/2009
Posts: 3,341
Please use ChartTitle.setDock and specify desired title position as one of values of ChartLayoutElement.Dock enumeration. This should help.
hennamullaji
#3 Posted : Saturday, May 01, 2010 10:25:05 AM
Rank: Member

Groups: Registered

Joined: 2/9/2010
Posts: 16
Location: Earth
Hey thanks a lot pturchenko, this was very useful.
Thanks once again.
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-2016 ArtfulBits. All rights reserved.