Index: /CKEditor/trunk/CHANGES.html
===================================================================
--- /CKEditor/trunk/CHANGES.html (revision 5941)
+++ /CKEditor/trunk/CHANGES.html (revision 5942)
@@ -65,4 +65,5 @@
#6467 : [FF] It is now possible to disable the plugin command on "mode" event.
#6461 : Attributes are now being kept when changing block formatting.
+ #6226 : BIDI: Language direction applied to a Paragraph is removed when we apply one of Paragraph formatting options.
Updated the following language files:
- #6427 : Ukrainian;
Index: /CKEditor/trunk/_source/plugins/styles/plugin.js
===================================================================
--- /CKEditor/trunk/_source/plugins/styles/plugin.js (revision 5941)
+++ /CKEditor/trunk/_source/plugins/styles/plugin.js (revision 5942)
@@ -776,5 +776,5 @@
while ( ( block = iterator.getNextParagraph() ) ) // Only one =
{
- var newBlock = getElement( this, doc );
+ var newBlock = getElement( this, doc, block );
replaceBlock( block, newBlock );
}
@@ -1084,5 +1084,5 @@
}
- function getElement( style, targetDocument )
+ function getElement( style, targetDocument, block )
{
var el;
@@ -1098,4 +1098,8 @@
// Create the element.
el = new CKEDITOR.dom.element( elementName, targetDocument );
+
+ // #6226: attributes should be copied before the new ones are applied
+ if ( block )
+ block.copyAttributes( el );
return setupElement( el, style );