Opened 9 years ago

Closed 8 years ago

#2856 closed Bug (fixed)

Inches and Centimetres

Reported by: Ajos1 Owned by: Artur Formella
Priority: Normal Milestone: FCKeditor 2.6.5
Component: General Version: FCKeditor 2.4
Keywords: Confirmed Review+ Cc:

Description

We still have people that work in Inches and NOT Centimetres. (Do not tell me off... I am trying to change them).

In "fckeditor/editor/dialog/fck_paste.html" (CleanWord) you have:


Remove margin styles. html = html.replace( /\s*MARGIN: 0cm 0cm 0pt\s*;/gi, ) ; html = html.replace( /\s*MARGIN: 0cm 0cm 0pt\s*"/gi, "\"" ) ;

html = html.replace( /\s*TEXT-INDENT: 0cm\s*;/gi, ) ; html = html.replace( /\s*TEXT-INDENT: 0cm\s*"/gi, "\"" ) ;


You might want to change to:


Remove margin styles. html = html.replace( /\s*MARGIN: 0cm 0cm 0pt\s*;/gi, ) ; html = html.replace( /\s*MARGIN: 0cm 0cm 0pt\s*"/gi, "\"" ) ;

html = html.replace( /\s*MARGIN: 0in 0in 0pt\s*;/gi, ) ; html = html.replace( /\s*MARGIN: 0in 0in 0pt\s*"/gi, "\"" ) ;

html = html.replace( /\s*TEXT-INDENT: 0cm\s*;/gi, ) ; html = html.replace( /\s*TEXT-INDENT: 0cm\s*"/gi, "\"" ) ;

html = html.replace( /\s*TEXT-INDENT: 0in\s*;/gi, ) ; html = html.replace( /\s*TEXT-INDENT: 0in\s*"/gi, "\"" ) ;


Attachments (2)

2856.patch (899 bytes) - added by Artur Formella 9 years ago.
2856.2.patch (1.4 KB) - added by Artur Formella 8 years ago.

Download all attachments as: .zip

Change History (11)

comment:1 Changed 9 years ago by Ajos1

Okay... the code segments got messed up...

You have 4 lines of code with "0cm", it might be useful having an extra 4 lines of similar code but with "0in".

comment:2 Changed 9 years ago by Michael Osipov

Milestone: FCKeditor 2.6.5

comment:3 Changed 9 years ago by Artur Formella

Keywords: Confirmed added
Version: FCKeditor 2.6.4FCKeditor 2.4

Changed 9 years ago by Artur Formella

Attachment: 2856.patch added

comment:4 Changed 9 years ago by Artur Formella

Keywords: Review? added

comment:5 Changed 8 years ago by Alfonso Martínez de Lizarrondo

Keywords: Review- added; Review? removed

Can you use non-capturing in the regex? -> /\s*MARGIN: 0(?:cm|in) 0(?:cm|in) 0pt\s*

And the what's new entry is missing.

Changed 8 years ago by Artur Formella

Attachment: 2856.2.patch added

comment:6 Changed 8 years ago by Artur Formella

Keywords: Review? added; Review- removed
Milestone: FCKeditor 2.6.5
Owner: set to Artur Formella
Status: newassigned

comment:7 Changed 8 years ago by Alfonso Martínez de Lizarrondo

Keywords: Review+ added; Review? removed

comment:8 Changed 8 years ago by Artur Formella

Fixed with [3452]

comment:9 Changed 8 years ago by Artur Formella

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