Page number of image?

I know it’s possible to have a <$p> placeholder and, by linking it to a section in the binder, have it be replaced by the page number of that section in the compiled document.

Is it possible to do the same for images within a section? One solution I came up with is to split the text, then have a new section with just the image, and then a new section with the rest of the section. This breaks the flow of the text, however, and might complicate things, especially with many images (e.g. appendix) and with automatic titling of sections.

I’ve gone through the Placeholder Tags help page in Scrivener but I can’t seem to find anything that helps.

Maybe a solution would be to just create bookmarks manually in, e.g., LibreOffice and link to them (but that would be labourious with many images, so if there’s a way to do this through scrivener automatically that I am unaware of it would be great!)

If an image has a caption in LibreOffice, that caption is considered an eligible target for a cross-reference all by itself. So if you need to add captions to your figures anyway, then that is two birds with one stone, no need for a separate bookmark anchor near it.

As for Scrivener, it has a very limited feature set when it comes to image handling. There are no layout options, captioning (and thus no index of targets to link to), and bookmarks are only inserted for sections. I suppose we could insert bookmarks around images automatically, but there would be no way to link to them in Scrivener, and as mentioned above, that wouldn’t be the preferred way to construct a document anyway.

That is a feasible approach—the compiler is flexible enough to be adapted to an outline where not every item in the outline is meant to be a headline producing section. I’ve seen people apply the concept to tables, figures and whatever else needs a “notch” in the bookmark list—also this provides a way for treating classes of objects in Scrivener. For example you can use a label or keyword to mark these “image files”, gather them all together in a search, and the Edit/Copy Special/ sub-menu to build a list of figures.

By the way I use the MultiMarkdown format to write, and it can caption images and create references to them from other areas of the text and doesn’t require any outline manipulation to achieve an effect. Scrivener has built-in support for it, and can even export an .fodt file, which LibreOffice can work with. You’ll also get a document that has styles applied to text (so a heading is a real heading that will pop up in reference lists, outlines, ToC features and so on). It does take a small investment in learning and a potentially larger investment in converting your document to a plain-text approach, though. The Scrivener and Scapple user manuals are good examples of technical documents that make use of this method.

Thanks for the answer!

If I go with creating separate “documents” in the binder for each image, then how can I make it so that a document in the binder which is in the same level as others, is not a headline-producing section?

So if before I had:

Section 1
::Text 1
::Text 2
::::Subtext1
::::Subtext2
::Text 3
Section 2

And now I change this into:

Section 1
::Text 1
::::Image-within-text1
::::The-rest-of-text1-after-image
::Text 2
::::Subtext1
::::Subtext2
::Text 3
Section 2

Is it possible to make it so that the “image-within-text1” and “the-rest-of-text1-after-image” do not produce headlines, but “subtext1” and “subtext2” do, in fact, produce headlines?

Never mind - found it. I just check “As-is” when compiling, and the titles are not included.

This is, in fact, the most ideal solution - as you suggested I can easily then create a table of all the figures in the document, and refer specifically to the page of a table or figure within the text.