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

Stack Bar Chart Label Options · View
cesaripaolo
#1 Posted : Friday, December 09, 2011 1:36:33 PM
Rank: Member

Groups: Registered

Joined: 10/17/2011
Posts: 16
Location: Italy
I'm trying to put each label behind its bar of the histogram without results.

If I enable the horizontal scrolling I would like to see the scrolling of the labels.
Is it possible to these things?

Thank you in advance.

Paolo
Baydalka Volodymyr
#2 Posted : Friday, December 09, 2011 5:21:00 PM
Rank: Developers Team


Groups: Registered, Administrators

Joined: 7/28/2009
Posts: 447
Hi,

To setup static labels you may use annotation. Please check following sample.

P.S. Please, do not post samples with you library and license file - that opposite to license agreement.

Best regards,

File Attachment(s):
Sample.zip (16kb) downloaded 6 time(s).
Volodymyr Baydalka
Andriod development and support team
cesaripaolo
#3 Posted : Friday, December 09, 2011 6:42:50 PM
Rank: Member

Groups: Registered

Joined: 10/17/2011
Posts: 16
Location: Italy
Sorry!
I didn't mind
Here's my code..
I want to put the label of a bar as background of a VERTICAL_RANGE_COLUMN.

I don't get the point of your previus replay.
I can't find examples of this application


Thank you for your attention
Paolo




public class MyFirstChartAppActivity extends Activity {

ChartType VERTICAL_RANGE_COLUMN = new ChartRangeColumnType()
{

public boolean isSideBySide() {
return false;
};
public boolean isRotated()
{
return true;
}
};

ChartType VERTIVAL_POINT = new ChartPointType()
{
public boolean isRotated()
{
return true;
}
};

static int FOOTBALL = 0;
static int RUNNING = 1;
static int SWIMMING = 2;
static int SKI = 3;
static int TENNIS = 4;

/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
ChartView chartView = new ChartView(this);
ChartSeries rangeSeries = new ChartSeries(VERTICAL_RANGE_COLUMN);
ChartSeries pointSeries = new ChartSeries(VERTIVAL_POINT);
ChartArea area = new ChartArea();

rangeSeries.getPoints().addXY(FOOTBALL, 30, 50).setLabel("Football");
rangeSeries.getPoints().addXY(RUNNING, 10, 20).setLabel("Running");
rangeSeries.getPoints().addXY(SWIMMING, 16, 33).setLabel("Swimming");
rangeSeries.getPoints().addXY(SKI, 8, 31).setLabel("Ski");
rangeSeries.getPoints().addXY(TENNIS, 14, 48).setLabel("Tennis");

pointSeries.getPoints().addXY(FOOTBALL, 34);
pointSeries.getPoints().addXY(FOOTBALL, 41);

pointSeries.getPoints().addXY(RUNNING, 16);

pointSeries.getPoints().addXY(SWIMMING, 22);
pointSeries.getPoints().addXY(SWIMMING, 28);

pointSeries.getPoints().addXY(SKI, 25);

pointSeries.getPoints().addXY(TENNIS, 43);
rangeSeries.setShowLabel(true);
pointSeries.setShowLabel(false);
pointSeries.setHLabelAlignment(Alignment.Far);
pointSeries.setVLabelAlignment(Alignment.Center);
area.getDefaultYAxis().setVisible(false);
area.getDefaultXAxis().setVisible(false);

chartView.getSeries().add(rangeSeries);
chartView.getSeries().add(pointSeries);
chartView.getAreas().add(area);

setContentView(chartView);
}
}
cesaripaolo attached the following image(s):
sample.png (92kb) downloaded 14 time(s).
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.