cocreate
cocreate copied to clipboard
Text
Cursor: https://fontawesome.com/icons/i-cursor?style=solid next to https://fontawesome.com/icons/font?style=solid
- [x] Text tool where you can click somewhere and type
- [x] Editing existing text
- [x] Font size setting
- [ ] Font setting
- [x] Fix cursor in wrong place when changing size
- [x] Disable text entry when no text object selected
- [x] Clear text entry when resetting mode (e.g. switching pages)
- [x] Handle text object getting deleted while selected (delete cursor, deselect, disable text box; currently
textStop
crashes) - [x] Basic synchronization when someone else is editing same text (update
<input>
, try to keep cursor location by checking for exact match on prefix up to cursor or suffix from cursor in before vs. after text) - [x] Render cursor in SVG view too
- [x] Markdown support would be nice, at least basics like * and ** and `
- [x] Multiple lines, or some behavior for enter key
- [x] Escape key exits text field editing
- [x] Tom wants LaTeX support in particular, which would be really sweet
- To keep SVG as final output, I think we'll actually need to use MathJax instead of KaTeX. MathJax even renders the symbols into paths, which is nice.
~~Ideally can just re-use Coauthor code here (maybe should fork off, or add to KaTeX contrib?)~~ Can't re-use, because want to render to SVG not HTML.
Text support is now live! Even some basic Markdown support. Hopefully LaTeX next...
LaTeX support is now live too!