Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(51)  |  Call(51)  |  Derive(0)  |  Import(0)
Draws the image (ImageReader object or filename) as specified.

"image" may be an image filename or an ImageReader object. 

x and y define the lower left corner of the image you wish to
draw (or of its bounding box, if using preserveAspectRation below).
 
If width and height are not given, the width and height of the
image in pixels is used at a scale of 1 point to 1 pixel.  
(more...)

src/r/o/rooibos-HEAD/rooibos/presentation/viewers.py   rooibos(Download)
                image = get_image_for_record(record, presentation.owner, 800, 800, passwords)
                if image:
                    p.drawImage(image, inch / 2, inch / 2, width=width / 2 - inch, height=height / 3 - inch,
                                preserveAspectRatio=True)
                f = Frame(width / 2 + inch / 2, inch / 2,

src/s/l/Slide-Downloader-HEAD/slideparse.py   Slide-Downloader(Download)
					# img.save(imageName)
					# pdfCanvas.drawImage(imageName,0,0,width= page1.width,height= page1.height,mask='auto') 
					pdfCanvas.drawImage(ImageReader(im),0,0,width=page1.width*2,height=page1.height*2,mask='auto') 
					pdfCanvas.showPage()
					# os.remove(imageName) # delete temp image
				# img.save(imageName)
				# pdfCanvas.drawImage(imageName,0,0,width= page1.width,height= page1.height,mask='auto') 
				pdfCanvas.drawImage(ImageReader(im),0,0,width=page1.width*2,height=page1.height*2,mask='auto') 
				pdfCanvas.showPage()
				# os.remove(imageName) # delete temp image

src/d/j/django-sis-HEAD/ecwsp/sis/pdf_reports.py   django-sis(Download)
        try:    
            if stu.pic:
                c.drawImage(unicode(settings.MEDIA_ROOT[:-7] + unicode(stu.pic.url_530x400)), x, paper_height - (y-.4*cm), xsize, ysize, preserveAspectRatio=True)
            else:
                c.drawString(x, paper_height - (y+.5*cm), "No Image")

src/r/e/reportlab-3.1.8/tests/test_pdfgen_general.py   reportlab(Download)
    for i in range(5):
        if haveImages:
            (w, h) = c.drawImage(gif, (1.5 + i)*inch, 3*inch)
        else:
            (w, h) = (144, 10)
    c.drawString(2.5*inch, 1.2*inch, 'This would normally be obscured')
    if haveImages:
        c.drawImage(gif, 1*inch, 1.2*inch, w, h, mask=myMask)
        c.drawImage(gif, 3*inch, 1.2*inch, w, h, mask='auto')
    else:
        from reportlab.lib.testutils import testsFolder
        png = os.path.join(testsFolder,'solid_red_alpha.png')
        c.drawImage(png, 1*inch, 8*inch+14.4, w, h, mask=None)
        c.drawImage(png, 3*inch, 8*inch+14.4, w, h, mask='auto')
        png = os.path.join(testsFolder,'alpha_test.png')

src/m/w/mwlib.ext-0.13.2/upstream-src/tests/test_pdfgen_general.py   mwlib.ext(Download)
    for i in range(5):
        if haveImages:
            (w, h) = c.drawImage(gif, (1.5 + i)*inch, 3*inch)
        else:
            (w, h) = (144, 10)
    c.drawString(2.5*inch, 1.2*inch, 'This would normally be obscured')
    if haveImages:
        c.drawImage(gif, 1*inch, 1.2*inch, w, h, mask=myMask)
        c.drawImage(gif, 3*inch, 1.2*inch, w, h, mask='auto')
    else:
        from reportlab.lib.testutils import testsFolder
        png = os.path.join(testsFolder,'solid_red_alpha.png')
        c.drawImage(png, 1*inch, 8*inch+14.4, w, h, mask=None)
        c.drawImage(png, 3*inch, 8*inch+14.4, w, h, mask='auto')
        png = os.path.join(testsFolder,'alpha_test.png')

src/r/e/ReportLab-HEAD/tests/test_pdfgen_general.py   ReportLab(Download)
    for i in range(5):
        if haveImages:
            (w, h) = c.drawImage(gif, (1.5 + i)*inch, 3*inch)
        else:
            (w, h) = (144, 10)
    c.drawString(2.5*inch, 1.2*inch, 'This would normally be obscured')
    if haveImages:
        c.drawImage(gif, 1*inch, 1.2*inch, w, h, mask=myMask)
        c.drawImage(gif, 3*inch, 1.2*inch, w, h, mask='auto')
    else:
        from reportlab.lib.testutils import testsFolder
        png = os.path.join(testsFolder,'solid_red_alpha.png')
        c.drawImage(png, 1*inch, 8*inch+14.4, w, h, mask=None)
        c.drawImage(png, 3*inch, 8*inch+14.4, w, h, mask='auto')
        png = os.path.join(testsFolder,'alpha_test.png')

src/i/o/iOSMAnalyzer-HEAD/main.py   iOSMAnalyzer(Download)
 
  # draw image (file.jpeg, x(bottom -> top), y (bottom -> top), image size (x), image size (y)
  c.drawImage(images, 150, 550, 350, 250)
 
  # page break

src/b/t/btb-HEAD/scanblog/btb/management/commands/import_test_data.py   btb(Download)
        for page in range(part['pages']):
            if backgrounds:
                c.drawImage(backgrounds[page % len(backgrounds)], 0, 0 * inch,
                    width=8.5 * inch, preserveAspectRatio=True
                )

src/b/o/bookreader-1.0/bookreader/views/pdf.py   bookreader(Download)
        set_image_params(page.jp2, djatokaArgs, imageArgs, size)
 
        canvas.drawImage(get_djatoka_url(page.jp2, **djatokaArgs), **imageArgs)
        canvas.showPage()
    except Page.DoesNotExist:
            canvas.setPageSize((imageArgs['width'], imageArgs['height']))
 
            canvas.drawImage(get_djatoka_url(page.jp2, **djatokaArgs),
                             **imageArgs)
 
            page = book.pages.get(internal=False,
                                  title=external,jp2__isnull=False)
            canvas.drawImage(get_djatoka_url(page.jp2, **djatokaArgs),
                             **imageArgs)
            canvas.showPage()

src/m/w/mwlib.ext-0.13.2/upstream-src/tests/test_invariant.py   mwlib.ext(Download)
        c.drawString(100,700, 'Hello World')
        gif = os.path.join(testsFolder,'pythonpowered.gif')
        c.drawImage(gif,100,600)
        c.save()
 
        c.setFont('Helvetica-Bold', 36)
        c.drawString(100,700, 'Hello World')
        c.drawImage(gif,100,600)
        c.save()
 

  1 | 2  Next