On 7/13/20 9:02 AM, Gregory Pittman wrote: > On 7/13/20 1:51 AM, JLuc wrote: >> Le 13/07/2020 à 00:25, Gregory Pittman a écrit : >>> On 7/12/20 4:06 PM, JLuc wrote: >>>> Is there a way to use the scripter to export a list of preflights warning ? >>> Not that I can find in the manual. >>> I've been working with a document recently that has a number of empty >>> frames in it, which routinely gives warnings when I try to export to PDF or >>> check with Preflight Verifier. >>> I wrote a little script to export to PDF to see what would happen, and the >>> answer is nothing - the file was exported without any hitch. >> >> I'm particularly interested in "out of range text" (text that doesnt fit in >> its frame or linked text frame chain) >> and low res pictures. > > You could make your own limited version of a verifier to do at least two > things: > > Run through the text frames and check textOverflows() > Run through the image frames, checking getImageScale() > > Checking the images is a bit tricky, since the scale doesn't by itself give > you the resolution. There might be a workaround using PIL.
Maybe not so difficult, and not needing PIL or Pillow. If you import an image into a frame at a 100% scaling (1.0 as far as getImageScale() is concerned), then you find that the DPI is 72. So if you find that the X-scale (for example) is 0.21, then dividing 72.0/0.21 will give you the DPI: 342.9 (rounded). Greg ___ Scribus Mailing List: scribus@lists.scribus.net Edit your options or unsubscribe: http://lists.scribus.net/mailman/listinfo/scribus See also: http://wiki.scribus.net http://forums.scribus.net