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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T16:08:44+00:00 2026-05-25T16:08:44+00:00

a designer made some design for my Android app, here is a design for

  • 0

a designer made some design for my Android app, here is a design for a ListView (not the real one but the same idea..):
enter image description here

So in the middle of the green area there is some text, and in the orange area an imageview (clickable..), and in the middle of the blue area another text.. this is 1 listview.. so if you swipe one row the other also swipe the same.. (they arent 3 listviews..) The yellow area is empty

How do I align the views so it works on all screen sizes? How can I center the text in the green and blue area?
Thanks

Here is the xml of the row I used:

<?xml version="1.0" encoding="utf-8"?>
 <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent" android:orientation="horizontal"
android:layout_height="wrap_content" android:paddingLeft="40dip"
android:paddingRight="40dip">
<TextView android:id="@+id/Start_Numbering" android:textSize="19.5sp"
    android:layout_width="fill_parent" android:layout_height="wrap_content"
    android:layout_weight="0.3" 
    />

<ImageView android:id="@+id/Start_ImageView"
    android:layout_weight="0.1" android:layout_height="wrap_content"
    android:layout_width="fill_parent"        android:src="@drawable/list_noaudioavailable"
    ></ImageView>


<TextView android:id="@+id/Start_Name" android:textColor="#a7e9fe"
    android:textSize="21dip" android:layout_width="fill_parent"
    android:layout_weight="0.6"
    android:layout_height="wrap_content" />

Here is getView:

 @Override
public View getView(int position, View convertView, ViewGroup parent) {
    ViewHolder     holder;

    if(convertView == null) {
        convertView = mInflater.inflate(R.layout.start_row, null); //line 47
        holder=new ViewHolder();

        holder.tv_Name   =(TextView)convertView.findViewById(R.id.Start_Name);
        holder.tv_PageNumber = (TextView)convertView.findViewById(R.id.Start_Numbering);
        holder.im_Audio=(ImageView)convertView.findViewById(R.id.Start_ImageView);
        convertView.setTag(holder);
    } else {
        holder  = (ViewHolder) convertView.getTag();
    }

    holder.tv_Name.setText(Names[position]);
    holder.tv_PageNumber.setText(Integer.toString(PageNumber[position]));
    return convertView;
}

class ViewHolder {
    TextView       tv_Name;
    TextView       tv_PageNumber;
    ImageView      im_Audio;
}

But all I get is this, why the tv_Name isnt being display?: enter 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-05-25T16:08:45+00:00Added an answer on May 25, 2026 at 4:08 pm

    Omar, your questions wasn’t crystal clear, but I will give it a shot.

    You use

    In your row.xml, you would use

    1. LinearLayout as the parent with orientation as horizontal
    2. It will have five child elements

      • a. Yellow View with layout_weight=2
      • b. Blue TextField with layout_weight=5
      • c. Orange ImageField with layout_weight=3
      • d.
        Green TextField with layout_weight=4
      • e. Yellow View with
        layout_weight=1

    For centering the text use appropriate text align property. All of these elements should have layout_width defined as fill_parent.

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

Sidebar

Related Questions

My designer handed me a design I'm not 100% sure how to do with
So our designer made some changes to some images, and committed the changes. So
I have an array of values being made available, but unfortunately some of the
I made a simple change in Designer.cs which is this.dateTimePicker.MaxDate = DateTime.Now; but whenever
I got some graphic design that was made using JavaScript / Html5 Canvas. Take
In the Visual Studio designer, how do you move a menu item from one
I noticed that my Designer.vb file of one of my forms has a lot
EDITED FOR BETTER UNDERSTANDING I made a custom control with propertise for some global
First off, it may seem that I'm asking for subjective opinions, but that's not
I've built some shopping cart systems in the past, but I always designed them

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.