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 8223453
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T14:42:17+00:00 2026-06-07T14:42:17+00:00

I set an image for each tab and result is as expected but on

  • 0

I set an image for each tab and result is as expected but on some devices (tablets or some smartphone models) image is seen bigger and above text. How to solve it? Thank you.

activity,

        StateListDrawable selector = new StateListDrawable();

        selector.addState(new int[] { android.R.attr.state_selected }, dSel);

        icon.setImageDrawable(selector);

layout,

<TabHost 
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:id="@android:id/tabhost" 
    android:layout_width="fill_parent"
    android:layout_height="fill_parent">

      <RelativeLayout       
    android:layout_width="fill_parent"
    android:layout_height="fill_parent">


        <LinearLayout  
            android:orientation="vertical"
            android:layout_width="fill_parent" 
            android:layout_height="fill_parent"
            android:layout_below="@+id/mainLayout">

            <FrameLayout 
                android:id="@android:id/tabcontent"
                android:layout_width="fill_parent" 
                android:layout_height="0dip"
                android:layout_weight="1" 
                android:scrollbars="none"
                android:isScrollContainer="false">
            </FrameLayout>

            <TabWidget 
                android:id="@android:id/tabs"
                android:layout_width="fill_parent" 
                android:layout_height="wrap_content"
                android:layout_weight="0"
                />

        </LinearLayout>         

    </RelativeLayout>

enter image description hereenter image description here

  • 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-06-07T14:42:21+00:00Added an answer on June 7, 2026 at 2:42 pm

    I believe these links would guide you properly to solve your problem.

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

    http://coding.smashingmagazine.com/2011/06/30/designing-for-android/

    http://www.coronalabs.com/blog/2011/01/27/dynamic-image-resolution-made-easy/

    Plus, this question raises a problem similar to yours I believe.

    Determining image sizes for multiple android screen sizes/densities

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

Sidebar

Related Questions

I have a set of jpeg images where each image has an associated description.
How to set background image of UITabelViewCell? I want to set image of each
I want to set a different image for each cell of my table view.
I'm trying to set image for my UIBarButtonItem and I can't manage to do
i need to set image as background in android gridview. I have code which
I am using client bundle in gwt.Using client bundle set image on label,open pdf
I want to set an image as my background at runtime, so I created
How can i set an image to a circular slider, which is an object
How to set max image size and weight/height using Dragonfly? Max size will be
I want to set background image to right and top of my span because

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.