Would certainly appreciate understanding where my mistake is in my code 
below.    It's rather perplexing because the GUI is doing what I want, but 
something isn't changing within the underlying data structure.

The icon manipulations scripts are really great, except for one.

Adding icons (script 1 here) and deleting icons (script 2 here) are working 
well for me in the UI, but some hidden remnants must still exist (after 
running script 3 here)...


*=== script 1 (I created an @button script) ===*

@language python

''' add 3 icons to a node '''

table = (
    'edittrash.png',
    'connect_no.png',
    'error.png',
)
for icon in table:
    fn = g.os_path_finalize_join(g.app.loadDir,
        '..', 'Icons', 'Tango', '16x16', 'status', icon)
    if g.os_path_exists(fn):
        c.editCommands.insertIconFromFile(path=fn)


*=== script 2 (I created an @button script) ===*

@language python

''' remove icons from the node '''

c.editCommands.deleteNodeIcons(p=p)


*=== script 3 ===*

@language python

''' create a listing of all nodes which have icons '''

aList = [p.copy() for p in c.all_unique_positions() if 'lineYOffset' in p.u]
#print('\n'.join([p.h for p in aList]))
g.es_print('\n'.join([p.h for p in aList]))


... because the nodes show up in the list produced by Script 3 and nothing 
I can do (including running the "delete Todo from all" function from within 
todo.py) is removing the data remnant.   I have checked to make sure that 
there are no Tags on the nodes either.

It's a puzzler for me -- probably a no-brainer for many others.   

-Richard



On Sunday, January 31, 2016 at 6:34:21 AM UTC-8, Terry Brown wrote:
>
> On Sat, 30 Jan 2016 18:18:17 -0600 
> "Edward K. Ream" <[email protected] <javascript:>> wrote: 
>
> > On Sat, Jan 30, 2016 at 5:57 PM, Largo84 <[email protected] <javascript:>> 
> wrote: 
> > 
> > I struggled w/ Git at first too, but found that Sourcetree 
> > > <https://www.atlassian.com/software/sourcetree/overview/> made it a 
> > > lot easier for me. 
>
> GitHub has recently (< 6 months?) released a "GitHub desktop" 
> https://desktop.github.com/ 
> app. which seems ok, I usually use the command-line (or gitk for 
> review). But the desktop app. might help some. 
>
> Cheers -Terry 
>
> > ​I too started with SourceTree.  Alas, it has severe performance 
> > problems. Imo, its best feature is gui-oriented selective adding. You 
> > can do something similar on the command line with git add -p, but I 
> > never have. 
> > 
> > I finally got fed up with the performance problems (and small fonts, 
> > which they refused to fix) and switched to gitk.  Works fine for 
> > routine tasks. ​ 
> > 
> > > I still don't really 'get Git', but I'm using it nonetheless. For 
> > > pull requests only, it's pretty simple. 
> > 
> > ​Yes, me too. 
> > 
> > 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 [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.

Reply via email to