Layout.GetDesiredWidth 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
多載
| 名稱 | Description |
|---|---|
| GetDesiredWidth(String, Int32, Int32, TextPaint) |
回傳版面需要多寬,才能以每段一行顯示指定的文字切片。 |
| GetDesiredWidth(ICharSequence, Int32, Int32, TextPaint) |
回傳版面需要多寬,才能以每段一行顯示指定的文字切片。 |
| GetDesiredWidth(ICharSequence, TextPaint) |
回傳版面需要多寬,才能每段一行顯示指定文字。 |
| GetDesiredWidth(String, TextPaint) |
回傳版面需要多寬,才能每段一行顯示指定文字。 |
GetDesiredWidth(String, Int32, Int32, TextPaint)
回傳版面需要多寬,才能以每段一行顯示指定的文字切片。
public static float GetDesiredWidth(string? source, int start, int end, Android.Text.TextPaint? paint);
static member GetDesiredWidth : string * int * int * Android.Text.TextPaint -> single
參數
- source
- String
- start
- Int32
- end
- Int32
- paint
- TextPaint
傳回
備註
回傳版面需要多寬,才能以每段一行顯示指定的文字切片。
截至 O,預設的 TextDirectionHeuristics#FIRSTSTRONG_LTR 文字方向啟發式。 在早期版本中,預設使用 TextDirectionHeuristics#LTR 。
本頁部分內容為基於 Open Source Project 所創建與分享的作品,並依授權條款所描述的使用進行修改。
適用於
GetDesiredWidth(ICharSequence, Int32, Int32, TextPaint)
回傳版面需要多寬,才能以每段一行顯示指定的文字切片。
[Android.Runtime.Register("getDesiredWidth", "(Ljava/lang/CharSequence;IILandroid/text/TextPaint;)F", "")]
public static float GetDesiredWidth(Java.Lang.ICharSequence? source, int start, int end, Android.Text.TextPaint? paint);
[<Android.Runtime.Register("getDesiredWidth", "(Ljava/lang/CharSequence;IILandroid/text/TextPaint;)F", "")>]
static member GetDesiredWidth : Java.Lang.ICharSequence * int * int * Android.Text.TextPaint -> single
參數
- source
- ICharSequence
- start
- Int32
- end
- Int32
- paint
- TextPaint
傳回
- 屬性
備註
回傳版面需要多寬,才能以每段一行顯示指定的文字切片。
截至 O,預設的 TextDirectionHeuristics#FIRSTSTRONG_LTR 文字方向啟發式。 在早期版本中,預設使用 TextDirectionHeuristics#LTR 。
本頁部分內容為基於 Open Source Project 所創建與分享的作品,並依授權條款所描述的使用進行修改。
適用於
GetDesiredWidth(ICharSequence, TextPaint)
回傳版面需要多寬,才能每段一行顯示指定文字。
[Android.Runtime.Register("getDesiredWidth", "(Ljava/lang/CharSequence;Landroid/text/TextPaint;)F", "")]
public static float GetDesiredWidth(Java.Lang.ICharSequence? source, Android.Text.TextPaint? paint);
[<Android.Runtime.Register("getDesiredWidth", "(Ljava/lang/CharSequence;Landroid/text/TextPaint;)F", "")>]
static member GetDesiredWidth : Java.Lang.ICharSequence * Android.Text.TextPaint -> single
參數
- source
- ICharSequence
- paint
- TextPaint
傳回
- 屬性
備註
回傳版面需要多寬,才能每段一行顯示指定文字。
截至 O,預設的 TextDirectionHeuristics#FIRSTSTRONG_LTR 文字方向啟發式。 在早期版本中,預設使用 TextDirectionHeuristics#LTR 。
Java 文件 android.text.Layout.getDesiredWidth(java.lang.CharSequence, android.text.TextPaint)。
本頁部分內容為基於 Open Source Project 所創建與分享的作品,並依授權條款所描述的使用進行修改。
適用於
GetDesiredWidth(String, TextPaint)
回傳版面需要多寬,才能每段一行顯示指定文字。
public static float GetDesiredWidth(string? source, Android.Text.TextPaint? paint);
static member GetDesiredWidth : string * Android.Text.TextPaint -> single
參數
- source
- String
- paint
- TextPaint
傳回
備註
回傳版面需要多寬,才能每段一行顯示指定文字。
截至 O,預設的 TextDirectionHeuristics#FIRSTSTRONG_LTR 文字方向啟發式。 在早期版本中,預設使用 TextDirectionHeuristics#LTR 。
Java 文件 android.text.Layout.getDesiredWidth(java.lang.CharSequence, android.text.TextPaint)。
本頁部分內容為基於 Open Source Project 所創建與分享的作品,並依授權條款所描述的使用進行修改。