Opened 3 years ago

Closed 3 years ago

#16678 closed Bug (duplicate)

format of pasted text from word is not showed correctly in the toolbar

Reported by: Boris Feuerpeil Owned by:
Priority: Normal Milestone:
Component: UI : Toolbar Version: 4.6.0
Keywords: Cc:

Description

Steps to reproduce

  1. type text in ms word and format it
  2. copy the formatted text and paste it in ckeditor with or without paste from word function
  3. now set cursor in the pasted text

Expected result

the toolbar (format buttons like font style and size) should show the correct format that was selected in word

Actual result

the toolbar still shows the ckeditor default format

Other details (browser, OS, CKEditor version, installed plugins)

  • all browsers
  • ckeditor 4.6
  • no additionaly installed plugins

the html code of the example:

<span style="font-size: 36pt;"><span style="color: red;"><span style="line-height: 107%;"><span style="font-family: &quot;Arial&quot;,sans-serif;">This is a Format Test</span></span></span></span>

Attachments (2)

format_word.png (17.4 KB) - added by Boris Feuerpeil 3 years ago.
Copied Text from Word
format_ckeditor.png (15.0 KB) - added by Boris Feuerpeil 3 years ago.
Pasted Text in CKEditor

Download all attachments as: .zip

Change History (3)

Changed 3 years ago by Boris Feuerpeil

Attachment: format_word.png added

Copied Text from Word

Changed 3 years ago by Boris Feuerpeil

Attachment: format_ckeditor.png added

Pasted Text in CKEditor

comment:1 Changed 3 years ago by Jakub Ś

Keywords: paste word format removed
Resolution: duplicate
Status: newclosed

At the moment styles in CKEditor work in a way that external style has to match dropdown style. Styles created by MS Word look like this:

<p><span style="font-size:36.0pt"><span style="font-family:&quot;Arial&quot;,&quot;sans-serif&quot;"><span style="color:red">Test text</span></span></span></p>

while styles created by CKEditor like this:

<p><span style="font-family:Arial,Helvetica,sans-serif"><span style="font-size:36px"><span style="color:#ff0000">Test</span></span></span></p>

As you can see they don't match.

This is a duplicate of more general issue: #9964

Note: See TracTickets for help on using tickets.
© 2003 – 2019 CKSource – Frederico Knabben. All rights reserved. | Terms of use | Privacy policy