Re: [PATCH] inset-forall: apply a function to all insets

2009-04-27 Thread Jean-Marc Lasgouttes
Helge Hafting writes: > Robust against infinite loops, but may have some problems of its own. > > Because now you have to keep that list of insets up-to-date during > processing. The operations done by "inset-forall" may change the > document structure - and the list of "all notes" get outdated. A

Re: [PATCH] inset-forall: apply a function to all insets

2009-04-27 Thread Helge Hafting
Vincent van Ravesteijn wrote: Jean-Marc Lasgouttes schreef: Le 25 avr. 09 à 00:07, Vincent van Ravesteijn a écrit : I think this is a battle we cannot win (not tested, but you get the idea): inset-forall Note note-insert So... you look for all Note insets, and execute note-insert for each and

Re: [PATCH] inset-forall: apply a function to all insets

2009-04-25 Thread Vincent van Ravesteijn
Jean-Marc Lasgouttes schreef: Le 25 avr. 09 à 00:07, Vincent van Ravesteijn a écrit : I think this is a battle we cannot win (not tested, but you get the idea): inset-forall Note note-insert So... you look for all Note insets, and execute note-insert for each and you'll end up with the double

Re: [PATCH] inset-forall: apply a function to all insets

2009-04-25 Thread Pavel Sanda
Jean-Marc Lasgouttes wrote: > We had a question recently about how to remove all Index insets from the > document. Rather > than building yet another UI for that, the following dirty function maybe > be useful, although > mostly for power user (not the kind of function that I would like to see >

Re: [PATCH] inset-forall: apply a function to all insets

2009-04-24 Thread Jean-Marc Lasgouttes
Le 25 avr. 09 à 00:10, Vincent van Ravesteijn a écrit : Yes, a colleague of mine wanted to change the style of all citations, so this would have been useful for that (by the way, we should add something to do that). Yes, provided with have a lfun to change citation style. mutate-note and to

Re: [PATCH] inset-forall: apply a function to all insets

2009-04-24 Thread Jean-Marc Lasgouttes
Le 25 avr. 09 à 00:07, Vincent van Ravesteijn a écrit : I think this is a battle we cannot win (not tested, but you get the idea): inset-forall Note note-insert So... you look for all Note insets, and execute note-insert for each and you'll end up with the double amount of Notes ? No, you f

Re: [PATCH] inset-forall: apply a function to all insets

2009-04-24 Thread Vincent van Ravesteijn
Jean-Marc Lasgouttes schreef: We had a question recently about how to remove all Index insets from the document. Rather than building yet another UI for that, the following dirty function maybe be useful, although mostly for power user (not the kind of function that I would like to see advertis

Re: [PATCH] inset-forall: apply a function to all insets

2009-04-24 Thread Vincent van Ravesteijn
Jean-Marc Lasgouttes schreef: Le 24 avr. 09 à 23:53, rgheck a écrit : This function has several problems: - can freeze LyX (see above) Suggestion: Keep track of which insets have been visited and refuse this kind of recursion. I think this is a battle we cannot win (not tested, but you get

Re: [PATCH] inset-forall: apply a function to all insets

2009-04-24 Thread Jean-Marc Lasgouttes
Le 24 avr. 09 à 23:53, rgheck a écrit : This function has several problems: - can freeze LyX (see above) Suggestion: Keep track of which insets have been visited and refuse this kind of recursion. I think this is a battle we cannot win (not tested, but you get the idea): inset-forall Not

Re: [PATCH] inset-forall: apply a function to all insets

2009-04-24 Thread rgheck
Jean-Marc Lasgouttes wrote: We had a question recently about how to remove all Index insets from the document. Rather than building yet another UI for that, the following dirty function maybe be useful, although mostly for power user (not the kind of function that I would like to see advertised