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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T03:36:34+00:00 2026-06-10T03:36:34+00:00

I have RelativeLayout with RelativeLayout title bar: <RelativeLayout xmlns:android=http://schemas.android.com/apk/res/android android:layout_width=match_parent android:layout_height=wrap_content android:gravity=center_horizontal android:orientation=vertical >

  • 0

I have RelativeLayout with RelativeLayout title bar:

<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center_horizontal"
android:orientation="vertical" >

<RelativeLayout android:id="@+id/titleBar"
    style="@style/TitleBar"
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:layout_alignParentTop="true"
    android:layout_centerHorizontal="true">

<TextView
    android:id="@+id/caption"
    style="@style/WindowCaption"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_centerInParent="true"
    android:text="caption"/>

<Button
    android:id="@+id/buttonSave"
    style="@style/ButtonBar"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_alignParentRight="true"
    android:layout_centerVertical="true"
    android:layout_marginRight="5dp"
    android:onClick="save"
    android:text="Save" />

</RelativeLayout>
...
</RelativeLayout>

enter image description here

On a small screens the button gets on top of the text:

enter image description here

I want to resize text, or button to make all of them properly visible.
And I want the text was is on the centre.

Can I do it somehow using only style and layout tools?

Or the only way is to programmatically change the text size?

  • 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-10T03:36:35+00:00Added an answer on June 10, 2026 at 3:36 am
     <RelativeLayout
        android:id="@+id/te1"
        android:layout_width="fill_parent"
        android:layout_height="45dp" >
    
     <TextView
        android:id="@+id/TextViewCount"
        android:layout_width="fill_parent"
        android:layout_height="wrap_content"
        android:layout_alignBottom="@+id/ButtonCount"
        android:layout_alignParentLeft="true"
        android:layout_toLeftOf="@+id/ButtonCount"
        android:text="Countfdddgd "
        android:textSize="40dip" />
    
        <Button
            android:id="@+id/button1"
            style="@style/ButtonText"
            android:layout_alignParentRight="true"
            android:layout_marginTop="2dp"
            android:background="@drawable/greenbutton"   
            android:height="45dp"
            android:text="Accounts"
            android:width="100dp" />
    
    </RelativeLayout>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have layout structure: <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="fill_parent" android:orientation="vertical" > <com.google.ads.AdView android:layout_width="fill_parent" android:layout_height="wrap_content" ads:adSize="BANNER"
<?xml version=1.0 encoding=utf-8?> <RelativeLayout xmlns:android=http://schemas.android.com/apk/res/android android:layout_width=fill_parent android:layout_height=fill_parent> <LinearLayout android:id=@+id/li android:layout_alignParentTop=true android:layout_width=match_parent android:layout_height=50dip android:orientation=horizontal android:background=@drawable/title_bg>
Here is some xml for a row in a ListView: <RelativeLayout xmlns:android=http://schemas.android.com/apk/res/android android:layout_width=fill_parent android:layout_height=wrap_content
In my foo_layout.xml file I have a subclassed RelativeLayout: <?xml version=1.0 encoding=utf-8?> <FrameLayout xmlns:android=http://schemas.android.com/apk/res/android
I currently have an xml layout called quests.xml: <?xml version=1.0 encoding=utf-8?> <RelativeLayout xmlns:android=http://schemas.android.com/apk/res/android android:layout_width=fill_parent
I have a dialog with this content: <RelativeLayout android:layout_width=wrap_content android:layout_height=wrap_content > <ScrollView android:layout_width=fill_parent android:layout_height=wrap_content
I have a RelativeLayout with a few TextView as children <RelativeLayout android:id=@+id/shift_parent_name android:layout_width=fill_parent android:layout_weight=0.25
I have a custom Title Bar so I want that when the user types
I create the custom title using the style.I code some from http://labs.makemachine.net/2010/03/custom-android-window-title/ I have
I have a problem about the title bar. I want to do 2 buttons

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.