I doubt that this is possible. But you could try something else. If you don't specify the extension of an image Sphinx chooses the appropriate by itself. This is used to have high resolution pdf-images in PDF and screen resolution images in HTML.
I don't know what Sphinx will do, if you provide two pixel images with the same resolution, eg. image.jpg image.png If Sphinx prefers the PNG you could store your variant images as PNG and the default images as JPEG. If Sphinx does not find the preferred PNG it takes the default JPEG. But I never testes this. juh Am 01.04.2014 14:52, schrieb Otto Paulsen: > Thank you . The ifconfig actually did it. Not as good as I could wish, > but probably good enough. > I want e.g. different pictures (screen shots) for different variants of > the system, so where this is relevant I can use the ifconfig directive > to choose between the pictures. > > However, what I really would wish is that I could have one directory > with all default pictures, and another directory for each variant with > the pictures that are special for that variant, and then that these > variant pictures could override the default picture if it exists (using > the same filename, of course). In the text I should only refer to the > default picture. Thus, if I find that I want to replace a picture for > one variant, I could just make a new screen shot and place it in the > variant directory, and it would automatically replace the default. > > Is something like this possible? > > The first thing I tried was using "replace", and just raplace the > picture directory name, but replace did not work inside the image > directive. (If this worked, I would have to copy all default pictures to > all variant directories, but that would be ok.) > > Otto > > > > kl. 11:13:03 UTC+2 tirsdag 1. april 2014 skrev juh følgende: > > Hi Otto, > > what differences do you mean? > > For differences according to different output format you can use the > "only" directive > > If you need another approach have a look at > sphinx-doc.org/ext/ifconfig.html > <http://sphinx-doc.org/ext/ifconfig.html> > > And there was a thread recently about multiple PDFs with shared > chapters: "Creating multiple PDFs that share chapters" > > HTH > juh > > Am 01.04.2014 10:57, schrieb Otto Paulsen: > > Hi, I am evaluating using Sphinx for user documentation in a new > project. > > > > I need to build different variants of the documentation. > > The difference between the variants may be some text and some images. > > I imagine that where the text is different, I would use different > files > > for the differnt variants. > > For images I was hoping to use different directories. > > Is this possible? > > > > What is the best way to build variants like this? > > > > Ragards, > > Otto > > > > -- > -- You received this message because you are subscribed to the Google Groups "sphinx-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/sphinx-users. For more options, visit https://groups.google.com/d/optout.
