com.github.mikephil.charting.components.YAxis.setLabelCount()方法的使用及代码示例

x33g5p2x  于2022-02-05 转载在 其他  
字(5.8k)|赞(0)|评价(0)|浏览(152)

本文整理了Java中com.github.mikephil.charting.components.YAxis.setLabelCount()方法的一些代码示例,展示了YAxis.setLabelCount()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。YAxis.setLabelCount()方法的具体详情如下:
包路径:com.github.mikephil.charting.components.YAxis
类名称:YAxis
方法名:setLabelCount

YAxis.setLabelCount介绍

暂无

代码示例

代码示例来源:origin: PhilJay/MPAndroidChart

leftAxis.setLabelCount(5, false);
leftAxis.setAxisMinimum(0f); // this replaces setStartAtZero(true)
rightAxis.setLabelCount(5, false);
rightAxis.setDrawGridLines(false);
rightAxis.setAxisMinimum(0f); // this replaces setStartAtZero(true)

代码示例来源:origin: PhilJay/MPAndroidChart

leftAxis.setLabelCount(5, false);
leftAxis.setSpaceTop(15f);
rightAxis.setLabelCount(5, false);
rightAxis.setSpaceTop(15f);

代码示例来源:origin: PhilJay/MPAndroidChart

leftAxis.setLabelCount(5, false);
leftAxis.setSpaceTop(20f);
leftAxis.setAxisMinimum(0f); // this replaces setStartAtZero(true)
rightAxis.setLabelCount(5, false);
rightAxis.setSpaceTop(20f);
rightAxis.setAxisMinimum(0f); // this replaces setStartAtZero(true)

代码示例来源:origin: PhilJay/MPAndroidChart

yAxis.setLabelCount(6);
AxisRenderer renderer = new YAxisRenderer(null, yAxis, null);
yAxis.setLabelCount(6);
yAxis.setGranularity(50f);
renderer = new YAxisRenderer(null, yAxis, null);
yAxis.setLabelCount(5, true);
renderer = new YAxisRenderer(null, yAxis, null);
yAxis.setLabelCount(5, true);
renderer = new YAxisRenderer(null, yAxis, null);
yAxis.setLabelCount(5, false);
renderer = new YAxisRenderer(null, yAxis, null);
yAxis.setLabelCount(6);
renderer = new YAxisRenderer(null, yAxis, null);
yAxis.setLabelCount(6);
renderer = new YAxisRenderer(null, yAxis, null);

代码示例来源:origin: PhilJay/MPAndroidChart

leftAxis.setLabelCount(7, false);
leftAxis.setDrawGridLines(false);
leftAxis.setDrawAxisLine(false);

代码示例来源:origin: PhilJay/MPAndroidChart

y.setLabelCount(6, false);
y.setTextColor(Color.WHITE);
y.setPosition(YAxis.YAxisLabelPosition.INSIDE_CHART);

代码示例来源:origin: PhilJay/MPAndroidChart

chart.getAxisRight().setDrawGridLines(false);
chart.getAxisRight().setDrawZeroLine(true);
chart.getAxisRight().setLabelCount(7, false);
chart.getAxisRight().setValueFormatter(new CustomFormatter());
chart.getAxisRight().setTextSize(9f);

代码示例来源:origin: PhilJay/MPAndroidChart

leftAxis.setLabelCount(6, false);
leftAxis.setAxisMinimum(-2.5f);
leftAxis.setAxisMaximum(2.5f);
rightAxis.setDrawGridLines(false);
rightAxis.setTypeface(tfLight);
rightAxis.setLabelCount(6, false);
rightAxis.setAxisMinimum(-2.5f);
rightAxis.setAxisMaximum(2.5f);

代码示例来源:origin: PhilJay/MPAndroidChart

leftAxis.setLabelCount(8, false);
leftAxis.setValueFormatter(custom);
leftAxis.setPosition(YAxisLabelPosition.OUTSIDE_CHART);
rightAxis.setDrawGridLines(false);
rightAxis.setTypeface(tfLight);
rightAxis.setLabelCount(8, false);
rightAxis.setValueFormatter(custom);
rightAxis.setSpaceTop(15f);

代码示例来源:origin: PhilJay/MPAndroidChart

yAxis.setLabelCount(5, false);
yAxis.setTextSize(9f);
yAxis.setAxisMinimum(0f);

