Commit graph

717 commits

Author SHA1 Message Date
Daniel Cohen Gindi
c0e7f56b5d Implement a more generic Fill class instead of GradientColor
Support HorizontalBarChart too.
2020-01-24 12:52:27 +02:00
Daniel Cohen Gindi
351e341ee7 Fixed merge residue 2020-01-24 11:42:03 +02:00
Daniel Cohen Gindi
45240c3723 Improved negative offset for horz bar chart
https://github.com/danielgindi/Charts/pull/3854
2020-01-22 16:01:42 +02:00
Daniel Cohen Gindi
e02e9be2fa Multiple colors for valueline
https://github.com/danielgindi/Charts/pull/3709
2020-01-22 14:13:31 +02:00
Philipp Jahoda
0c2ac2d9cc New example app release 2019-03-16 11:53:42 +01:00
Philipp Jahoda
2058f7bf5d Minor changes to project and example 2019-03-16 11:42:04 +01:00
almic
aea2ff3417
Add option to set minimum angles
Allows to force minimum slice angles when drawing charts, which means that any
slices with angles lower than the minimum will be drawn with the minimum angle.

When changing this setting on the fly, you have to call
`notifyDataSetChanged()` and `invalidate()` for the minimum angle to take
effect.

This only functions if all slices can be drawn with the minimum angle. For
example if a chart has 5 slices, the largest functioning minimum angle is
`72f` degrees on a 360 degree chart, or 20% of the chart's `maxAngle`.
2018-11-15 09:51:46 -07:00
almic
42cdba535f
Add Curved Slices to Pie Chart
Finally added support for rounded slices, and somewhat improved the code
for the PieChartRenderer class.
2018-11-12 10:59:48 -07:00
almic
e5b66192e7
New ValueFormatter
I created a simplified value formatter class, which is an abstract class rather
than an interface.

