these buttons are not only for xinclude but also in other references (e.g. my self-implemented xslt-conref). Moving the buttons one level up would only lower the problem rather than solving it since one referenced content might contain another. For instance an xincluded file can an xslt-conref or another xinclude.
Nevertheless, for now I removed the content from oxy|reference:before and added it to xi|include and my other references and this works. (Yet, without a way to jump to the referenced file but this should be simple to add as a new AuthorOperation.)
BTW: xi|include:before has no effect but with xi|include it looks exactly as it should.
Actually I like the idea that operations in read-only content are not available and there are other cases where it's on my todo list to remove/disable these when beeing inside a reference.
However, all the actions I've added are no operations modifying the document at all:
- refresh.reference: simply calls
Code: Select all
- reference.expand/collapse.this/all: marks the current reference / all references (of this kind) as expanded/collapsed (stored within a java-singleton that is asked by the reference resolver) and refreshes it. A collapsed xinclude will be reduced to the first title element and an xslt-conref will be hidden at all.
All these actions seem pretty useful in general - not only for my application.
So possibly the problem is that I'm using an author operation for something it is not intended for. (Another indication for this theory is that these operations always generate an undo-action and mark the document as modified while no modification occurs).
So I could think of following solutions:
- A new kind of NotModifyingAuthorOperation: no undo, not marking the document as modified, not disabled within read-only content.
- Using some other feature I'm not aware of yet.
- If you agree on the general use (I think there exists an issue for collapsing xincludes) these features could be built into oxygen.
BTW: When the buttons are disabled I'd expect them to be grayed and having the hover effect being deactivated!? Right now the buttons just don't have any effect but the user doesn't see it.
Thanks and regards,