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

How can we show the text in two lines? #40

Open
sustun opened this issue Sep 27, 2017 · 4 comments
Open

How can we show the text in two lines? #40

sustun opened this issue Sep 27, 2017 · 4 comments

Comments

@sustun
Copy link

sustun commented Sep 27, 2017

Hello there;
I want to show a text consisting of two lines within a label. \ n or html text does not work.
Best regards.

@ldimitroff
Copy link

That's because there is a tag setted for singleLine... If you want a quick solution, make a copy of this layout on this project and delete that propperty.

https://github.com/Cutta/TagView/blob/0043b7d68bc4ced477928125c6a5379c9c2db381/library/src/main/res/layout/tagview_item.xml

@sustun
Copy link
Author

sustun commented Sep 27, 2017

I did not understand what you said. I'm using Android Studio and Gradle.

@ldimitroff
Copy link

ldimitroff commented Sep 27, 2017

In Android Studio, create a new layout resource file. name it "tagview_item.xml"

Inside paste this code as it is:

`

<TextView
    android:id="@+id/tv_tag_item_contain"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:gravity="center" />

<TextView
    android:id="@+id/tv_tag_item_delete"
    android:layout_width="wrap_content"
    android:layout_height="match_parent"
    android:gravity="center"
    android:visibility="gone"/>

`

@DivyaPrajapati09
Copy link

Above solution works only if you add the library manually in your project instead of Gradle.

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

3 participants