Jürgen Spitzmüller wrote:
Jean-Marc Lasgouttes wrote:
The later is not in BufferParams. It only exists because there are
instances in the document. To write it differently, the Branch panel
would both show the branches of BufferParams and the branches that have
not been defined, allowing easily to define these if needed. The goal is
to avoid automatic creation of dead branches in the document (cruft).
But it would require extra work: you have to open the document dialog and
"accept" the branches. I really would like to avoid that.
Also, I think users should be informed anyway if an unknown branch is
pasted to their documents. So why not let them add those to the branch
list?
Are you sure that all the places where pasting is invoked allow for a
dialog?
Hm, why shouldn't it?
One cannot avoid having these unknown branches anyway. I just tried to
deleted a branch that is in use. Result: the branch is shown as "child
only"!
Then it is defined in a child and not in the master. If not, you found a bug
that needs to be fixed.
I think that all these complicated tricks with branch are too
complicated for their own good.
I think we should disable the deletion of branches if the branch is still
used. Or at least issue a warning.
If the user delete a branch that is in use, consider a dialog
with these options:
* delete all branch content - useful for an outdated "comment" branch
* dissolve branch insets - looses the branch but keeps the contents.
Either way, the branch itself is gone as the user requested. There ought
to be a "cancel" option too, of course.
Refusing to delete a branch, or keeping "unknown" branch insets is bad,
the user will then need to search for every inset for that branch
in order to deal with it. Software does that faster. :-)
Helge Hafting