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

[Android]IndexOutOfBounds when using DashPattern #125

Closed
BaseCrusher opened this issue Aug 18, 2020 · 10 comments
Closed

[Android]IndexOutOfBounds when using DashPattern #125

BaseCrusher opened this issue Aug 18, 2020 · 10 comments
Labels
bug Something isn't working

Comments

@BaseCrusher
Copy link

When you set the BorderMarkup DashPattern to anythink other then 0 when using Android a Java.Lang.ArrayIndexOutOfBoundsException is thrown.

@sthewissen
Copy link
Owner

DashPattern is meant to be set to at least two values, seperated by a comma.

e.g. "10,4" would mean that the dash is 10 units wide and the space in between them is 4 units wide.

Setting it to a single value will indeed throw an error (because it won't work with a single value anyway), which I'm adding a check for.

sthewissen added a commit that referenced this issue Aug 19, 2020
@BaseCrusher
Copy link
Author

Ahh all right. Thank you very much fpr the quick reply. :)

@BaseCrusher
Copy link
Author

As a small edit. I would suggest setting the DashPattern with only one number would result that the dash length and the spacing are the value set in the DashPattern. On iOS this seams to work already.

@sthewissen
Copy link
Owner

That's probably a platform-specific perk of how iOS implements that then. I can take a peek at implementing a check for that on Droid.

@sthewissen sthewissen added the bug Something isn't working label Aug 21, 2020
@sthewissen
Copy link
Owner

This should be fixed in the current beta if you want to verify.

@BaseCrusher
Copy link
Author

BaseCrusher commented Sep 3, 2020

So I've taken a look it works just fine now. 👍
If you'd like I can create a quick pull request for the documentations, so that users know that they can set the dash gap aswell if they'd like to.
Only one thing that seamed a litle of, though it doesn't bug me, when I was using the Android version the dash gap was very small. I don't know why. Just wanted to let you know.

PS: Thank you very much for the great work. If there is any way to support you a litle without using GitHub Sponsors let me know. Sadly im not in the position right now to do monthly sponsoring.

@sthewissen
Copy link
Owner

@BaseCrusher Thanks for the kind words, appreciate it. I'll happily take a docs PR :) I didn't even know that was possible for Wiki, so you learn something new every day. There is definitely a visual difference between Android and iOS for the dashes, but I haven't found the magic formula that makes the look in sync yet.

Regarding sponsoring, I don't quite know what people typically set up for that. I have the GH sponsors thing here, I have a Twitch stream where I guess one can throw bits at me. Other than that I don't know what people use these days. If you have suggestions I'll gladly take em.

@sthewissen
Copy link
Owner

Closing this since the original problem was solved.

@BaseCrusher
Copy link
Author

BaseCrusher commented Sep 15, 2020

@sthewissen I realized that I'm not able to do PR's to the wiki. So Im posting it here.

##Using Dash Pattern
The dash pattern takes two arguements. The first one is for the dash length and the second one for the dash gap. Setting only the first parameter results in the dash length and the dash gap to have the same value.

eg.: `DashPattern='4,8'`

@sthewissen
Copy link
Owner

Thanks, I'll add a paragraph for it!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants