Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 5978345
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T21:30:08+00:00 2026-05-22T21:30:08+00:00

I have over 50 XML Layouts/pages and need a way to determine a base

  • 0

I have over 50 XML Layouts/pages and need a way to determine a “base” font size for each screen type (small/medium/large). Actually, I need to specify other things, such as sizes for linear layouts.

In short, I want to differentiate sizes between small/medium/large devices.

1) Would I programmatically change the text size in styles.xml during launch?

This option is convenient because I wouldn’t have to make 150+ XML Layouts.

2) Would I create three separate XML Layout’s for the three sizes?

I would have to copy+paste each Style (*.small, *.med, *.large)… this sound like it will take a lot of work.

Any comments?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-22T21:30:09+00:00Added an answer on May 22, 2026 at 9:30 pm

    I’m assuming that you know that you should use scalable units as stated in Vinay’s answer:

    http://developer.android.com/guide/practices/screens_support.html

    I strongly recommend not to deviate from the “best practices” unless you really know what you’re doing. It can only bring you problems down the road. I’m not a pro, that’s why I try to follow the standards. OK, now let’s answer:

    When you want to use different sizes, and scalable units are not enough, you must declare them somewhere. So you are going to declare different files no matter what… it’s inevitable. But then again, only when your scalable units are not enough to provide the desired visual effect across different screens.

    To do that, you declare in value folders. Did you see the Google I/O app source on Google Code? It’s “Google”, and they do it very well. If you want to learn by example, that’s probably the most complete resource I can think of. But it’s a bit frightful at first.

    It’s so much to tell here (many simple questions… looks like you really don’t know your way, sorry if it’s not the case) that you are probably better off downloading that source tree.

    Of course, both the values and layouts folders work in a transparent fashion (that’s the whole point of using the standards), so you don’t need to worry about screen variations across your layouts (when addressing key-values styles) and/or at runtime (when addressing both style and layout).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

does Delphi 2010 have C# Style XML comments that show up when hovering over
I have various XML layouts. In all of those layouts I have buttons, but
I have a tiles-defs.xml that has these definitions... <definition name=masterLayout path=/WEB-INF/tiles-layouts/globalLayout.jsp> <put name=pageTemplate value=over-ride
I have over 1000 clients and I developed a simple PHP script to loop
We have over 1000 unit tests. A while ago 18 of them started to
We all know the effects that lots of thrown exceptions can have over the
If I'm building an application that will have over 30 models, and I want
im planning to create a movie file that might have over 16,000 frames?i know
I'm sure it's something simple, but I have over 100 errors like: and: I
I have taken over a project that was build from suggestions in this Dan

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.