Text Editor in Snap!

I want to show off something I made.
Here is the project.

It's not a really good project, but I did work on it for like 1 class period (50 mins in my school), so you wouldn't expect much to be added.

Cool, and it supports Russian!

This is a great project! I didn't know about the "any key" option when I made a Text Editor so unlike yours, mine couldn't pick up everything if I smash my keyboard.

I was surprised it did.

It uses the "any key" ability, so of course it's going to support most languages! :)

I wonder if you would be able to make it so that you can press ctrl+S to save.

I have seen that control keys work and are reported, it really depends on the browser though.

You would need Alt+Control+S, as Ctrl+S would get hijacked by Snap! itself, I think. I could easily be wrong, though.

I just made a project that lets you test which keys are detected, so go ahead.

Keyboard

how do I not make this sound like I'm trying to advertise my project

I would rather use Ctrl+Shift+S, since I think it's better, but I will probably add keybinds so you can customize it to your heart's content. :)

After messing with your project, I found out that that shortcut doesn't show up, so I will use your example.

P.S. I use anything that can stop the emoticons to turn into emojis. For this post, I used </z>.

I just give mine a curvy nose. :~)

Nice project. Should we feel guilty for encouraging you not to pay attention in class?

I especially like how the stage makes the cursor blink. I would suggest, though, using a full-height vertical line such as ⎸ LEFT VERTICAL BOX LINE U+23B8 because if you use the vertical bar character on the keyboard | it blends in with the text too much, even blinking. Note how the forum's cursor extends above and below even the parentheses. Or else just write the character in a larger font.

Now you just have to add all the EMACS key commands, e.g., ctrl-A to move the cursor to the beginning of the current line, alt-A to move to the beginning of the current sentence (scan backward for period-space and put the cursor after it, or at the very beginning if not found), etc.

What? I'm pretty sure everyone is used to pressing ctrl+A to select all, and home to go to the beginning of the line (ok, I'm not sure many people know about that, but it's more well known). Also, @tethrarxitet would have to implement moving the caret before adding those keybindings anyway.

Brian is an old school EMACS person :slight_smile:

And also a Mac person, so I use command+A to select all. :~)

Yes, of course!

C-x M-c M-butterfly!

That one command that overheats your computer when you want to fry eggs!

That one that converts all the dates in your text to stardates!

(Personally, I find EMACS too complex. Real programmers program with VIM!)

no
the review games keep me up to speed for the tests, and i imagine this is probably similar for a lot of people

No, since it was tech class, and I had already finished every assignment in there. My teacher there is chill.

Yes, but an issue arrives with doing so: a caret in any position will shift all of the text after it.
I suppose I could move all of the typing scripts to Stage, and make the Sprite that previously had the code the blinker, but that would require measuring the length (in pixels) of the content, and apparently my font write block I had made doesn't exactly work with the Stage, so I can't just measure one monospace character and build off of that.

I understand my logic (in this post, not the script) may be a little bit screwed up, so please hesitate to respond.

VI is better. (I'm joking, use whatever IDE you prefer.)

Nah, neovim is the best!

Yeah, it is indeed a bit complicated (I also made a text editor). One way is to just display the caret as a sprite instead of a character.