Opened 11 years ago

Closed 11 years ago

Last modified 10 years ago

#3496 closed New Feature (fixed)

SCAYT plug-in for CKEdtior

Reported by: Artur Formella Owned by: Frederico Caldeira Knabben
Priority: Normal Milestone: CKEditor 3.0
Component: UI : Spell Checker Version:
Keywords: Review+ 3.0RC Doc Cc: WebSpellChecker.net

Description (last modified by Frederico Caldeira Knabben)

Introduce the new "Spell Check As You Type" (SCAYT) spell checker option, provided by SpellChecker.net.

Attachments (3)

3496.patch (27.9 KB) - added by Artur Formella 11 years ago.
3496.2.patch (29.9 KB) - added by Artur Formella 11 years ago.
3496_3.patch (46.8 KB) - added by Frederico Caldeira Knabben 11 years ago.

Download all attachments as: .zip

Change History (19)

comment:1 Changed 11 years ago by Artur Formella

Owner: set to Artur Formella
Status: newassigned

comment:2 Changed 11 years ago by Frederico Caldeira Knabben

Description: modified (diff)
Milestone: CKEditor 3.xCKEditor 3.0

comment:3 Changed 11 years ago by Frederico Caldeira Knabben

Cc: WebSpellChecker.net added

Changed 11 years ago by Artur Formella

Attachment: 3496.patch added

comment:4 Changed 11 years ago by Artur Formella

Keywords: Review? added

It is a powerful plugin but there is still a lot to be done. I have marked it in the code (TODO).

Know issues:

  • plugin works only on first instance of CKEditor
  • options dialog saves changes only once
  • dialog files should be joined into one .js file to avoid domains problems.

Despite these problems plugin works.

It it experimental phase, to enable plugin please set CKEDITOR.config.scayt_autoStartup to true.

comment:5 Changed 11 years ago by Frederico Caldeira Knabben

Keywords: Review- added; Review? removed

The plugin.js file is missing in the patch.

comment:6 Changed 11 years ago by Frederico Caldeira Knabben

Keywords: 3.0RC added

Changed 11 years ago by Artur Formella

Attachment: 3496.2.patch added

comment:7 Changed 11 years ago by Artur Formella

Keywords: Review? added; Review- removed

Changes:

-now it works with many editor instances

-options dialog is in 1 JS file

-scayt is setting to disabled before setting to source mode.

-added "More suggestions" submenu.

-unused commands and menu items are removed

-editor.lang is used

There is one issue in IE when editor is empty.

I have made changes in panelbutton/plugin.js, because I have to set the state of Panel button to ON.

comment:8 Changed 11 years ago by Frederico Caldeira Knabben

Keywords: Review- added; Review? removed

Ok... it looks like we're almost there. Good job Artur.

There a few issues and enhancements we could have here:

  • The button state is not preserved when going source mode and back.
  • It would be nice to have a real menu instead of the custom panel used for the toolbar button.
  • The elements path is showing the spellchecker span.
  • If possible, we should change "Enable SCAYT" to "Disable SCAYT", it it's enabled, and back to previous label when disabling it.
  • The dialog title should be "Spell Check As You Type".

comment:9 Changed 11 years ago by Frederico Caldeira Knabben

Also... unrelated changes have been made to the config.js file with the previous patch.

comment:10 in reply to:  8 Changed 11 years ago by Frederico Caldeira Knabben

Replying to fredck:

It would be nice to have a real menu instead of the custom panel used for the toolbar button.

This feature depends on #3531.

comment:11 in reply to:  8 Changed 11 years ago by Artur Formella

Replying to fredck:

  • The elements path is showing the spellchecker span.

What do you think about:

if ( element.getAttribute( '_cke_real_element_type' ) )
	name = element.getAttribute( '_cke_real_element_type' );

else if ( element.getName() == 'span' && element.getAttribute( 'scayt_word' ) )
	name =  editor.lang.scayt.misspelledWord  // = 'misspelled word'
	
else
	name = element.getName();

comment:12 Changed 11 years ago by Frederico Caldeira Knabben

Owner: changed from Artur Formella to Frederico Caldeira Knabben
Status: assignednew

I'm taking over this ticket, as we need to have it done for the RC.

Changed 11 years ago by Frederico Caldeira Knabben

Attachment: 3496_3.patch added

comment:13 Changed 11 years ago by Frederico Caldeira Knabben

Keywords: Review? added; Review- removed

This new patch fixes all the previously mentioned issues, except the element path thing. We can have it fixed with a dedicate ticket later, as it involves generic editor features.

There is still room for improvements in the plugin and dialog scripts. But we can go ahead with it as it is now.

The style for disabled menu items is not correct. This will be handled by a dedicated ticket.

I'm including the coded that fixes #3531 and #3532, because it was difficult to isolate the code related to them from code that is interested to this ticket. So, as soon as we close this one, those other two tickets will get closed also.

comment:14 Changed 11 years ago by Artur Formella

Keywords: Review+ added; Review? removed

When scayt_autoStartup = true the initial state of button is wrong. This is small issue so I will open a new ticket for it.

comment:15 Changed 11 years ago by Frederico Caldeira Knabben

Resolution: fixed
Status: newclosed

Fixed with [3516].

comment:16 Changed 11 years ago by Artur Formella

Keywords: Doc? added

"preserveState" was introduced with this ticket.

Note: See TracTickets for help on using tickets.
© 2003 – 2019 CKSource – Frederico Knabben. All rights reserved. | Terms of use | Privacy policy