代码示例来源:origin: fossasia/pslab-android

y.setLabelCount(10);
if (baroValue >= 0) {
  baroMeter.setWithTremble(false);

代码示例来源:origin: fossasia/pslab-android

y.setLabelCount(10);
if (luxValue >= 0) {
  lightMeter.setWithTremble(false);

代码示例来源:origin: fossasia/pslab-android

y.setLabelCount(10);
statMax.setText(String.valueOf(currentMax));
statMin.setText(String.valueOf(currentMin));

代码示例来源:origin: fossasia/pslab-android

y.setLabelCount(10);
statMax.setText(String.valueOf(currentMax));
statMin.setText(String.valueOf(currentMin));

代码示例来源:origin: fossasia/pslab-android

y.setLabelCount(10);

代码示例来源:origin: fossasia/pslab-android

y.setAxisMinimum(-10f);
y.setDrawGridLines(true);
y.setLabelCount(10);

代码示例来源:origin: fossasia/pslab-android

y.setAxisMinimum(-6.15f);
y.setDrawGridLines(true);
y.setLabelCount(10);

代码示例来源:origin: fossasia/pslab-android

yObjectTemperature.setAxisMinimum(-40f);
yObjectTemperature.setDrawGridLines(true);
yObjectTemperature.setLabelCount(10);
yAmbientTemperature.setAxisMinimum(-70f);
yAmbientTemperature.setDrawGridLines(true);
yAmbientTemperature.setLabelCount(10);

代码示例来源:origin: fossasia/pslab-android

private void setupInstruments() {
  lightMeter.setMaxSpeed(PreferenceManager.getDefaultSharedPreferences(getActivity()).getFloat(luxSensor.LUXMETER_LIMIT, 10000));
  XAxis x = mChart.getXAxis();
  this.y = mChart.getAxisLeft();
  YAxis y2 = mChart.getAxisRight();
  mChart.setTouchEnabled(true);
  mChart.setHighlightPerDragEnabled(true);
  mChart.setDragEnabled(true);
  mChart.setScaleEnabled(true);
  mChart.setDrawGridBackground(false);
  mChart.setPinchZoom(true);
  mChart.setScaleYEnabled(true);
  mChart.setBackgroundColor(Color.BLACK);
  mChart.getDescription().setEnabled(false);
  LineData data = new LineData();
  mChart.setData(data);
  Legend l = mChart.getLegend();
  l.setForm(Legend.LegendForm.LINE);
  l.setTextColor(Color.WHITE);
  x.setTextColor(Color.WHITE);
  x.setDrawGridLines(true);
  x.setAvoidFirstLastClipping(true);
  y.setTextColor(Color.WHITE);
  y.setAxisMaximum(currentMax);
  y.setAxisMinimum(currentMin);
  y.setDrawGridLines(true);
  y.setLabelCount(10);
  y2.setDrawGridLines(false);
}

代码示例来源:origin: fossasia/pslab-android

private void setupInstruments() {
  baroMeter.setMaxSpeed(PreferenceManager.getDefaultSharedPreferences(getActivity()).getFloat(baroSensor.BAROMETER_LIMIT, 2));
  XAxis x = mChart.getXAxis();
  this.y = mChart.getAxisLeft();
  YAxis y2 = mChart.getAxisRight();
  mChart.setTouchEnabled(true);
  mChart.setHighlightPerDragEnabled(true);
  mChart.setDragEnabled(true);
  mChart.setScaleEnabled(true);
  mChart.setDrawGridBackground(false);
  mChart.setPinchZoom(true);
  mChart.setScaleYEnabled(true);
  mChart.setBackgroundColor(Color.BLACK);
  mChart.getDescription().setEnabled(false);
  LineData data = new LineData();
  mChart.setData(data);
  Legend l = mChart.getLegend();
  l.setForm(Legend.LegendForm.LINE);
  l.setTextColor(Color.WHITE);
  x.setTextColor(Color.WHITE);
  x.setDrawGridLines(true);
  x.setAvoidFirstLastClipping(true);
  y.setTextColor(Color.WHITE);
  y.setAxisMaximum(currentMax);
  y.setAxisMinimum(currentMin);
  y.setDrawGridLines(true);
  y.setLabelCount(10);
  y2.setDrawGridLines(false);
  y2.setMaxWidth(0);
}

相关文章

YAxis类方法