Ticket #2216 (closed New Feature: wontfix)

Opened 7 years ago

Last modified 2 years ago

Find & Replace is not JavaScript-friendly

Reported by: A.M. Owned by:
Priority: Normal Milestone:
Component: General Version:
Keywords: Cc:

Description

When running Find & Replace against text that is longer than a few paragraphs, the editor will run very slowly and often trigger an alert in FF, informing the user that the script is misbehaving and asking whether it should be stopped or not. This usually happens if are trying to find and replace in one go. A better way to handle this functionality is to process smaller chunks of text, say 100 lines or one paragraph at a time, and use JS timer (i.e. setTimer) to process every chunk leaving a few milliseconds between iterations.

Change History

comment:1 Changed 7 years ago by w.olchawa

  • Status changed from new to closed
  • Resolution set to duplicate

This is a DUP of #2150

The problem was solved with fix [1973] which will be released in version 2.6.1.

comment:2 Changed 7 years ago by fredck

  • Keywords Confirmed added
  • Status changed from closed to reopened
  • Resolution duplicate deleted

Sorry Wojtek, this is not a DUP. It is a proposal for a better implementation for the Find/Replace code, which will still hang on extremely long texts. It is something that worths to be considered, but not that urgent since Martin fixed #2150.

comment:3 Changed 6 years ago by martinkou

Actually this idea might have a much wider use for CKeditor 3 than just the Find/Replace dialog. The problem with extremely long documents isn't limited to the Find/Replace algorithm, it also causes problem in other areas - say, when switching to Source mode, or submitting the FCKeditor form. In such areas where the length of the document might cause unpleasant latency, a simple JavaScript scheduler may be needed to run the task in chunks. If it is possible to approximate how much has been done vs. how much there is to do, we can also add a progress bar so the user knows his browser is not dead.

comment:4 Changed 6 years ago by A.M.

Exactly. I have been using this technique for years and it works well even with long-running tasks spanning minutes. The browser dialog informing users that the script is too aggressive doesn't promote FCKeditor as a very mature app.

comment:5 Changed 2 years ago by j.swiderski

  • Keywords Confirmed removed
  • Status changed from reopened to closed
  • Resolution set to wontfix

FCKeditor was retired and is no longer supported. All active development was moved to its successor, CKEditor 3.x, that is a fully mature and far superior product. We recommend you upgrade as soon as possible since this issue is no longer a problem in current code base.

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