We're currently using CK Editor 4.x and it's working well, however, our users will be required to make many cut and paste changes to content in the near future. I'm attempting to configure the editor to use the Paste As Text dialog on a hotkey (Ctrl-V), but I'm at a loss as to the command to specify.
CKEDITOR.replace('editors', { customConfig: '', fullPage: true, allowedContent: true, keystrokes: [ [CKEDITOR.CTRL + 86 /*V*/, 'pasteAsPlainText'] ] });
When I use the following configuration, the Ctrl-V key combination simply pastes text and doesn't open the Past as Plain Text dialog. I can't seem to find the documentation of methods that can be called. If I change the guessed method name of pasteAsPlainText to something like "underline", then the expected underline function works.
Is this something that can be done? For the amount of work that these users will be doing, copying from the source document, clicking the "Paste as Plain Text" button and then pasting will be quite a hassle. Just removing the need to hunt for the "Paste as Plain Text" button will go a long way towards making their process more bearable.
Any help would be appreciated.
There's a configuration
There's a configuration option forcePasteAsPlainText which will enable rich html to plain text html transformation for normal pasting (by ctrl+v, without even opening paste dialog).
However, I advice you to configure Advanced Content Filter (or you can base on default configuration) which will also take care of what you paste, but it won't remove links, headers, list and other things you allowed.
Piotrek (Reinmar) Koszuliński
CKEditor JavaScript Developer
--
CKSource - http://cksource.com
--
Follow CKEditor on: Twitter | Facebook | Google+