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
hectorharvey  
#1 Posted : Monday, February 7, 2011 2:15:58 AM(UTC)
hectorharvey
Rank: Newbie

Groups: Registered
Joined: 2/1/2011(UTC)
Posts: 5
Location: Atlanta

Can you tell me how to determine the width of a bar in a column chart? I allow the user to select a bar, and if it is too small, it's hard to select with a finger. So I want to allow zoom up to a certain point, based on the width of the bar.
Baydalka Volodymyr  
#2 Posted : Monday, February 7, 2011 7:08:47 PM(UTC)
Baydalka Volodymyr
Rank: Member

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

Hi,

Check following code
Code:
public float measureColumnWidth(ChartArea area, ChartSeries series)
{
	PointF startPoint = new PointF();
	PointF endPoint = new PointF();
	DoubleRange sbsInfo = ChartRenderArgs.getSideBySideOffset(series, series.getType(), area);
	ChartTransform transform = ChartTransform.create(series);
	
	transform.getPoint(sbsInfo.Minimum, 0, startPoint);
	transform.getPoint(sbsInfo.Maximum, 0, endPoint);
	
	return endPoint.x - startPoint.x;
}


NOTE : do not use this method before ChartView appears.

Best regards,
Volodymyr Baydalka
Andriod development and support team
hectorharvey  
#3 Posted : Tuesday, February 8, 2011 8:31:02 AM(UTC)
hectorharvey
Rank: Newbie

Groups: Registered
Joined: 2/1/2011(UTC)
Posts: 5
Location: Atlanta

Perfect. Thanks.
Users browsing this topic
Guest (2)
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.