kofigyan / StateProgressBar

Android library to realize the various states and transitions in a ProgressBar.
1.54k stars 233 forks source link

How to make is Right To Left (RTL)? #28

Closed Inzimam-Tariq closed 6 years ago

Inzimam-Tariq commented 6 years ago

I'm developing app in Arabic so I need it to to show step number from RTL like 4, 3, 2, 1 but currently its LTR like 1, 2, 3, 4. How can I do that?

kofigyan commented 6 years ago

I will work on this within the week and update you.

Inzimam-Tariq commented 6 years ago

Thanks

On Mon, Jan 29, 2018 at 3:04 PM, Kofi Gyan notifications@github.com wrote:

I will work on this within the week and update you.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/kofigyan/StateProgressBar/issues/28#issuecomment-361196792, or mute the thread https://github.com/notifications/unsubscribe-auth/AOcW4g60DuFCISxYoNlwSryGo2ZbXkcnks5tPZe3gaJpZM4RvJ4S .

kassemitani commented 6 years ago

any update on the Right to Left ? for arabic

kofigyan commented 6 years ago

@Inzimam-Tariq and @kassemitani is done. I am just preparing to upload it soon. See screenshots below :

screenshot_2018-03-12-15-08-43

screenshot_2018-03-12-15-08-25

kofigyan commented 6 years ago

Hi @Inzimam-Tariq and @kassemitani ,please can you look at the the implementation of the description of each state and confirm to me whether is consistent with Arabic style of writing.

String[] descriptionData = {"Details", "Status", "Photo", "Confirm" , "Done"}; @Override public void setContentView(int layoutResID) { super.setContentView(layoutResID); stateProgressBar.setStateDescriptionData(descriptionData); }

English(Ascending)

screenshot_2018-03-14-14-32-43

Arabic (Descending)

screenshot_2018-03-14-14-32-10

kassemitani commented 6 years ago

great job @kofigyan , is it possible to allow to add any drawable inside the circle shape?? Instead of numbers and checkmark.

kofigyan commented 6 years ago

Thanks @kassemitani for the feedback. I will look into the drawable inside the circle shape request and give you a feedback soon.

kofigyan commented 6 years ago

Hi @kassemitani , to clarify my question, what should be the proper Arabic representation of this code :

String[] descriptionData = {"Details", "Status", "Photo", "Confirm" , "Done"};

Please is it 1 or 2 ? :

  1. screenshot_2018-03-15-08-43-18 1

  2. screenshot_2018-03-15-08-38-50

kassemitani commented 6 years ago

2 is correct

kofigyan commented 6 years ago

Thank you @kassemitani for the feedback. I will finish with these features and quickly look into your feature(drawable inside the circle shape) request.

kassemitani commented 6 years ago

Thank you @kofigyan for your awesome work! Let us know when you going to commit changes.

kofigyan commented 6 years ago

Hi @kassemitani , l will make all the features available to the public most likely this week. This round of updates cover many of the feature requests from users. I am putting the finishing touches to it.

kofigyan commented 6 years ago

Hi @kassemitani and @Inzimam-Tariq the features are fully implemented now and available to the general public. How to use :

  1. Add to build.gradle implementation 'com.kofigyan.stateprogressbar:stateprogressbar:0.0.8'

  2. Add attribute in xml file app:spb_stateNumberIsDescending="true"

Eg. <com.kofigyan.stateprogressbar.StateProgressBar android:id="@+id/state_progress_bar" android:layout_width="wrap_content" android:layout_height="wrap_content" app:spb_currentStateNumber="three" app:spb_maxStateNumber="four" app:spb_stateNumberIsDescending="true" />

  1. Or add in java code

    stateProgressBar.setStateNumberIsDescending(true);

kofigyan commented 6 years ago

I will be working on full documentation tomorrow after l finish lecturing my students.

Inzimam-Tariq commented 6 years ago

Good to know You have fixed it, I will use it in my project. thanks

kofigyan commented 6 years ago

You are welcome @kassemitani .