Search code examples
androidandroid-layoutline

Why line_solid does not appear?


Why when the line_solid does not appear? It worked with line_dotted

<ImageView
    android:id="@+id/image_line"
    android:layout_width="match_parent"
    android:layout_height="1dp"
    android:src="@drawable/line_solid"
    android:layerType="software"
    android:tint="@color/color_primary_variant"
    android:layout_marginTop ="@dimen/margin_padding_size_medium"
    app:layout_constraintBottom_toBottomOf="parent"
    app:layout_constraintStart_toStartOf="parent"
    app:layout_constraintEnd_toEndOf="parent"                    
    app:layout_constraintTop_toBottomOf="@+id/text_app_description"/> 

Solution

  • I found the answer I needed to change the tag from - android:tint= .. to - android:background= ..

    Thanks a lot for the inspirations :)