Thanks for your comment. There is a reason for that. Google's com.google.android.gms.common.SignInButton button also doesn't provide any attribute called android:textSize. This is because they don't want you to change the size of the text based on their design guidelines.
If you check their branding guidelines here: developers.google.com/identity/bra..., they mention that "You can scale the button as needed for different devices and screen sizes, but you must preserve the aspect ratio so that the Google logo is not stretched". i.e You can use android:scaleX and android:scaleY attributes with in order to scale the button. This maintains the aspect ratio as well.
If you see the padding section on the same page, it shows an image which shows a static font size of 14sp as shown below:
i.e
That's why in the library also I've just used the suggested size in order to standardize it based on guidelines and don't consider the textSize even if it is set on the custom button. If adding scaling still doesn't solve what you are looking for, please feel free to open a pull request or an issue on the Github repository .
Thanks!
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Hi Karan
Thanks for your comment. There is a reason for that. Google's
com.google.android.gms.common.SignInButton
button also doesn't provide any attribute calledandroid:textSize
. This is because they don't want you to change the size of the text based on their design guidelines.If you check their branding guidelines here: developers.google.com/identity/bra..., they mention that "You can scale the button as needed for different devices and screen sizes, but you must preserve the aspect ratio so that the Google logo is not stretched". i.e You can use
android:scaleX
andandroid:scaleY
attributes with in order to scale the button. This maintains the aspect ratio as well.If you see the
padding
section on the same page, it shows an image which shows a static font size of 14sp as shown below:i.e
That's why in the library also I've just used the suggested size in order to standardize it based on guidelines and don't consider the
textSize
even if it is set on the custom button. If adding scaling still doesn't solve what you are looking for, please feel free to open a pull request or an issue on the Github repository .Thanks!