Office Hours — Today, March 3

Friday, February 21

Mar 3
3:55 PM
Mark M.
has entered the room
Mark M.
turned on guest access
4:00 PM
Ron B.
has entered the room
Mark M.
hello, Ron!
how can I help you today?
Ron B.
Hi Mark!
I need my app to override the user setting for font size. I always want to use the default device size.
Mark M.
then don't use sp units
1 sp = 1 dp at the default font size
note that users may not appreciate your choice, though
Ron B.
OK, I'll give it a try. Users won't appreciate it if I don't, I'm lining up text against a fixed image.
Mark M.
then you have bigger problems
the font size is not the same on all Android devices
4:05 PM
Mark M.
heck, the *font* is not the same on all Android devices
Ron B.
Do you have any recommendations on how to approach this? It doesn't need to be exact, but small on one can't be medium on another.
Mark M.
um, why not allow for word-wrap?
I mean, you can force it to fit via AutoSizeTextView (https://github.com/danclarke/AutoResizeTextView)
but you may wind up with unreadable text on some screen sizes and prose combinations
usually, you try to let the text be the size it needs to be, to match the user's desired font scale and whatever your text is, using scrolling if need be
4:10 PM
Ron B.
Thanks, I'll look into it further!
Mark M.
if you have another question, go right ahead
Ron B.
No, I'm all set for now.
4:45 PM
Ron B.
Signing out. Have a great evening.
Mark M.
you too!
Ron B.
has left the room
5:00 PM
Mark M.
turned off guest access

Friday, February 21

 

Office Hours

People in this transcript

  • Mark Murphy
  • Ron Bruckman