The switch was chosen because the new format has all the methods predefined
(something an interface wouldn't allow) meaning you can extend it and only
change what you want. This also means that you only need one value formatting
class for labels rather than two different classes, it just makes more sense.

Please check the method signatures to learn how to use them, I'm sure you'll
find this new format is much more customizable and faster to use.

I've made the class abstract even though there are no abstract methods or
fields, this is because it would certainly be a mistake to create a
ValueFormatter and not override any methods.

To convert existing code, just use 'extends' instead of 'implements' and change
the names to 'ValueFormatter'. You'll need to change the methods you overwrite
as well, just check the class and use the one you need.
2018-11-07 12:41:53 -07:00
almic
9148f37f9e
Bump version to 3.1.0-alpha 2018-10-29 13:23:18 -06:00
almic
5030b36c86
More Cleanup
I've removed the realm examples, mainly because the library was buggy.
In the previous commit, I already removed the examples from the list
since they didn't add anything to the overall demonstration. I thought
that if anyone wants to use realm.io with the charts, they can see the
actual library.

The file structure has been updated to match how Android Studio does
things. Some files added way back when have been deleted as they don't
do anything but cause the linter to freak out about 'unused properties'

All 'build.gradle' files have been refreshed as well.

Small addition to the README file to add a quick way to reach sections
of the page.
2018-10-27 18:00:06 -06:00
almic
db7dda2b7e
More Linting
Lots of things in the example app are now marked with the 'final' modifier, and saveToGallery() is protected in classes that implement it. As well, new suppressions are in a few places.

NEW text is now removed completely. Looks like this has been unused for a long time and it's just stuck around anyway.
2018-10-27 14:02:04 -06:00
almic
d67ea481af
Huge Project Refresh
Before anyone freaks out, all these changes are under-the-hood, meaning that you probably won't even notice them at all.

The biggest difference is raising the minSdkVersion from 9 to 14. Recently android bumped this number interally as there are basically no devices running lower than 14 anymore. Sorry but you are just wasting your time if you are trying to support anything lower than 14 now.

The next biggest change is updating the project to the new AndroidX libraries, which changes some imports and nothing else really.

The third biggest change is fixing a few bugs in the code that cause values to be drawn even if there are none, which results in your app crashing. Surprisingly, these checks already existed in a few of the newer chart types, but most lacked this simple check.

Other than those three changes, nothing else is functionally different. Well, saving to gallery works on all charts in the example app now, and you can quickly see the code for each example in the menus.

The only real potential "breaking" change is that charts are now saved as PNGs by default instead of JPGs if you go the route of not specifying as a JPG. You may want to double check your file sizes as PNGs can be larger than low quality JPGs.

I still have more plans for simplifying the API and fixing other issues with the project, for the small few that closely pay attention to individual commits: there's going to be more soon.
2018-10-26 10:30:22 -06:00
RobertZagorski
75dd04cc42 Remove redundant findViewById casts, that became obsolete after migration to API 26. 2018-05-10 08:01:03 +02:00
RobertZagorski
7abc9cd669 Update and reorganise copy data sets methods (Fix for #1604).
Copying class properties is always done in protected copy method.
2018-05-08 16:19:09 +02:00
Mick A
c08ec81fc0
Merge pull request #4001 from oatrice/feature/muti_gradient
[Feature] Multiple gradient color for barchart
2018-05-05 09:18:14 -06:00
Anirut Teerabut
e4ba3cdc20 - multiple gradient color 2018-05-04 04:21:26 +07:00
almic
689d484615
Delete lingering MyEasingFunction.java
I made the decision to remove this file instead of updating it, as I'm
sure most will instead prefer to look at the actual Easing class. If you
miss this example class... ¯\_(ツ)_/¯
2018-05-03 08:37:00 -06:00
almic
35c9fc937e
refactor(EasingFunction): Simplified EasingFunction
EasingFunction has been simplified greatly, and I've added a MUCH needed
annotation to relevant methods.

Easing.EasingOptions has been deprecated, as well as any methods using
them. Converting is as simple as deleting the "EasingOptions" part.

A new signature is available for animateXY()!

You are now able to pass one EasingFunction to animateXY() if you want
both axes to be animated the same way.

Quietly included are some gradle build updates, incrementing the
appcompat version to 27.1.1, and using the new `javacompiler` to avoid
deprecation of `javacompile`
2018-04-30 12:24:18 -06:00
Mick A
9997a33524
Merge pull request #3975 from hannesa2/AndroidStudio3.1.2
update to Android Studio 3.1.2
2018-04-28 19:12:26 -06:00
Hannes Achleitner
d8ea67aa21 update to Android Studio 3.1.2 2018-04-28 19:54:22 +02:00
Mick A
40adb57f68
Merge pull request #3898 from sembozdemir/pie_chart_value_line_colors
PieChart: Add option for using slice color as value line color
2018-04-28 10:53:08 -06:00
Wilder Pereira
993a8554c0 Remove unused imports 2018-04-15 21:51:35 -03:00
Wilder Pereira
508cc565a9 Rename RadarChartActivitry to RadarChartActivity 2018-04-15 21:51:15 -03:00
sembozdemir
1e6e58d2c0 Add option for using slice color as value line color
Fixes: #3897
2018-03-28 20:23:51 +03:00
Philipp Jahoda
16a9be8ea0 Update gitignore, add assets 2017-12-14 19:37:09 +01:00
Philipp Jahoda
5e97f561f7 Update version 2017-11-29 16:06:58 +01:00
Philipp Jahoda
0868d9bf89 Add new google repo 2017-11-29 15:57:30 +01:00
Philipp Jahoda
23aef1a0ab Add new google repo 2017-11-29 15:55:18 +01:00
Philipp Jahoda
dfaffa39cc Add maven plugin to example 2017-11-29 15:48:42 +01:00
Philipp Jahoda
f2dedb30de Update gradle and dependencies 2017-11-29 15:23:57 +01:00
PhilJay
b564704b82 Updating versions 2017-03-23 16:13:21 +01:00
Daniel Cohen Gindi
493e3d238d Merge pull request #2463 from maheshgaya/master
Fix: typo for October
2017-02-21 16:39:50 +02:00
Daniel Cohen Gindi
94957fad33 Improved feb29 formula 2017-02-20 13:55:16 +02:00
Daniel Cohen Gindi
144af7b295 Added examples for icon entries 2017-02-20 13:33:53 +02:00
Daniel Cohen Gindi
a934501315 Gradle updates 2016-12-19 21:56:16 +02:00
PhilJay
08f295eae1 Upgrade manifest 2016-11-17 19:01:53 +01:00
PhilJay
a7fd778fc8 Upgrade version 2016-11-17 19:01:21 +01:00
Daniel Cohen Gindi
4cb83a7b91 Added IndexAxisValueFormatter, to allow for easy x-axis labels like MPAndroidChart 2.0 2016-11-16 11:19:50 +02:00
Daniel Cohen Gindi
ee020bba67 Gradle updates 2016-11-16 11:01:34 +02:00
Mahesh Gaya
262d877b9f Fix: typo for October 2016-11-12 12:23:36 -06:00
PhilJay
9a19bf6670 Migrate to Realm v2.0.2, fix example 2016-10-23 00:02:49 +02:00
PhilJay
9b7cffa274 Move to Realm v2.0.2, update example 2016-10-22 23:54:31 +02:00
PhilJay
0fec2ef06b Clear up grouped bar example 2016-10-18 22:40:45 +02:00
Daniel Cohen Gindi
d65ffb8871 Fixed bar chart demo first value being empty 2016-10-18 18:39:04 +03:00
PhilJay
8ed6dd24bf Update gradle & android sdk 2016-10-16 19:09:42 +02:00
Daniel Cohen Gindi
e10628958f Improved highlight for scatter/bubble, and fixes highlightValueWithX 2016-10-10 16:33:43 +03:00
Daniel Cohen Gindi
8d65596266 Default spaceMin/spaceMax for bar charts
This avoids having to set custom axisMinimum/axisMaximum, or offsetting x
2016-10-08 22:25:44 +03:00
PhilJay
3398cf4462 Refactoring, prepare example for testing highlight 2016-10-02 15:14:09 +02:00
PhilJay
01d8b24686 Update gradle 2016-09-24 18:21:50 +02:00