On Thursday, June 6, 2013 8:25:22 PM UTC+2, Arc Acorn wrote: > > It looks like the normal textarea is still around just hidden in > codemirror mode, so would it be possible to reverse this and make a system > where you could switch between the two and it would copy/replace the > content from one to the other on switch? > :)))) What you discribe here is exactly, what codemirror does. The hidden textarea is still in use. When you open a tiddler it creates the cm-editor by copying the "visible" stuff from the textarea to the highlighter. cm only keeps about 100 lines of the text in the "editor". Imagine you need to highlight 1000 lines and just see 30 of them. .... so the hidden text area is the "cached text content" everything is synced back and forth.
effectively adding a button to the normal view mode: [Switch to code view.] > > It seems like logically the way this would work is to not use the CmEdit > or CmSave and instead simply have it as a layer on top () that could > be switched from hidden to displayed (Which looks like you can already do, > the content just doesn't interact with each other.) > There is super heavy interaction going on. As I said that's how codemirror works :) It would be less work to create cm aware EditButtons because cm has api functions for this. > and have the content of the textarea copied over, and when save is hit if > the codemirror div is displayed have it's contents copied back over to the > normal textarea and than save as normal. > Thats how cmEdit and cmSave works :) There is no problem, if you have cmEdit and editTiddler in the ToolbarCommands tiddler. The whole stuff, just wasn't designed for this. It may be confusing and atm imo it won't work. -m -- You received this message because you are subscribed to the Google Groups "TiddlyWiki" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/tiddlywiki?hl=en. For more options, visit https://groups.google.com/groups/opt_out.

