Closed Kvaz1r closed 5 years ago
I time to time forget that file can be created from open menu. Not sure is make sense have separate option or something because it's a bit unintuitively.
Do you think that it would make sense to have (new file)
or something as the default selection when opening a file, as long as what has been typed out is not an exact match for a file that already exists? Then you would have to cycle left or right to get auto-completion for files that already exist.
Probably. I see two reason in this confusion.
:thinking: you're right, that does seem to be common to keep those separate. I based the "open file" command on what I'm used to in emacs, which has a single unified "open/create file" interface. Emacs works very similar to how vidar is right now - if you want to create a new file, you have to cancel the autocompletion.
vidar is intended to be a little bit more similar to emacs
and vim
than it is to modern editors like atom
or vscode
... but it should take lessons from modern editors. Modern editors have file pickers that clutter up the interface and make opening a file more complicated, and I think that's why they have separate "New File" and "Open File" commands ... but I'm not certain. I'll have to check a few of them to see.
I'll try a few options. I think it might help if I updated the command with the (new file)
entry and also update the name of the command (in the menu) to be something like "Open or Create File". Although, it might still be a little difficult to explain that you can also create new directories by typing the name of the directory and hitting /
instead of enter
.
Maybe I need to finally add "tutorial" and "help" commands to the editor.
Modern editors have file pickers that clutter up the interface and make opening a file more complicated, and I think that's why they have separate "New File" and "Open File" commands ... but I'm not certain.
New file it's temporary one it not always will saved by user so it's also reason of difference. Moreover file pickers are different in Windows and Linux, in Windows they provide pop-up menu and user can create new file from opening operation.
I think it might help if I updated the command with the (new file) entry and also update the name of the command (in the menu) to be something like "Open or Create File".
Yes, it will definitely helpful.
Although, it might still be a little difficult to explain that you can also create new directories by typing the name of the directory and hitting / instead of enter.
I don't think so cause user immediately see path and will considering it as path constructor. It's easy because it's natural. The thin thing here is understand that "Esc" breaks only auto-completion as sub-command and not full open command.
Maybe I need to finally add "tutorial" and "help" commands to the editor.
Tutorials are really great but it's very hard to write, so I think at this time it's not worth it. While all users get vidar via go get it's not needed cause there are issue section and gitter. And for beginning, menu Help can contain only links to site/wiki/...
Description
Add option to create a new file to FIle menu.