Opened 14 years ago

Closed 14 years ago

Last modified 14 years ago

#5246 closed Bug (fixed)

3.2 Bug : CKEDITOR.addStylesSet no longer works....

Reported by: Ben Owned by:
Priority: Must have (possibly next milestone) Milestone: CKEditor 3.2
Component: General Version: 3.2
Keywords: Confirmed Cc:

Description

I had a custom style set added to my 3.1 install... Now that I upgraded to 3.2 it's no longer working. It just shows a blank style drop down (see attachment).

I have added the following code to CKEDITOR.editorConfig = function( config ):

config.stylesCombo_stylesSet = 'custom_styles';

And here is my custom style set:

/* Custom style settings.

Added the styles here so they can be modified using action hooks.

*/

CKEDITOR.addStylesSet( 'custom_styles', [

/* Block Styles */

/* Inline Styles */

{ name : 'Marker: Yellow' , element : 'span', styles : { 'background-color' : 'Yellow' } }, { name : 'Marker: Green' , element : 'span', styles : { 'background-color' : 'Lime' } },

{ name : 'Big' , element : 'big' }, { name : 'Small' , element : 'small' }, { name : 'Typewriter' , element : 'tt' },

{ name : 'Computer Code' , element : 'code' }, { name : 'Keyboard Phrase' , element : 'kbd' }, { name : 'Sample Text' , element : 'samp' }, { name : 'Variable' , element : 'var' },

{ name : 'Deleted Text' , element : 'del' }, { name : 'Inserted Text' , element : 'ins' },

{ name : 'Cited Work' , element : 'cite' }, { name : 'Inline Quotation' , element : 'q' },

{ name : 'Language: RTL' , element : 'span', attributes : { 'dir' : 'rtl' } }, { name : 'Language: LTR' , element : 'span', attributes : { 'dir' : 'ltr' } },

/* Object Styles */

{

name : 'Image on Left', element : 'img', attributes : {

'style' : 'padding: 5px; margin-right: 5px', 'border' : '2', 'align' : 'left'

}

},

{

name : 'Image on Right', element : 'img', attributes : {

'style' : 'padding: 5px; margin-left: 5px', 'border' : '2', 'align' : 'right'

}

}

]);

Like I said, it was working in 3.1. Hopefully there is a fix for it in the meantime because I would really like to keep using 3.2 :)

Keep up the great work!

Attachments (1)

Screen shot 2010-02-26 at 12.30.40 PM.png (36.3 KB) - added by Ben 14 years ago.
This is what it looks like when I have a custom style set

Download all attachments as: .zip

Change History (4)

Changed 14 years ago by Ben

This is what it looks like when I have a custom style set

comment:1 Changed 14 years ago by Ben

Some more info for you... Firebug is coming up saying

CKEDITOR.addStylesSet is not a function

comment:2 Changed 14 years ago by Frederico Caldeira Knabben

Keywords: Confirmed added
Resolution: fixed
Status: newclosed

The API has been modified for the styles loading for the 3.2. I've requested to maintain backwards compatibility, but it looks like this have not been implemented in the proper way.

I've fixed it with [5198] for the urgent 3.2 "re-release" will do today. But, you can also make it work by replacing CKEDITOR.addStylesSet with CKEDITOR.stylesSet.add.

comment:3 Changed 14 years ago by Frederico Caldeira Knabben

Milestone: CKEditor 3.2

This one has been included in the "re-release" we did today. Please download the 3.2 again.

Note: See TracTickets for help on using tickets.
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy