Ticket #2856 (closed Bug: fixed)

Opened 6 years ago

Last modified 6 years ago

Inches and Centimetres

Reported by: ajos1 Owned by: arczi
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

2856.patch (899 bytes) - added by arczi 6 years ago.
2856.2.patch (1.4 KB) - added by arczi 6 years ago.

Change History

comment:1 Changed 6 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 6 years ago by mosipov

  • Milestone FCKeditor 2.6.5 deleted

comment:3 Changed 6 years ago by arczi

  • Keywords Confirmed added
  • Version changed from FCKeditor 2.6.4 to FCKeditor 2.4

Changed 6 years ago by arczi

comment:4 Changed 6 years ago by arczi

  • Keywords Review? added

comment:5 Changed 6 years ago by alfonsoml

  • 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 6 years ago by arczi

comment:6 Changed 6 years ago by arczi

  • Status changed from new to assigned
  • Keywords Review? added; Review- removed
  • Owner set to arczi
  • Milestone set to FCKeditor 2.6.5

comment:7 Changed 6 years ago by alfonsoml

  • Keywords Review+ added; Review? removed

comment:8 Changed 6 years ago by arczi

Fixed with [3452]

comment:9 Changed 6 years ago by arczi

  • Status changed from assigned to closed
  • Resolution set to fixed
Note: See TracTickets for help on using tickets.
© 2003 – 2012 CKSource – Frederico Knabben. All rights reserved. | Terms of use | Privacy policy