-
Notifications
You must be signed in to change notification settings - Fork 13
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
support for both orientation. #2
Comments
Thanks for your request. Xdimen scales the dimensions depending on the devices' width regardless of the orientation.
here when the first device is in landscape mode its width is 600dp, and when the second is in the portrait mode its width is also 600dp, and for both, we need the same scaled dimension. I categorized the predefined devices' widths into some sets regarding their type and orientation, you can combine more ones like this Kotlin xdimen {
targetDevicesWidth.set(phonePortrait + phoneLandscape)
....
} Groovy xdimen {
targetDevicesWidth = phonePortrait + phoneLandscape
....
} and this will generate scaled dimensions for all devices' widths in I hope this comment helps you, and hope to hear from you if things are not clear enough yet. |
What about it? Is my answer helped you? |
I'll close this issue, If my answer not helped you feel free to comment on it and I'll reopen |
I want to set dimen for both orientation. how should I do it?
for eg. values-w483dp and values-w483dp-port automatically generated and the dimen values set to specific orientation.
The text was updated successfully, but these errors were encountered: