MMD pictures from "Research" folder

I am fairly happy with the current setup that I am using:
Write in scrivener, including equations, references and images using MMD and exporting to latex with latex-snippet.xslt

A few questions remain:

  • I like to have the pictures that I am using in a paper imported in the “Research” folder in scrivener. Is there a way to drag and drop them into the written text and have a MMD-image code appear instead of a copy of the picture?
  • What is the best way to set multiple equations in MMD (such as \begin{eqnarray} in latex)?

Thanks for your help,

No, not like that in the editor, but embedded graphics will be exported into the compile folder and MMD syntax will be placed where they were. So in effect, yes, that’s what happens when you drag an image into a text file: you get image code. When you do things this way, the image name will be used for its label, including the extension, so you’ll cross-reference to them like [this][image_name.png]. If you need a caption, you can type one in on the same line as the graphic, “Wrapped in quotes”.

Thanks AmberV for your reply. However, I think there is still an issue. I think I might have to explain this in a little more detail.

I am writing MMD text in Scrivener which I need to export to latex via latex-snippet.xslt.
So what I could write this code manually (

It would be nice, if I could drag the image from the research binder. I can do this, and then in the text the picture shows up (
When I compile the draft from there, I do get the picture exported into latex (which is nice), but I don’t see a way to add a caption (not so nice) and a full folder containing the .tex file and the image (png file) are created (not so nice, because they are created each time).

Is there a way to add a caption if the image is displayed (like in the second screenshot)?

Thanks again for your help,

Here is an example of what I was referring to above:

Ignore the purple highlight, I comment each caption with the image filename, so that if I need to cross-ref to it, I know what the TeX label will be. The idea is to put the caption on the same line as the image and enclose it in double-quotes, just like you would in MMD, except graphically instead of within the filename declaration area. And just as with MMD, the quotes will be removed from the final copy.

There is one exception: if you tell Scrivener to compile over the same spot using the same file name, it will update the folder, not create a new one. Presumably, if you’ve re-compiled, you don’t want LaTeX’s cache and indexing files anyway—it’s best to start from scratch if you make changes to the document, so losing all of that is in my mind a nice thing. What I do for stuff I don’t want regenerated or wiped each time is to locate them one step up in the hierarchy. So I create a folder for LaTeX post-processing, and have all of my .sty files and static graphic elements in that, then I compile into a sub-folder which constantly regenerates a clean slate. To link to the stuff a level up, I just use relative addresses in the LaTeX file. So that stuff just stays the same and isn’t touched by Scrivener.