Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to insert "<<" text in TextView?

Tags:

java

android

xml

I need to insert "<<" in android:text = "<<" but there are raise problem with:

Multiple annotations found at this line:
    - [I18N] Hardcoded string "<<", should use @string resource
    - The value of attribute "android:text" associated with an element type "Button" must not contain the '<' 
     character.

Can you tell me how can I insert << in xml file TextView text?

like image 964
user1343673 Avatar asked Apr 30 '12 11:04

user1343673


1 Answers

Try &lt;&lt; instead of <<. You have to escape those characters because they influence your XML layout.

like image 167
Kai Avatar answered Oct 12 '22 11:10

Kai