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

  • Home
  • SEARCH
  • 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 507293
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T06:47:21+00:00 2026-05-13T06:47:21+00:00

How do I show controls at a fixed position for various screen resolutions in

  • 0

How do I show controls at a fixed position for various screen resolutions in Android?

I have a screen design like below

<?xml version="1.0" encoding="utf-8"?>
<TableLayout
   xmlns:android="http://schemas.android.com/apk/res/android"
   android:gravity="center_horizontal"
   android:layout_width="fill_parent"
   android:layout_height="fill_parent"
   android:orientation="vertical"
   android:background="@drawable/img_background_loadbackground">
<TableRow>
<TextView
   android:id="@+id/tv1"
   android:layout_width="fill_parent" 
   android:layout_height="300sp"/>
</TableRow>

<TableRow>
</TableRow>
<ProgressBar 
   android:id="@+id/progressbar" 
   style="?android:attr/progressBarStyleHorizontal" 
   android:layout_width="fill_parent" 
   android:layout_height="wrap_content" />
</TableLayout>

It is working in HVGA(320×480) resolution, the progressbar appears at the bottom of the screen, but if I run in other resolution (WQVGA432 – 240×432) the progressbar appears in the middle of the screen. I am not able to show it in a fixed position.

I am using the manifest file show below but no output

<supports-screens android:smallScreens="true"  
                android:normalScreens="true" 
                android:largeScreens="true"  
                android:anyDensity="true" />

I don’t have a solution so please give me some idea to resolve the issue.

  • 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-13T06:47:22+00:00Added an answer on May 13, 2026 at 6:47 am

    If you want your layouts to work on different resolution screens your should be sizing them using dip as the unit. For example:

    android:layout_marginRight="10dip"
    

    dip stands for Device Independent Pixel and using these in your layout means that Android will automatically scale your layout depending on which display the device running your application has.

    You can read about these in the Supporting Multiple Screens page in the Android Developer Documentation. This document also has some other options for handling different displays but I think using dip is probably the easiest.

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

Sidebar

Related Questions

Below is my JavaProcess.mxml <?xml version=1.0 encoding=utf-8?> <s:WindowedApplication xmlns:fx=http://ns.adobe.com/mxml/2009 xmlns:s=library://ns.adobe.com/flex/spark xmlns:mx=library://ns.adobe.com/flex/mx minWidth=955 minHeight=600 creationComplete=windowedapplication1_creationCompleteHandler(event)>
I use the following function to show controls on my form: class procedure TFormMain.FadeControls(ctrl:Array
Have a gridview control which will show X amount of rows. I want to
I'm trying to display a QLabel (without parent) at a fixed position using PyQt.
I know that there are no fixed rules about software version control but I
I have a canvas with user controls arranged on it. When a tooltip is
I have a div I want to show and hide with a check box:
I have been trying to get this seemingly simple problem fixed for about half
I have a UserControl (XAML below) that has a ListBox that I want to
I have a question regarding the show event. in my application I'm handling the

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.