norg-specs icon indicating copy to clipboard operation
norg-specs copied to clipboard

Image placement markup

Open andreadev-it opened this issue 1 year ago • 2 comments

Hi, while looking at the spec, I couldn't find a way to place an image inside my norg file. In markdown, it is done like this:

![alt text](./link/to/image.png)

Is the syntax allowing something like that? Because when exporting to markdown, pdf or other documents it is often needed... I know that a lot of thought has been put into the specs, so this might have already be discussed, but how should we do it? Is it supported by the current spec?

andreadev-it avatar Mar 19 '23 14:03 andreadev-it

Image placement is delegated to the currently undocumented macro feature set.

Its syntax looks like this:

.image /path/to/image.png

The implementation of the image macro is not documented anywhere yet though :p

vhyrro avatar Mar 19 '23 18:03 vhyrro

Ah, that's very interesting. I might have misanderstood macros, since I thought that macros where basically a "shortcut" for other norg syntax, so that they would not be able to add something that wasn't possible to do otherwise. The implementation of the image macro should be done with other norg syntax, right?

andreadev-it avatar Mar 19 '23 22:03 andreadev-it