Upgrade to v2.5
Fyne API v2.5
package fyne
Animation
AnimationCurve
App
AppMetadata
BuildType
Canvas
CanvasObject
Clipboard
CloudProvider
CloudProviderPreferences
CloudProviderStorage
Container
Delta
Device
DeviceOrientation
Disableable
DoubleTappable
DragEvent
Draggable
Driver
Focusable
HardwareKey
KeyboardShortcut
KeyEvent
KeyModifier
KeyName
Layout
LegacyTheme
Lifecycle
ListableURI
Locale
MainMenu
Menu
MenuItem
Notification
OverlayStack
PointEvent
Position
Preferences
Resource
Scrollable
ScrollEvent
SecondaryTappable
Settings
Shortcut
Shortcutable
ShortcutCopy
ShortcutCut
ShortcutHandler
ShortcutPaste
ShortcutRedo
ShortcutSelectAll
ShortcutUndo
Size
StaticResource
Storage
StringValidator
Tabbable
Tappable
TextAlign
TextStyle
TextTruncation
TextWrap
Theme
ThemeColorName
ThemedResource
ThemeIconName
ThemeSizeName
ThemeVariant
URI
URIReadCloser
URIWithIcon
URIWriteCloser
Validatable
Vector2
Widget
WidgetRenderer
Window
app
canvas
container
data/binding
data/validation
dialog
driver
driver/desktop
driver/mobile
driver/software
lang
layout
storage
storage/repository
test
theme
widget
Fyne API "fyne.TextWrap"
fyne.TextWrap
import "fyne.io/fyne/v2"
Usage
type TextWrap
type TextWrap int
TextWrap represents how text longer than the widget’s width will be wrapped.
const (
// TextWrapOff extends the widget's width to fit the text, no wrapping is applied.
TextWrapOff TextWrap = iota
// TextTruncate trims the text to the widget's width, no wrapping is applied.
// If an entry is asked to truncate it will provide scrolling capabilities.
//
// Deprecated: Use `TextTruncateClip` value of the widget `Truncation` field instead
TextTruncate
// TextWrapBreak trims the line of characters to the widget's width adding the excess as new line.
// An Entry with text wrapping will scroll vertically if there is not enough space for all the text.
TextWrapBreak
// TextWrapWord trims the line of words to the widget's width adding the excess as new line.
// An Entry with text wrapping will scroll vertically if there is not enough space for all the text.
TextWrapWord
)