#2182 closed defect (fixed)
text like C:D gets [C:D C:D]
Reported by: | rupert thurner | Owned by: | Jun Omae |
---|---|---|---|
Priority: | normal | Component: | TracWysiwygPlugin |
Severity: | normal | Keywords: | |
Cc: | Trac Release: | 0.10 |
Description
text like C:D gets [C:D C:D], in other words
text like C:D gets [C:D C:D].
Attachments (0)
Change History (4)
comment:1 Changed 17 years ago by
comment:2 Changed 17 years ago by
thanks to the recent correction, the direction wysiwyg --> text works (nearly) as it produces C:D.
having C:D already in the text view and then switch to wysiwyg still produces the [C:D C:D].
i am not sure if the wiki syntax parser is ill as:
- moinmoin recently went away from wiki:asdf? type of links
- this editor also has difficulties with such links
comment:3 Changed 17 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
comment:4 Changed 17 years ago by
This fix works well, except that I wonder if the same technique could be applied to wiki links. I saw that http-type links stay the same, but if I have a text like TracWysiwygPlugin, then if I "round-trip" this then I get [wiki:TracWysiwygPlugin]
as a result. If this is a sub-case of this ticket, then if jun66j5 agrees this is a design problem then we could reopen or make a new ticket. In my opinion it is ideal for links to be converted to their canonical form, which should be the shortest/least specified form possible. If anyone disagrees I think this may be a good topic for debate, as I noticed that the editor moves wiki to and from a DOM model, it will always have the side-effect of removing any superficial formatting and canonicalizing all links and formatting.
Yes, I've noticed that hyperlinks and such do this as well. Anything that the JS interprets as a link it rewrites into an explicit link, even if the link text matches the link specification exactly.
Perhaps that would be an easy way to patch the code. It seems as if loads wiki into a model, then converts the model to a wiki, which loses original source even if it is functionally equivalent. But, it could follow a "best practice" in source generation if it said for a link it is going to generate
[A B]
that ifA == B
, then just generate A not in brackets.