http://docs.cksource.com/ckeditor_api/symbols/src/plugins_styles_styles_default.js.html
CKEDITOR.stylesSet.add('default',[
{name:'Heading 1',element:'p',styles:{'font-size':'14px', 'margin-bottom':'10px', 'font-weight':'bold'}},
{name:'Heading 2',element:'p',styles:{'font-size':'12px', 'margin-bottom':'10px', 'font-weight':'bold', 'font-style':'italic'}},
{name:'Std Text',element:'p',styles:{'font-size':'11px', 'margin-bottom':'10px'}},
{name:'Std Text Ctr',element:'p',styles:{'font-size':'11px', 'margin-bottom':'10px', 'text-align':'center'}},
{name:'Std Text Right',element:'p',styles:{'font-size':'11px', 'margin-bottom':'10px', 'text-align':'right'}},
{name:'Std Text Bold',element:'p',styles:{'font-size':'11px', 'margin-bottom':'10px', 'font-weight':'bold'}},
{name:'Std Text Bold Ctr',element:'p',styles:{'font-size':'11px', 'margin-bottom':'10px', 'font-weight':'bold', 'text-align':'center'}},
{name:'Std Text Bold Right',element:'p',styles:{'font-size':'11px', 'margin-bottom':'10px', 'font-weight':'bold', 'text-align':'right'}},
{name:'Std Link',element:'p',styles:{'font-size':'11px', 'margin-bottom':'10px', 'color':'#bb0000', 'text-transform':'none', 'text-decoration':'underline'}},
{name:'List Text',element:'p',styles:{'font-size':'11px'}},
{name:'List Text Ctr',element:'p',styles:{'font-size':'11px', 'text-align':'center'}},
{name:'List Text Right',element:'p',styles:{'font-size':'11px', 'text-align':'right'}},
{name:'List Text Bold',element:'p',styles:{'font-size':'11px', 'font-weight':'bold'}},
{name:'List Text Bold Ctr',element:'p',styles:{'font-size':'11px', 'font-weight':'bold', 'text-align':'center'}},
{name:'List Text Bold Right',element:'p',styles:{'font-size':'11px', 'font-weight':'bold', 'text-align':'right'}},
{name:'List Link',element:'p',styles:{'font-size':'11px', 'color':'#bb0000', 'text-transform':'none', 'text-decoration':'underline'}},
{name:'Bullet List - disc',element:'ul',styles:{'list-style-type':'disc'}}
]);

Re: Styles dropdown missing entries
Re: Styles dropdown missing entries
would like to get this code generated:
<ul class="ListSquareGold">
<li>This one</li>
<li>That One</li>
</ul>
I am using this code to add style... the other three show up in styles list, but no the UL style
CKEDITOR.addStylesSet( 'bls_styles',
[
{ name : 'Body', element : 'p', attributes : { 'class' : 'body' } },
{ name : 'SectionHeading' , element : 'p', attributes : { 'class' : 'PageSectionHeading' } },
{ name : 'ListSquareGold' , element : 'ul', attributes : { 'class' : 'ListSquareGold' } },
{ name : 'SecondaryMenu' , element : 'div', attributes : { 'class' : 'Menu2' } }
]);
Any thoughts? if this is not right way to do this, please advise.
Re: Styles dropdown missing entries
Re: Styles dropdown missing entries
Stylesavailable for the element that is currently selected
Styles
Styles
Documentation Manager, CKSource
See CKEditor 5 docs, CKEditor 4 docs, CKEditor 3 docs, CKFinder 3 docs, CKFinder 2 docs for help.
Visit the new CKEditor SDK for samples showcasing editor features to try out and download!