Ticket #158 (new New Feature)

Opened 21 months ago

Last modified 3 months ago

Enable find in source view mode

Reported by: jtosi@… Owned by:
Priority: Normal Milestone:
Component: UI : Source View Version:
Keywords: Discussion Cc: predecess@…

Description

We would like to have the 'find' button enabled in the source view mode of the editor.

Change History

  Changed 21 months ago by fredck

  • keywords source, find removed
  • component changed from UI : Toolbar to UI : Source View

Ok. Just remember that the find feature built in on browsers will also search the text in the source view.

follow-up: ↓ 3   Changed 21 months ago by mjk

I've implemented this by implementing source view to run as <pre> inside of the main editing panel, and escaping ampersand and tags -- that way, the same Find/Replace code will work irrespective of mode. I'll check this into /branches/mjk when I get around to merging my changes into 2.4.

in reply to: ↑ 2   Changed 21 months ago by fredck

Replying to mjk:

I've implemented this by implementing source view to run as <pre> inside of the main editing panel, and escaping ampersand and tags

This thing needs a lot of discussion. I would recommend you to create a specific branch for this feature (FCKeditor/branches/features/richsource) and open a ticket to discussion it. There are other related features (like source coloring) and mainly a lot of issues to be workaround for it.

  Changed 20 months ago by mjk

I've made a solid first cut at this as part of [244]. I've patched this in from my local changes to 2.3, so the new enter key behaviour needs to be dealt with. This also opens up the possibility of implementing syntax colouring.

  Changed 20 months ago by alfonsoml

Now when switching modes in Firefox I get this error all the time

oRange.Select is not a function
http://localhost/fckdev/editor/_source/internals/fck.js
Line 278

  Changed 18 months ago by alfonsoml

#521 has been marked as dup

  Changed 18 months ago by alfonsoml

  • cc predecess@… added

  Changed 10 months ago by w.olchawa

  • keywords Discussion added

  Changed 3 months ago by deweller

Here is what I have discovered in v2.6.3:

When I allow Find/Replace toolbar button in source mode, I get a javascript error when trying to find text in source mode.

The code to enable the Find button that I am using is this:

FCKToolbarItems.RegisterItem('Find', new FCKToolbarButton('Find', FCKLang.Find, null, null, true, null, 16));

When I enter source mode, then click the find icon, type in text in the dialog and click the Find button, I get a javascript error. This happens in both IE 7 and Firefox 3.0.1.

IE 7 reports this error:

Line: 68 Error: 'nodeType' is null or not an object

The problem appears to be that the fck_replace.html dialog is trying to search the content of oEditor.FCK.EditorDocument. While in source mode, this object is null.

Note: See TracTickets for help on using tickets.