#3709 closed New Feature (wontfix)
Selected text stays selected when switch to source view and back
Reported by: | spx | Owned by: | Garry Yao |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | General | Version: | |
Keywords: | Confirmed | Cc: | fournaise, henke.bill@gmail.com, joel.peltonen@… |
Description
Hello. To me FCKeditor is almost perfect. The only thing I miss from Dreamweaver is selection preservation while switching to source view.
Since I work with very big html files it is very difficult to find any specific place in code. When I select a word (or sentence or picture or table cell) in WYSIWYG mode in Dreamveawer and then switch to source view I find myself in the middle of the (pages of the) code with the same text selected.
If FCKeditor could do that - it would save very much worktime. But FCKeditor resets the cursor location to start of the source.
Attachments (1)
Change History (32)
comment:1 Changed 16 years ago by
Keywords: | Confirmed added |
---|---|
Milestone: | → CKEditor 3.x |
Changed 16 years ago by
Attachment: | 3709.patch added |
---|
comment:2 Changed 16 years ago by
Component: | UI : Toolbar → General |
---|---|
Keywords: | Review? added |
Owner: | set to Garry Yao |
Status: | new → assigned |
Proposing of adding a textselection plugin to handle selection within 'source' mode and enable the 'selection synchronous' feature by config entry syncSelection .
comment:3 Changed 16 years ago by
Current limitation: scroll into view for 'source' mode is not implemented yet for all non-IE.
comment:6 Changed 14 years ago by
Cc: | fournaise henke.bill@gmail.com added |
---|
comment:8 Changed 13 years ago by
After applying the patch is there anything else to be done? "Proposing of adding a textselection plugin to handle selection within 'source' mode and enable the 'selection synchronous' feature by config entry syncSelection . " .Can you please explain me in detail
comment:9 Changed 13 years ago by
Can any one please help me on this . I am using CKEditor 3.6.2 and I have applied the patch. Is there any thing else to be done ? Can someone please help on this
comment:10 Changed 13 years ago by
If you are seeking advice please use one of our forums (http://cksource.com/forums/) and not bug tracker.
Second I have applied the patch for latest trunk version of CKEditor.
All I had to do to get it working was resolving conflicts in _source\core\config.js file.
To use the plugin - type some enough text so that scrollbar appears. Scroll down a little bit select word/sentence and switch to source. Editor will scroll down to that line (tested under FF8).
comment:11 Changed 13 years ago by
@ j.swiderski
Firstly, Thanks for your prompt response and s sorry for posting in the wrong place . I am still blocked :( Now I have posted it in the forum http://cksource.com/forums/viewtopic.php?f=11&t=24151 . Can you please help me out further there .
comment:12 Changed 13 years ago by
Status: | review → review_failed |
---|
I have checked the patch in each browser. The plugin does not work.
Here are my results:
- In Webkit selection stays when switching to source but the editor does not scroll down to it.
- In FF and IE9-7 it keeps selection and scrolls to it - somewhat works
- In Opera it scrolls to the text but it does not select it
- In IE6 it does not work.
What is more when you switch from Source to WYSIWYG mode you get stackOverflow error.
Below are errors from browsers:
FF
Message: too much recursion
URI: /ckeditor_trunk/_source/core/dom/node.js
Line: 24
Chrome:
Message: Uncaught RangeError: Maximum call stack size exceeded
URI: /ckeditor_trunk/_source/core/dom/comment.js
Line: 15
Opera:
Code: this.base( text );
Message: Uncaught RangeError: Maximum call stack size exceeded
URI: /ckeditor_trunk/_source/core/dom/comment.js
Line: 20
IE9:
Message: too much recursion
URI: /ckeditor_trunk/_source/core/dom/node.js
Line: 26
comment:14 Changed 13 years ago by
There's still interest in this feature. It was requested in ticket 9684-QRPH-1050
comment:15 Changed 13 years ago by
Do we have any update on this ticket ?
It is realy really cool feature and evryone loves it.
comment:17 Changed 13 years ago by
We are also looking for this feature either in the current 3.x CKEditor branch (which I hear is no longer being developed) or in the future 4.x release. Can someone from CKSource comment on if this is being added into the 4.x release?
comment:18 Changed 12 years ago by
Can anyone in CKSource please comment on if this will be implemented or if there is a way to implement this? I'd hate to have to replace our CKEditor implementation with the Telerik Editor...
comment:19 Changed 12 years ago by
Cc: | joel.peltonen@… added |
---|
comment:20 Changed 12 years ago by
Does anybody know how to port this patch to the 4.x CKEditor? It's very cool and useful feature! I really need it.
comment:21 Changed 12 years ago by
We're not working on this right now. In any case, you can find a v3 patch on this ticket, which may eventually work. That's a good starting point for those interested on implementing this feature.
comment:24 Changed 12 years ago by
The patch / plugin from comment 22 works for me on 4.0
It would be nice if a patch could be committed to the core, so the plugin can be installed on a normal release, without the need to patch first.
Maybe it would help the issue, if someone with sufficient rights would change the status back to review?
comment:26 Changed 12 years ago by
Maybe it would help the Ticket, if someone with sufficient rights would change the status back to review?
comment:27 Changed 11 years ago by
It would fail the review because the patch will definitely not work on CKEDITOR 4.2.x. First someone (everyone can do that) would have to prepare the patch (preferably as a pull request for https://github.com/ckeditor/ckeditor-dev) and then it would be justified to change the status.
Also, I think that this feature can be implemented as a plugin. So it does not need to be a pull request - it can be an addon added to http://ckeditor.com/addons/plugins/all. And that's even more preferable way, because it wouldn't need to wait for us (the core developers) to be reviewed and tested.
comment:28 Changed 11 years ago by
After i could get the patch working with 4.3 (and also 4.2), i prepared a pull-request: https://github.com/ckeditor/ckeditor-dev/pull/64
This was a mere copy/paste job, due to my limited coding skills. I can't tell if the plugin could be done without having a patch, or if (and how) the code from the patch could be added via a plugin.
The original author prontsevich stated "Maybe it's not the best solution, but it works.": http://ckeditor.com/comment/123133#comment-123133
I tested the sample in latest chrome, FF, Opera, all fine, but IE 10 is not fully working, the selection moves/expands a bit with each WYSIWYG-Source switch.
comment:29 Changed 11 years ago by
I removed the pull request as it's no more needed. w8tcha has improved the plugin so it needs no core patching...
keeping textselection works out of the box with this: https://github.com/w8tcha/CKEditor-TextSelection-Plugin/
comment:30 Changed 11 years ago by
Resolution: | → wontfix |
---|---|
Status: | review_failed → closed |
Available as a plugin here: http://ckeditor.com/addon/textselection
I'm not sure if it is possible. There is also other, basic solution: preserve scrolling.