Guild icon
Teeworlds
IRC / bridge
One-way IRC channel bridge. If you want to be able to send messages to IRC, contact @Dune or @heinrich5991. https://www.teeworlds.com/?page=docs&wiki=rules/irc_rules
Between 2020-06-19 00:00:00Z and 2020-06-20 00:00:00Z
Avatar
I actually don't even know how I'll handle selection over linebreaks :/
Avatar
for the copy-paste PR?
Avatar
any fundamental problem?
Avatar
Well I was rendering it in 3 pieces, the part before the selection, the selection, the part after the selection
13:17
That obviously won't work if the parts are not inline
Avatar
how does it behave atm?
Avatar
I'm building it right now to check
13:22
hm it selects on the wrong line, but even worse the rendering for multiline is horrible
13:22
the cursor moving around reflows the text
13:23
hm I wonder if my patch breaks that
13:25
nope it's awful in master
13:25
oh I bet it's awful only for a long uninterrupted string because it's looking for a wordstop to break
Avatar
You know what would be great? A way to specify the background color for a cursor
13:36
I have no way to know where the last line ended :/
13:36
Poll: Do I hack in the ending of last line into the cursor or background color?
13:37
Oh or bonus option, CTextRender::TextBackground()
Avatar
oh boy that looks dirty
13:38
but CTextRender is already a pile of dirt I guess :D
Avatar
Tbh selections are supposed to be an overlay not background color
13:39
I actually don't know the UI best practices in that regards
13:41
Yeah it's supposed to be an overlay, sooo class CTextCursor { bool m_Selecting; vec4 m_SelectionColor; }?
13:42
meh, everything I can think of actually sounds awfully dirty, I wonder how other projects do it
13:47
Btw, why did matricks think that the old CTextRender interface was foolish?
Avatar
Also turns out rendering a rectangle isn't actually trivial when you don't have CRenderTools 😄
Avatar
Actually this is quite impossible to do like this, you can't change textures while drawing, I bet it'd kill performance to begin and end after each character
Avatar
he mentioned too many virtual calls
Avatar
Okay, I actually don't know how to fix this
14:35
Any suggestions are very welcome
Avatar
You could do a third pass in addition to outline and text. But querying all the characters a third time (with a linear lookup) won't help performance =\
Avatar
I've written something so ugly it'll make your hair fall out
14:53
but I'll commit it see if oy will have a seizure
Avatar
Great :D
Avatar
It'd be good if text selection rendering did not worse text rendering performance when there is no text selection
Avatar
text rendering is already very bad
Avatar
An extra branch per batch shouldn't(tm) matter much about performance
Avatar
At least this solution won't hurt performance :)
Avatar
The text reflowing when you have multiline text is very annoying btw
15:04
Now onto the console one, how do I get a linebreak in the console?
Avatar
The console has linebreaks?
Avatar
Well Oy said: "When there's a line break in the console the cursor isn't shown anymore and when you select sth it's not rendered correctly."
Avatar
I don't understand how you can get a line break in the console
15:10
enter sends the command
Avatar
I tried \ to escape the newline but that doesn't do it either
15:11
a very long line doesn't wrap for me either
Avatar
removing linebreaks from text or executing in the case of the console would be preferralke imo.
15:12
preferrable*
Avatar
just ask oy how to reproduce
Exported 49 message(s)