开发者

Two line text for MenuItem

开发者 https://www.devze.com 2023-02-05 06:12 出处:网络
Do you know how 开发者_开发百科to have a two lines menu item title? I\'ve tried using \\n in the string or Html.fromHtml withtag but it doesn\'t work. ThanksThis is the recommended answer from Google:

Do you know how 开发者_开发百科to have a two lines menu item title? I've tried using \n in the string or Html.fromHtml with

tag but it doesn't work. Thanks


This is the recommended answer from Google: "If text in a simple menu wraps to a second line, use a simple dialog instead. Simple dialogs can have rows with varying heights."

https://material.io/guidelines/components/menus.html#menus-simple-menus


You can use String line=System.getProperty("line.separator")


this will give you newline effect in string.

0

精彩评论

暂无评论...
验证码 换一张
取 消