Hi Mario, hello others,

today I have successfully installed the CodeMirror package and I'd like to 
share my thoughts.

First, thanks Mario, that's a breakthrough. I like the idea to work within 
TW (although, in Android one still needs tools like console and html/css 
instectors).

Second, I must admit, it wasn't easy with current documentation and notes 
from previous attempts helped me. I'd suggest to create an "installation" 
section and list these steps there:

* copy/import codemirror.js, runmode.js, zCodeMirrorPlugin with their 
systemConfig tags
* edit EditTemplate by adding the "<div class='toolbar' 
macro='typeChooser'></div>" line (for instance after the "<div 
class='editor' macro='edit title'></div>" line)
* optionally edit ViewTemplate by adding "(type: <span macro='view 
content-type link'></span>)" in the "<div class='subtitle'>..." line, 
before the ending "</div>"
* copy/import CMEditCommands with systemConfig tag, change ToolbarCommands 
by adding cmEdit to the ViewToolbar slice and cmSave to the EditToolbar 
slice, copy/import codemirror.css
* copy (and may be edit) CodeMirrorConfig
* add parts for different modes: css.js for CSS, tiddlywiki.js and 
tiddlywiki.css for TiddlyWiki syntax etc; overlay.js [here some 
instructions about when it's need may go]
* save and reload
* to get syntax highlightning in the cmEdit mode work, go to the 
edit/cmEdit mode and chose a content-type for the tiddler (for instance, 
"text/css" for a CSS tiddler)
* optionally install ExtraKeysAddOn and/or RenderBufferPlugin

Next, I've encountered several bugs which I'll list in the order of 
descreasing importance [all the plugins I used are of up-to-date versions; 
I haven't installed the two additional plugins]:

* for me, in both Opera and FireFox text selection in the cmEdit mode is 
invisible (that's rather disturbing for the workflow), but that happens 
only in my local TW, not in the TiddlySpace repository of CodeMirrorPlugins
** may be I installed something wrongly? looks like I took all the 
necessary tiddlers from [1]
* after content-type is chosen with typeChooser, the text area gets hidden. 
Saving and reopening the tiddler gets it back to visible and the 
content-type is saved, though
* when I press and hold the "down" button, sometimes the cursor doesn't go 
just down, but also jumps to the right
** I haven't succeed to make this totally reproducabe -- even for me in the 
same conditions it sometimes happens and sometimes doesn't. The only thing 
I can say is I that happened in a tiddler which consists totally of list 
items of different levels
* finally, "&nbsp;" still appears next to the "1" in the line number colomn

Some wishes and then ideas:

* it would be much more convenient if the typeChooser is a toolbar command 
as well -- in this case it wouldn't be necessary to edit templates at all
* would be very nice if the "Are you sure you want to abandon your changes" 
prompt doesn't appear if no changes were applied. As for now it does in the 
zCodeMirrorPlugin even if it wasn't touched; and if any tiddler was touched 
but it led to no changes (say, pressed space and then backspace), the 
prompt appears as well
* an idea: to extend the x-tiddlywiki highlightning so that inner links and 
wikiwords are highlighted too (may be with blue, paler than that of 
external links)
* also, as for now I don't see any reason (aside developer's convenience) 
to keep all those separated tiddlers: for the ease of installation, it 
would be more useful to have at least zCodeMirrorPlugin, CMEditCommands 
merged and also codemirror.js, codemirror.css and runmode.js merged

Finally, thanks again for the plugin(s).

Best regards,
Yakov.

[1] http://codemirror.tiddlyspace.com/#tag:cmtw

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at http://groups.google.com/group/tiddlywiki?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to