Attention Jed, but really anyone who agrees EditorMagic 
<http://editormagic.tiddlyspot.com/>  is a worthwhile concept (i.e to 
access *anything* directly as you're typing):

EditorMagic will not work unless someone helps out with to either tweak 
Jeds "poupup at caret position plugin" or create an alternative 
implementation, i.e: A plugin that floats a tiddler at caret position in 
the editor. Below I describe some of the problems with the plugin and what 
is required for a real use case like EditorMagic. 

I set up Popupissue <http://popupissue.tiddlyspot.com/> for this issue and 
for testing, which is a much scaled down version of EditorMagic, limited to 
"title picking". Beyond Jeds plugin, Popupissue is basically limited to a 
single code tiddler (the popup content) and should not be difficult to 
understand. Briefly; it ensures the edited tiddlers text contains the 
trigger string [[ and identifies the "fragment", i.e [[*this* , and lists 
all tiddler titles with that prefix. Each listed title is really a button 
and clicking it inserts the [[title]] in the text. 

So, as seen in Popupissue <http://popupissue.tiddlyspot.com/> the current 
plugin is insufficient in these regards:

   - There is no currentTiddler variable accessible in the popup. Thus I'm 
   forced to use "[list[$:/StoryList]prefix[Draft]]" (which is ambiguous). 
   - I would assume this is also why having two tiddlers in edit mode and 
   typing [[t in the top one and [[E in the second one still only shows the 
   popup content for [[t in both.
   - Within a tiddler, it is desirable if the popup differentiates between 
   the fields, i.e currently if the popup shows from typing e.g [[t then if 
   clicking in the title field, the same open popup will move up to there 
   still showing the results for [[t
   - The plugin seems incompatible with TWs Editor Toolbar, i.e the Editor 
   Toolbar must be switched off in the Ctrlpanel settings.


A note: If I understand @Jeds plugin it calculates the caret position 
relative to the viewports upper left corner. Maybe it would be possible to 
calculate it relative to the tiddlers corner? ...and maybe this would 
resolve most of the bulleted issues auotmatically as they are all relative 
to the tiddler both in terms of position and in terms of currentTiddler 
reference.

- @Jed, anyone?

Thank you all!


<:-)


-----------------------------------------------------------------------------------------

Reference

   - @Jeds solution is found here:
   https://ooktech-tw.gitlab.io/plugins/caretposition/
   - Also @Snowgoon's Text'nEdit 
   <https://github.com/snowgoon88/TW5-extendedit> (basically a "title 
   picker") calculates the caret position:
   
   
https://github.com/snowgoon88/TW5-extendedit/blob/master/plugin/files/cursor-position.js
   - Both of those are based on:  
   https://github.com/component/textarea-caret-position
   

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWikiDev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywikidev/53d6eae7-e723-487b-87f7-19275e050cc1o%40googlegroups.com.

Reply via email to