GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Added share images. · FlyingAndroid/MPAndroidChart@456626f

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • MPChartLib/src/com/github/mikephil/charting/charts
    • HorizontalBarChart.java
  • design
    • facebook_icon.png
    • googleplus_icon.png
    • twitter_icon.png
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎MPChartLib/src/com/github/mikephil/charting/charts/HorizontalBarChart.java‎

Copy file name to clipboardExpand all lines: MPChartLib/src/com/github/mikephil/charting/charts/HorizontalBarChart.java
+9-7Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,8 @@
2222

2323
/**
2424
* BarChart with horizontal bar orientation. In this implementation, x- and
25-
* y-axis are switched.
25+
* y-axis are switched, meaning the YAxis class represents the horizontal values
26+
* and the XAxis class represents the vertical values.
2627
*
2728
* @author Philipp Jahoda
2829
*/
@@ -53,7 +54,7 @@ protected void init() {
5354
mXAxisRenderer = new XAxisRendererHorizontalBarChart(mViewPortHandler, mXAxis,
5455
mLeftAxisTransformer, this);
5556
}
56-
57+
5758
@Override
5859
protected void calculateOffsets() {
5960

@@ -86,7 +87,8 @@ protected void calculateOffsets() {
8687
}
8788

8889
if (mAxisRight.needsOffset()) {
89-
offsetBottom += mAxisRight.getRequiredHeightSpace(mAxisRendererRight.getPaintAxisLabels());
90+
offsetBottom += mAxisRight.getRequiredHeightSpace(mAxisRendererRight
91+
.getPaintAxisLabels());
9092
}
9193

9294
float xlabelwidth = mXAxis.mLabelWidth;
@@ -142,7 +144,7 @@ protected void calcModulus() {
142144
mXAxis.mAxisLabelModulus = (int) Math
143145
.ceil((mData.getXValCount() * mXAxis.mLabelHeight)
144146
/ (mViewPortHandler.contentHeight() * values[Matrix.MSCALE_Y]));
145-
147+
146148
if (mXAxis.mAxisLabelModulus < 1)
147149
mXAxis.mAxisLabelModulus = 1;
148150
}
@@ -165,14 +167,14 @@ public RectF getBarBounds(BarEntry e) {
165167
float bottom = x + 0.5f - spaceHalf;
166168
float left = y >= 0 ? y : 0;
167169
float right = y <= 0 ? y : 0;
168-
170+
169171
RectF bounds = new RectF(left, top, right, bottom);
170172

171173
getTransformer(set.getAxisDependency()).rectValueToPixel(bounds);
172174

173175
return bounds;
174176
}
175-
177+
176178
@Override
177179
public PointF getPosition(Entry e, AxisDependency axis) {
178180

@@ -187,7 +189,7 @@ public PointF getPosition(Entry e, AxisDependency axis) {
187189

188190
return new PointF(vals[0], vals[1]);
189191
}
190-
192+
191193
/**
192194
* Returns the Highlight object (contains x-index and DataSet index) of the
193195
* selected value at the given touch point inside the BarChart.
Collapse file

‎design/facebook_icon.png‎

Copy file name to clipboard
6.86 KB
  • Display the source diff
  • Display the rich diff
Loading
Collapse file

‎design/googleplus_icon.png‎

Copy file name to clipboard
9.5 KB
  • Display the source diff
  • Display the rich diff
Loading
Collapse file

‎design/twitter_icon.png‎

Copy file name to clipboard
7.63 KB
  • Display the source diff
  • Display the rich diff
Loading

0 commit comments

Comments
0 (0)
You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.