>________________________________ > From: Edward K. Ream <edream...@gmail.com> >To: leo-editor <leo-editor@googlegroups.com> >Sent: Friday, February 26, 2016 8:47 AM >Subject: Re: Code Academy: find by predicate or attribute > >On Friday, February 26, 2016 at 6:42:34 AM UTC-6, Edward K. Ream wrote: > >> On Thu, Feb 25, 2016 at 6:42 PM, Richard Andersen <monta...@gmail.com> wrote: > >>> I'd like...to use the Clone Find All Flattened command to find all my >>> Nodes which are "open tasks"...Ideally, these would be shown in context >>> with the parent tags down to the "found" tags > >> An interesting problem. It just needs a different predicate. Here is tested >> code: >[snip] >>I'm not sure this is all that useful, but it's what you said you wanted... > >On second thought, I think the solution is fine, provided that there is a >visual indication of which nodes actually have 'open' and 'todo' tags. This >is easy to do: the nodetags plugin simply needs to attach distinct icons for >each tag. That way all you have to do is to expand all the nodes provided by >the cloneFindByPredicate. Easy, straightforward.
Sorry to bring up the "inadmissible" ;-) solutions again, but todo.py includes icons, of course, and a "go to next todo node" which seems to cover similar ground to the finding nodes which have open / todo tags. To digress (the real point of my response is the next para :-) I have scripts which search across a long list of .leo files for open todo items (using leosax for speed), and generate flattened lists (views) of the same in various orders. Further, UNLs pointing into the (possibly unloaded) leo file containing the real todo node are stored on the shadow todo items in the collected lists and changes to attributes trigger loading of the target file and change of the corresponding attribute on the real todo node. Obviously limited point going on about all this unreleased kind of messy code - I guess part of the reason for not trying to package it up is that I suspect people attracted to Leo are inclined to want to homebrew there own take on the perfect task management system... anyway, just some approaches that have worked for me. >In short, we urgently need ways to attach icons to tags (or any other >attribute). Once we have that, the user can find the desired nodes either by >looking through the outline or by looking at the nodes provided by >cloneFindByPredicate. Still think the "declutter" machinery might work for this - basically it applies "beyond stylesheet" style / visualization changes to nodes, currently it uses rules like this: # remove @clean etc. and use an icon RULE ^@clean (.*) REPLACE \1 ICON file_icons/file_clean.png RULE ^@auto (.*) REPLACE \1 ICON file_icons/file_auto.png ... # if the node name starts with 'peacock node DEMO', make a mess of it RULE ^(peacock node DEMO) REPLACE LOOK: \1 ICON Tango/16x16/emotes/face-grin.png ICON Tango/16x16/emotes/face-wink.png FG @solarized-magenta BG white FONT Times PX 40 ITALIC 1 WEIGHT Bold So all it needs is a different sort of RULE that looks into p.v.u, maybe a also variant that deals specifically with tags, seeing I'm guessing any generic rule for getting into p.v.u['path']['morepath']['list_of_strings'], which worth having, may be cumbersome of the specific case of tag driven icons. Cheers -Terry >Edward > > -- >You received this message because you are subscribed to the Google Groups >"leo-editor" group. >To unsubscribe from this group and stop receiving emails from it, send an >email to leo-editor+unsubscr...@googlegroups.com. >To post to this group, send email to leo-editor@googlegroups.com. >Visit this group at https://groups.google.com/group/leo-editor. >For more options, visit https://groups.google.com/d/optout. > > > -- You received this message because you are subscribed to the Google Groups "leo-editor" group. To unsubscribe from this group and stop receiving emails from it, send an email to leo-editor+unsubscr...@googlegroups.com. To post to this group, send email to leo-editor@googlegroups.com. Visit this group at https://groups.google.com/group/leo-editor. For more options, visit https://groups.google.com/d/optout.