Why are there spaces on the left and right hand side of my seekbar?

Anshuman Pattnaik

I am working on Seekbar and i have found one issue. A default space is present on the left and right hand side. I need the seekbar to be full width. I did match_parent and fill_parent but that didn't work.

enter image description here

<?xml version="1.0" encoding="utf-8"?>

 <RelativeLayout 
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="match_parent">

   <SeekBar
      android:id="@+id/seek_bar_controller"
      android:layout_width="match_parent"
      android:layout_height="wrap_content"
      android:padding="0dp" />
 </RelativeLayout>

You can follow this snapshot for the reference, on both left and right hand sides space is present.

Please kindly go through my post and suggest some solution.

Amit Vaghela

To remove that you need to use android:thumbOffset="20dp",

try below code :

<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="match_parent">

    <SeekBar
        android:id="@+id/seek_bar_controller"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:thumbOffset="20dp" />
</RelativeLayout>

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

Why is my Stack clipping the right-hand side of images?

How to pad char array with empty spaces on left and right hand side of the text

Why does my cube bounce at the left side but not at the right side?

Should null be checked on the left or right hand side

How to add an unbroken line in bash starting from end of my left hand PS1 text to the right hand side

Why is this an invalid assignment left hand side? - 2.0

Why is this an invalid assignment left hand side?

Why is my drawing on the right side of the canvas changing the pixels at the left side of my canvas?

Why does my right hand flex column suddenly drop below a left column?

How to create operator*(double) for multiplying on both the left and right hand side?

Different slicing behaviors on left/right hand side of assignment operator

Can the chrome dev tools be on the left hand side rather then the right?

Generalized makefile rules with multiple variables on both left and right hand side

BCE0051: Operator '<' cannot be used with a left hand side of type 'Object' and a right hand side of type 'float'

Hibernate Many-to-many association: left hand side collection contains elements, but right hand side collection is empty

Left Hand Side , Right Hand Side Compiler Errors in Dart / Flutter List

Is there a way to refer to the left hand side of an expression in the right hand side? i.e. after the =

I want to write from right hand side to left hand side in textview

The left -hand and right hand side of an arithmetic operation must be of type 'any', 'number' or an enum type

Can't get my sidebar on the right-hand side

Why Diamond operator was not missed from Right hand side in Java 7?

Why >> duplicates right-hand side operand in haskell

Why can't the left hand side of an assignment be an increment expression?

*why* does list assignment flatten its left hand side?

Why I get "Invalid left-hand side in assignment"?

Is there a keyboard shortcut to switch between the left-hand side and right-hand side of a diff/compare-two-files editor?

Bitwise binary operator for BYTES requires equal length of the inputs. Got 16 bytes on the left hand side and 4 bytes on the right hand side

How to get a list of all drools variables defined in condition / left hand side from inside the consequence / right hand side?

How to use substr from right hand side to left hand side? How to convert each 8 characters from a string to an int?