Closed tecosaur closed 1 year ago
Thanks, good idea with the matching of brackets to the theme.
Thanks for merging this :slightly_smiling_face:.
I will admit though, after diving into some of the internals here I've become afflicted with a growing temptation to try to make a from-scratch-but-copying-a-few-things-from-OhMyREPL fancy REPL package that's put together a bit differently.
Go for it, it's fun :)
Gah! Encouragement was the last thing I needed :stuck_out_tongue_closed_eyes:
If anything nice seems to happen I'll let you know.
For a while I've thought it's a pity that julia
doesn't come with OhMyREPL, so I might see if I can make something that only depends on JuliaSyntax
— which might at least allow this to be more seriously considered :crossed_fingers:.
I've been meaning for a long time to allow the Julia REPL to take a "highlighter" that would take the current buffer of the REPL and return a set of bytes and color "tokens" and the REPL would display that colored output. That would allow packages like OhMyREPL to avoid having to do any method overwrites or adding all these awkward keybindings that we do here.
On a similar note, for a while I've felt Julia could benefit from a "string + text properties" type, which would allow one to say "this word is red" etc. without having to mess around with printstyled
or manually dealing with shell escape codes etc., and also have the advantage of being able to easily fall back to plaintext or even be represented in other formats, e.g. HTML.
Kristoffer, let me know if you'd be interested in hearing more from me about this. I've just been able to do an evening's work on this, but so far I have an (incremental) history filtering system working which only depends on Base + REPL. Over the weekend I might see how much further I can take this.
Three things (which can be split up, if needed)
Sample screenshot: