Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

REditText paddingTop问题 #127

Open
baowenqing opened this issue Mar 28, 2024 · 0 comments
Open

REditText paddingTop问题 #127

baowenqing opened this issue Mar 28, 2024 · 0 comments

Comments

@baowenqing
Copy link


        <android.support.v7.widget.LinearLayoutCompat
            android:layout_width="match_parent"
            android:background="#ff0"
            android:gravity="center_vertical"
            android:layout_height="50dp">


            <EditText
                android:layout_width="110dp"
                android:layout_height="25dp"
                android:gravity="center_vertical|start"
                android:paddingStart="10dp"
                android:paddingEnd="10dp"
                android:textSize="11sp"
                android:background="#f06"
                app:corner_radius="12dp"
                app:text_color_normal="#333"
                android:text="哈哈" />


            <com.ruffian.library.widget.REditText
                android:id="@+id/et_name"
                android:layout_width="110dp"
                android:layout_height="25dp"
                android:layout_marginLeft="20dp"

                android:gravity="center_vertical|start"
                android:paddingStart="10dp"
                android:paddingEnd="10dp"
                android:textSize="11sp"
                app:background_normal="#ECEFF3"
                app:corner_radius="12dp"
                app:text_color_normal="#333"
                android:text="哈哈" />


        </android.support.v7.widget.LinearLayoutCompat>

和原生相同的写法 但是我们的et文字显示不全
image



        <android.support.v7.widget.LinearLayoutCompat
            android:layout_width="match_parent"
            android:background="#ff0"
            android:gravity="center_vertical"
            android:layout_height="50dp">


            <EditText
                android:layout_width="110dp"
                android:layout_height="25dp"
                android:gravity="center_vertical|start"
                android:paddingStart="10dp"
                android:paddingEnd="10dp"
                android:textSize="11sp"
                android:background="#f06"
                app:corner_radius="12dp"
                app:text_color_normal="#333"
                android:text="哈哈" />


            <com.ruffian.library.widget.REditText
                android:id="@+id/et_name"
                android:layout_width="110dp"
                android:layout_height="25dp"
                android:layout_marginLeft="20dp"
                android:paddingTop="0dp"
                android:paddingBottom="0dp"
                android:gravity="center_vertical|start"
                android:paddingStart="10dp"
                android:paddingEnd="10dp"
                android:textSize="11sp"
                app:background_normal="#ECEFF3"
                app:corner_radius="12dp"
                app:text_color_normal="#333"
                android:text="哈哈" />


        </android.support.v7.widget.LinearLayoutCompat>

android:paddingTop="0dp" android:paddingBottom="0dp" 多添加了这两句后 才可以正常显示

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant