Search code examples
javascriptckeditorwysiwyg

CKEditor on font-size change event


Is there any way to capture an event when user has changed font-size?

I'm looking for something similar to this:

CKEDITOR.editor.getCommand('xxx').on('xxx', function(){

});

Solution

  • You need to use:

    CKEDITOR.instances.your_instance_name.on( 'change', function() {
        //  Code goes here
    } );
    

    Replace your_instance_name with your instance name.