Open nmock opened 9 years ago
I'm currently working on a few text alignment issues that may or may not address this.
What is wrong with the current implementation?
What resolution would you prefer?
@dmiedema I'm simply trying to center a piece of text and activity indicator/image. The expected behavior is that if setting both to alignment center, the text would appear exactly centered and the alignment of the activity indicator/image would be compensated by floating to the left of the text.
As you can see in the screenshot, the current implementation will just naively center both elements.
Cool cool. Seems reasonable enough. The only reason it doesn't do anything like that now is I attempted to make as few assumptions as possible in regards to alignment/shifting things away from where they were requested.
If you have any current work arounds/changes to accomplish that I'm sure others would appreciate it and/or PRs are always welcome.
It might make sense to add a new boolean value, "isRelativeToText." If it's set to true, the activity indicator/image will be on the left or right sides of the text instead of the toast view.
How would we determine right or left side? current locale?
It would still use the usual alignment keys, they'd just be relative to the text.
Issue https://github.com/cruffenach/CRToast/issues/131 was not fixed with the pull request, see screenshot from latest demo.