I like the possibility to hide tags, because it helps me to better concentrate on the text I write (program documentation in DocBook). But the tags *completely* disappearing makes me nervous -- I would like to see that there is some tag, without seeing the complete tag name. I imagine a new view mode "Almost hide tags", which would work like this:
Each XML tag is displayed as one character. For example all opening tags are displayed as "(", all closing tags are displayed as ")", and the single tags are displayed as "|" -- these characters have lightblue color, so they do not mess with reading text. When moving mouse above that character, the complete tag and attributes could be displayed as a tooltip.
I think that seeing a document like this would make it easy to focus on the text, while also noticing things like "this word is emphasised or linked". So I could both check the meaning of the text and also make sure that e.g. all names of buttons are marked.
By the way, it would be nice to have those view options in toolbar; preferably in one place with pull-down menu.
Logged In: YES
user_id=1298822
Originator: NO
Viliam, thanks for your request: I very much agree. Right now, the changing shade of the line highlight and the current element pane (if visible) are the only indication when entering a nested inline tag.
What I need to find out is if the editor control itself supports substitution strings for hidden characters. For example, I think a simple dotted vertical line (in light blue) would help a lot. The last time I checked, the control didn't support such a feature, but that isn't to say that it hasn't been added since.
I especially like the proposed (, ) and | convention + tooltip. I can see that working very well indeed, though I haven't worked out how I'd go about implementing it.
The other alternative is creating a dedicated tag-free view using the framework's recently updated rich text view (permitting embedded graphics etc.). This wouldn't be competitive in terms of performance -- as far as I know xmlce offers the only tag-free mode that can handle 12+ MB documents -- but it would allow a lot of features users appreciate in other editors.
<By the way, it would be nice to have those view options in toolbar; preferably in one place with pull-down menu.>
Yes, that would be better. I'm reluctant to overload the toolbar, but I agree that this would be a useful addition. Unfortunately the excellent OS icon set I've been using doesn't have any icons that would represent this well. (I'm not much of an artist I'm afraid :-)
In any case I am glad to hear that there is interest in the tag free mode, and as I said I think your suggestion is excellent.
Logged In: YES
user_id=1144354
Originator: YES
I do not know the possibilities which the editor control supports. If I understand it correctly, it is relatively easy to hide parts of text, or to change their color (what the current views do), but it is difficult to *replace* them with something. Is it right? Now is it possible to hide/color any parts of text (e.g. based on regex) or only XML tags? If yes, then what about replacing opening tags with "<", closing tags with ">" and single tags with "/"? Those characters do appear in the tags, so it is enough to make parts of tags invisible.
Logged In: YES
user_id=1298822
Originator: NO
All style formatting (colours, bold, hidden/visible, etc.) is based on the control's lexer. At the moment the lexer treats the <, >, and the element of <element> (say) as one style.
This does suggest one possible solution, though: if I can tweak the lexer to treat < and > differently (as XMLSpy's lexer does -- Altova seem to have written a dedicated XML lexer that differentiates between the angle brackets and tag contents; apart from that they use the same editor component).
I need to give this some thought. This might also allow me to address one very annoying limitation of the current lexer, which is that embedded DTDs are not lexed/highlighted correctly.
Interestingly, the /> of empty tags _is_ lexed as requiring a separate style; so perhaps one fix would be to extend the empty tag handler to handle ordinary open and close tags.
The source of the Scintilla HTML lexer (which doubles as its XML lexer) is very clear, so I ought to be able to do something with it.
Thanks again for your help!