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

added support for progress markers #30

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Aggelos88
Copy link

Hello! I added markers functionality to your project (as requested in " Creating a marker at discrete progress #25"). Markers can have two states, empty if the progress of the SeekArc has not yet reached the marker value or fill otherwise. Also, markers can have a label which is drawn outside of the SeecArc circle. Finally, markers can have (optionally) a click listener.

New xml attributes introduced (with getters/setters in SeekArc class):

  • markerEmpty (type: drawable) : The drawable of the empty state marker.
  • markerFill (type: drawable) : The drawable of the fill state marker.
  • markerTextEmptyColor (type: color) : The label color of the empty state marker.
  • markerTextFillColor (type: color) : The label color of the fill state marker.
  • markerTextSize (type: dimension) : The label text size of the marker.
  • markerTextRadius (type: dimension) : The radius of the circle from the label text center to the point adjusted to the SeekArc circle. The longer the value, the longer the distance from the marker.

To add a marker you need to call method addMarker(String label, int value, int textOffsetX, int textOffsetY, OnMarkerClickListener onMarkerClickListener)

where:

  • label : The label of the marker. If not provided (null), the parameter value will be shown as label
  • value : The progress value of the marker
  • textOffsetX : The X offset of the label
  • textOffsetY : The Y offset of the label
  • onMarkerClickListener :The listener that corresponds to the click events of the marker. It can be null.

I have updated your example with a use case. If you find it usefull please merge, or else just ignore. Thanks!

@RoadXY
Copy link

RoadXY commented Feb 11, 2016

Thanks for you PR, pulled it to my own fork.
Thanks!

@theblitz
Copy link

Is this update merged?
If not, is there a timetable?
Kinda urgent for me. :)

I'd rather not download the source code for direct inclusion.

@RoadXY
Copy link

RoadXY commented Feb 24, 2016

I already did since there are important fixes which would be included in V2 but have been sitting there since a month or 2.
And there are PR standing here since januari 2015 :-S

@theblitz
Copy link

I tried to find the updates in the 1.1 version on gradle but they don't seem to be there.

@RoadXY
Copy link

RoadXY commented Feb 24, 2016

No, Gradle hasn't been updated since a long time.

@theblitz
Copy link

Are there any plans?
At the moment I downloaded the zip file - but not ideal.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants