﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
12263	Improvements to style handling in default Paste from Word filter	Olek Nowodziński	Olek Nowodziński	"Following PR https://github.com/ckeditor/ckeditor-dev/pull/116.

----

In default filter's `addStyle` the following optimization is performed:

{{{
this.attributes.style = styleText.replace( /^;|;(?=;)/, '' );
}}}

https://github.com/ckeditor/ckeditor-dev/blob/2752fb2d1f93f4c26630a8e830c52cc541657deb/plugins/pastefromword/filter/default.js#L89

Still, I managed to reproduce a case (http://tests.ckeditor.dev:1030/tests/tickets/9456/1), which isn't entirely covered by that RegExp as it either removes leading "";"" OR redundant "";;"":

{{{
;;font-family:calibri;font-size:medium 
}}}

will produce

{{{
;font-family:calibri;font-size:medium 
}}}

because RegExp is satisfied by removing leading "";"". 

While I'm not sure whether it really matters if some leading "";"" remains, I'm for the use of  `CKEDITOR.tools.normalizeCssText()` instead of any (even improved) RegExp to avoid any (further) problems and make sure styles are properly normalized."	Task	closed	Normal	CKEditor 4.4.4	Plugin : Paste from Word		fixed		
