I have two stackViews with buttons in each one. At my chosen font size, they extend off the screen on smaller phones.
I want to reduce the font size of ALL buttons in BOTH stackViews and want all buttons to have the same font size. Is there a simple way to dynamically adjust the font size of all buttons in both stackViews so that they all fit properly and have the same font size?
I could hard-wire it by counting the characters in each title of the largest stack view then calculate the percentage of the view width and scale the font size for all of them but I am wondering if there is anything built-in.
("fillEqually" won't work because the button titles have different lengths so the buttons are different widths.)
Here is an example:
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.