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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T02:06:21+00:00 2026-06-15T02:06:21+00:00

Here I have EditText and ImageButton : <LinearLayout android:layout_width=match_parent android:layout_height=wrap_content android:id=@+id/layout1 android:weightSum=1.0> <EditText android:id=@+id/searchBox

  • 0

Here I have EditText and ImageButton:

<LinearLayout
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:id="@+id/layout1"
    android:weightSum="1.0">

    <EditText
        android:id="@+id/searchBox"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:hint="@string/search"
        android:layout_weight=".86"
        android:textStyle="italic|normal"
        android:typeface="normal"
        android:singleLine="true"
        android:ellipsize="end" />

    <ImageButton
        android:layout_height="match_parent"
        android:layout_width="0px"
        android:layout_weight=".14"
        android:background="@drawable/search_button_selector"/>

</LinearLayout>

Everything seems to be OK, unless I start typing text in EditText.

At the beginning it looks like this:

enter image description here

And after typing text, my ImageButton gets smaller:

enter image description here

How to make EditText stand still?

  • 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-15T02:06:22+00:00Added an answer on June 15, 2026 at 2:06 am

    I believe changing the EditText’s layout_width to android:layout_width="0dp" will fix it. This will allow the LinearLayout to control the width to fill the space dictated by your weights.

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

Sidebar

Related Questions

I have a EditText view, <EditText android:layout_weight=1 android:id=@+id/etMiktar android:layout_width=0dp android:layout_height=wrap_content android:hint=@string/miktarHint android:focusable=false> </EditText> And
Let's say in a LinearLayout we have two EditText. Android system is somehow able
I have a EditText in a layout with a white background. On Android 2.x,
I have a LinearLayout class in which I have: TexView | ImageView | EditText
In the Linearlayout I have four Edittext Fields.When virtual Keyboard is opened I can't
I have set EditText in xml file as android:gravity=top and android:inputType=textMultiLine with some text
just a simple question here. I have a edittext inside a scrollview. Here is
I have 2 edittext fields where it needs the item name (String) and the
I have an EditText field in my layout, with the android:inputType=number . The thing
I have an EditText which should work as follows (Android 2.3.3): The user enters

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.