Skip to content
New issue

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

ui.List multiline element renders outside of list container #1

Open
BenNicholls opened this issue May 6, 2017 · 1 comment
Open
Assignees
Labels

Comments

@BenNicholls
Copy link
Owner

Dear Future Ben,

ui.List renders all elements inside the list (currently just instances of ui.Textbox but there's no reason they couldn't be other things) that are even partially visible inside the list's designated area. This means that at the top and bottom of the list, multi-line elements that should only be partially be visible render all their lines, spilling over the edge.

To fix: need to think of some way of partially rendering a textbox, and call it here:

https://github.com/BenNicholls/burl/blob/master/ui/list.go#L175

This is where it decides whether an element is visible. Not hard to filter out partially visible ones and invoke the special ui.Textbox.RenderPartial() or whatever.

Sincerely,

Lazy Past Ben

PS. Sorry for not doing this properly when I fanagled all this together in the first place. I would have done it but I was making a space ship game and wanted to get to the fun part.

@BenNicholls BenNicholls self-assigned this May 6, 2017
@BenNicholls BenNicholls added the bug label May 6, 2017
@BenNicholls
Copy link
Owner Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant