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
Documenting codemirror shorcuts. #4591
Conversation
you can actually use a set of predetermined keyboard shortcuts to | ||
write and manipulate your content in an easier way. | ||
|
||
Below, you will find three tables listing the available shortcuts: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems unnecessarily complex. What about one table, with columns for 'PC shortcut' and 'Mac shortcut'?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree, I will do the change...
Thomas comments addressed, I think ;-) |
------------------------------------------------------------------------------ | ||
Basic Action pcDefault Action macDefault | ||
========== ================== ============ ================= ============= | ||
Left go to char left Ctrl-A select all Cmd-A |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I haven't generated the HTML, but I think this side-by-side view is also confusing. Let's have just three columns: Action, PC shortcut, Mac shortcut (and write the column headers out properly, not pcDefault
- it's not a variable name). Where the shortcut is the same on PC and Mac, either leave one blank, or repeat it (or use a rowspan, but that requires creating the more cumbersome grid style tables).
Also, we don't need to list really obvious things like left/right/up/down or backspace/delete. That's just common vocabulary for editing any text-based document.
(And does anyone actually use 'Insert'? The only time I'm ever aware of it is when I hit it by mistake, find that I'm overwriting text I'd already written, curse a bit and turn it off)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK, I will do the changes in a couple of hours...
And regarding the "Insert", I had also find it by mistake, but I think that it can be useful for some people...
OK, not a few hours... just a few minutes 😉 , take a look and let me know. |
go to line start Home Home | ||
go to line end Alt-Right Cmd-Right | ||
go to line end End End | ||
del word before Ctrl-Back Alt-Back |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
'Back' is backspace? I think I'd rather write it out in full, even if it makes the columns wider.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK
Thanks, this looks much better. I'll build the docs to take a look at the result. |
go to cell start Ctrl-Home Cmd-Up | ||
go to cell start Alt-Up Cmd-End | ||
go to cell start PageUp PageUp | ||
go to cell end Ctrl-End - |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These dashes render as bullet points. --
or ---
work - I prefer the weight of the latter.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK, I agree...
OK, comments addressed... |
select all Ctrl-A Cmd-A | ||
delete line Ctrl-D Cmd-D | ||
undo Ctrl-Z Cmd-Z | ||
redo Shift-Ctrl-Z Shift-Cmd-Z |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nitpick: I think it's more common to write 'Ctrl-Shift' than 'Shift-Ctrl'. Likewise, Min reckons that the norm for Mac shortcuts is 'Cmd-Shift', at least when written in words.
Done! |
travis failed on its own, I just restarted it. |
Travis has now succeeded, it just seems to have failed to post the results here. This is all fine unless @Carreau has anything to add about shortcuts on other keyboards when he wakes up. |
would it be worth it to add a link to these codemirror shortcuts to |
I don't think it be worth to add a link inside |
I would have thought that the 'Keyboard shortcuts' popup was the best place to put the link, but putting it in the menu as e.g. 'Editor shortcuts' would work too. Feel free to go ahead and do it in this PR. |
I added the link to the menu. |
That makes sense. But how are we going to remember to update it at release time? Maybe make an issue with milestone 2.0? |
Yes, I was thinking the same... I am opening an issue to deal with it before 2.0. Can you assign it to the 2.0 milestone, please? Thanks. |
I've had another quick check through, and I think this looks good. Thanks for your patience, Damian. |
Documenting codemirror shorcuts.
No problem! Thanks for your feedback 👍 |
Documenting codemirror shorcuts.
I found me looking for this inside the codemirror.js source, so I decided to document it here because I think it will be valuable for others.
Please, check the semantic (I mean the way to express things) because English it is not my mother language and it is important to be clear in the doc...