[AppStream] Additional markup support in descriptions
Robert Ancell
robert.ancell at canonical.com
Sun Jul 28 06:46:46 UTC 2019
On Sat, Jul 27, 2019 at 12:35 AM Matthias Klumpp <matthias at tenstral.net>
wrote:
> Am Fr., 26. Juli 2019 um 05:32 Uhr schrieb Robert Ancell
> <robert.ancell at canonical.com>:
> >
> > I propose we add the following:
> > - emphasis <em>
>
> The <em> emphasis is already scheduled for addition, we had a really
> long discussion about this particular one in
> https://github.com/ximion/appstream/issues/184
Nice!
> - strong emphasis <strong>
>
> I am not so sure about this one - isn't a regular emphasis enough?
>
In HTML regular emphasis is italics by default and strong bold. I think you
could get away with one level of emphasis, but it's probably a good idea to
align with HTML/Markdown and support two.
> > - code <code> or <pre> or <pre><code> (CommonMark uses options 1 and 3,
> but it's probably simpler to just only <code> or <pre> in AppStream. I'm
> not enough of an XML expert to work out the differences between these tags).
>
> <code> makes sense to me, if it isn't overused. Would code be inline
> monospace, or rather be a code block?
>
CommonMark supports both [1] [2] and I think both are useful, but you could
probably use a single tag to express both, i.e.:
<p>
The name <code>foo</code> is commonly used as a placeholder, e.g.:
</p>
<p><code>
int foo = 5;
</code></p>
As Simon pointed out staying close to HTML is probably a good idea to avoid
confusion. I guess that would mean supporting both <code> and <pre>.
[1] https://spec.commonmark.org/0.29/#code-spans
[2] https://spec.commonmark.org/0.29/#indented-code-blocks
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/appstream/attachments/20190728/c7f5fcad/attachment.html>
More information about the AppStream
mailing list