Android: resource String automatic generation

前端 未结 6 1121
心在旅途
心在旅途 2021-01-20 06:52

I\'m new to Android. When I add a button/views in Graphical layout it adds the label text this way- android:text=\"Button\" . Why doesnt it add \"android:text=\"@string/my_l

6条回答
  •  星月不相逢
    2021-01-20 07:33

    You can add the string to the strings.xml by clicking command and 1(on a mac, assume it would be control 1 on a Windows or Linux box) simultaneously. This will add the resource to strings.xml and then open that up in the editor.

提交回复
热议问题