Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature] set gradient color for bar chart #3759

Closed
wants to merge 1 commit into from

Conversation

oatrice
Copy link
Contributor

@oatrice oatrice commented Jan 26, 2018

-set gradient color for bar chart
-Add javadoc for getter/setter method
-add kotlin

How to use.

int startColor = ContextCompat.getColor(this, android.R.color.black);
int endColor = ContextCompat.getColor(this, android.R.color.white);
set1.setGradientColor(startColor, endColor);

@VyMajoris
Copy link

Can we have this, please?

@oatrice
Copy link
Contributor Author

oatrice commented Mar 23, 2018

@VyMajoris U can use this feature by add dependency of my fork this repository.

  • Add the following to your project level build.gradle:
allprojects {
	repositories {
		maven { url "https://jitpack.io" }
	}
}
  • Add this to your app build.gradle:
dependencies {
	implementation 'com.github.oatrice:MPAndroidChart:3.0.4'
}

@VyMajoris
Copy link

@oatrice Nice, thank you.

@almic almic added the enhancement improves upon existing functionality label May 1, 2018
@almic
Copy link
Contributor

almic commented May 3, 2018

Adding support for gradients is definitely on the to-do list, however this pull request has way too many extra changes. If you could please create a new pull request, preferably with only ONE commit, that only adds the ability to set a second color for bar chart entries, which the renderer then uses that second color to draw a gradient on the bar. I will gladly merge it!

@oatrice
Copy link
Contributor Author

oatrice commented May 3, 2018

@almic Thank you for your comment. I create a new pull request again at this #4001 (Solved issue #2444 as well)

@oatrice oatrice closed this May 6, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement improves upon existing functionality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants