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

List of feature requests #1896

Open
X-Ninja-dev opened this issue Oct 21, 2023 · 6 comments
Open

List of feature requests #1896

X-Ninja-dev opened this issue Oct 21, 2023 · 6 comments
Assignees
Labels

Comments

@X-Ninja-dev
Copy link

Detailed Description

You asked for it so here's the first list of features I need or would at least love to have :-)

Suggestet commands/features

Important

  • yt(x), yf(x), y$ - yank to, yank find, yank to end of line
  • :s/foo/bar/(g) - search and replace in current line "/g" to replace all occurrences without asking
  • :%s/foo/bar/(g) - search and replace entire file
  • ctrl n to reopen the file tree - (unless there's already a keybinding for that?)
  • . to redo last change another place in the file - Don't know how to explain but if you know Vim you know it
  • 4d or 4c - delete or change the next 4 characters. In Vim you choose the direction 4dl but that's unnecessary

It's kinda important that we have either the regex search and replace or the . key command.
Those are really the two normal ways of replacing text. The . of course being used for many other things

Less important

  • 4j, 4k, 4h, 4l - all pretty esential in Vim. Actually any command with a number before it :-)
  • most people uses relative line numbers in Vim
  • undo the last insert instead of deleting 1 character at a time
  • an option to turn off the self-closing of ", ', (, etc. It is a horrible feature that came into editors many
    years ago and it has never ever saved anyone any time, it only ever gets in the way :-) Most of the time you
    write one of these characters you are going to type the closing char too because you have to continue the
    line afterwards so it saves you nothing, but the times you are adding it to existing code you have to write
    the character, then ESC to get to normal mode, Then 'l' to move to the closing char that was put in, then 'x'
    to delete it, and then you can go to the other end press 'i', and do the whole thing again :-)
  • OR make it possible to make a visual selection and then surround the selection with (), "", [], etc. by
    typing the opening char
@fox0430
Copy link
Owner

fox0430 commented Oct 24, 2023

@X-Ninja-dev

ctrl n to reopen the file tree - (unless there's already a keybinding for that?)

Does this mean open the filer mode in the current dir?

@fox0430
Copy link
Owner

fox0430 commented Oct 26, 2023

@X-Ninja-dev

4d or 4c - delete or change the next 4 characters. In Vim you choose the direction 4dl but that's unnecessary

Cannot add 4d and 4c commands. Because it cannot be distinguished from other 4d(x) and 4c(x) commands.

@farias-hecdin
Copy link

Hello @fox0430 , how are you? First of all, I want to congratulate you on developing this editor, it's amazing! 😍

I've been using it a lot to write code in Nim. I'm a regular user of Neovim, and although I know it's not crucial for you to know, one of the things I love about Neovim is the ability to create custom keyboard shortcuts. It would be great to be able to configure shortcuts like Ctrl-q to close the editor and Ctrl-right to switch buffers or windows, just like I do in Neovim. That's why I wanted to ask if you could consider adding the functionality of customizable keyboard shortcuts in the next version of the Moe editor. 🙏

@fox0430
Copy link
Owner

fox0430 commented Jul 29, 2024

@farias-hecdin

Thank you for your interest in this project!

You want :map and :noremap right?

I've wanted to support remap key bindings, but I've been putting it off since it would require some design changes. But I don't know if I can implement it right away, but I'll try to do it soon.

If you have any suggestions on how to set it up, please let me know.

@farias-hecdin
Copy link

If you have any suggestions on how to set it up, please let me know.

Hello @fox0430 , it's a pleasure to greet you. I can already imagine the challenges of implementing something like this. I would like to help you, but I wouldn't know where to start, I'm sorry. Anyway, thank you for trying. 😊

@fox0430
Copy link
Owner

fox0430 commented Jul 29, 2024

@farias-hecdin

For example, normal mode commands are here.

proc normalCommand(status: var EditorStatus, commands: Runes): Option[Rune] =

proc isNormalModeCommand*(

Since it's written directly, we may need to consolidate the default key binding definitions in one place and then think about how to override them.

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

3 participants