We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
fyne-io
andydotxyz
Jacalz
dweymouth
toaster
Learn more about funding links in repositories.
Report abuse
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
If a label in a Scroll container have its text starts with a space. and its Wrapping equals TextWrapWord.
TextWrapWord
eg
l :=widget.NewLabel(" AAAA") l.Wrapping = fyne.TextWrapWord
Then program will crash at RichText.go with index out of range -1
RichText.go
Run code in Example code will cause program to crash
package main import ( "fyne.io/fyne/v2" "fyne.io/fyne/v2/app" "fyne.io/fyne/v2/container" "fyne.io/fyne/v2/widget" ) func main() { a := app.New() w := a.NewWindow("Hello World") texts := make([]fyne.CanvasObject, 32) for i := 0; i < len(texts); i++ { l := widget.NewLabelWithStyle( " AAAA", fyne.TextAlignCenter, fyne.TextStyle{}) l.Wrapping = fyne.TextWrapWord texts[i] = l } vbox := container.NewVBox(texts...) scroll := container.NewScroll(vbox) w.SetContent(scroll) w.Resize(fyne.NewSize(360, 540)) w.ShowAndRun() }
v2.2.4
1.19
Windows
Windows 10
No response
The text was updated successfully, but these errors were encountered:
Maybe its the same problem as #3291
Sorry, something went wrong.
Please can you test against v2.3.0 which was released yesterday. Lots of text code was upgraded.
Problem still exists in v2.3.0
Fixed on develop, thanks @alexballas
No branches or pull requests
Checklist
Describe the bug
If a label in a Scroll container have its text starts with a space. and its Wrapping equals
TextWrapWord
.eg
Then program will crash at
RichText.go
with index out of range -1How to reproduce
Run code in Example code will cause program to crash
Screenshots
Example code
Fyne version
v2.2.4
Go compiler version
1.19
Operating system
Windows
Operating system version
Windows 10
Additional Information
No response
The text was updated successfully, but these errors were encountered: