| [ Web Proxy ] |
| Viewing: https://matplotlib.org/users/../api/_as_gen/../../users/explain/../../api/backend_cairo_api.html | [Back] [Original] |
Section Navigation
matplotlibmatplotlib.animationmatplotlib.artistmatplotlib.axesmatplotlib.axismatplotlib.backend_basesmatplotlib.backend_managersmatplotlib.backend_toolsmatplotlib.backendsmatplotlib.backends.backend_mixedmatplotlib.backends.backend_templatematplotlib.backends.backend_aggmatplotlib.backends.backend_cairomatplotlib.backends.backend_gtk3agg, matplotlib.backends.backend_gtk3cairomatplotlib.backends.backend_gtk4agg, matplotlib.backends.backend_gtk4cairomatplotlib.backends.backend_nbaggmatplotlib.backends.backend_pdfmatplotlib.backends.backend_pgfmatplotlib.backends.backend_psmatplotlib.backends.registrymatplotlib.backends.backend_qtagg, matplotlib.backends.backend_qtcairomatplotlib.backends.backend_svgmatplotlib.backends.backend_tkagg, matplotlib.backends.backend_tkcairomatplotlib.backends.backend_webagg_corematplotlib.backends.backend_webaggmatplotlib.backends.backend_wxagg, matplotlib.backends.backend_wxcairomatplotlib.beziermatplotlib.categorymatplotlib.cbookmatplotlib.cmmatplotlib.collectionsmatplotlib.colorbarmatplotlib.colorizermatplotlib.colorsmatplotlib.containermatplotlib.contourmatplotlib.datesmatplotlib.dvireadmatplotlib.figurematplotlib.font_managermatplotlib.ft2fontmatplotlib.gridspec
matplotlib.hatchmatplotlib.imagematplotlib.insetmatplotlib.layout_enginematplotlib.legendmatplotlib.legend_handlermatplotlib.lines
matplotlib.markers
matplotlib.mathtextmatplotlib.mlabmatplotlib.offsetboxmatplotlib.patchesmatplotlib.pathmatplotlib.patheffectsmatplotlib.pyplotmatplotlib.projections
matplotlib.quiver
matplotlib.rcsetupmatplotlib.sankeymatplotlib.scalematplotlib.sphinxext.mathmplmatplotlib.sphinxext.plot_directivematplotlib.sphinxext.figmpl_directivematplotlib.sphinxext.rolesmatplotlib.spinesmatplotlib.stylematplotlib.tablematplotlib.testingmatplotlib.textmatplotlib.texmanagermatplotlib.tickermatplotlib.transformsmatplotlib.trimatplotlib.typingmatplotlib.unitsmatplotlib.widgetsmatplotlib._afmmatplotlib._apimatplotlib._docstringmatplotlib._enumsmatplotlib._type1fontmatplotlib._tight_bboxmatplotlib._tight_layoutmpl_toolkits.mplot3dmpl_toolkits.axes_grid1mpl_toolkits.axisartistpylabmatplotlib.backendsmatplotlib.backends.backend_cairomatplotlib.backends.backend_cairo#Steve Chaplin and others
This backend depends on cairocffi or pycairo.
alias of FigureCanvasCairo
Bases: FigureCanvasBase
Bases: GraphicsContextBase
Restore the graphics context from the stack - needed only for backends that save graphics contexts on a stack.
Set the alpha value used for blending - not supported on all backends.
If alpha=None (the default), the alpha components of the
foreground and fill colors will be used to set their respective
transparencies (where applicable); otherwise, alpha will override
them.
Set how to draw endpoints of lines.
CapStyle or {'butt', 'projecting', 'round'}Set the clip path to a TransformedPath or None.
Set the dash style for the gc.
Distance, in points, into the dash pattern at which to start the pattern. It is usually set to 0.
The on-off sequence as points. None specifies a solid line. All values must otherwise be non-negative (\(\ge 0\)).
Notes
See p. 666 of the PostScript Language Reference for more info.
Set the foreground color.
If fg is known to be an (r, g, b, a) tuple, isRGBA can be
set to True to improve performance.
Bases: RendererBase
Draw an RGBA image.
GraphicsContextBaseA graphics context with clipping information.
The distance in physical units (i.e., dots or pixels) from the left hand side of the canvas.
The distance in physical units (i.e., dots or pixels) from the bottom side of the canvas.
numpy.uint8An array of RGBA pixels.
Affine2DBaseIf and only if the concrete backend is written such that
option_scale_image returns True, an affine
transformation (i.e., an Affine2DBase) may be passed to
draw_image. The translation vector of the
transformation is given in physical units (i.e., dots or pixels).
Note that the transformation does not override x and y,
and has to be applied before translatingthe result by
x and y (this can be accomplished by adding x
and y to the translation vector defined by transform).
Draw a marker at each of path's vertices (excluding control points).
The base (fallback) implementation makes multiple calls to draw_path.
Backends may want to override this method in order to draw the marker
only once and reuse it multiple times.
Draw a Path instance using the given affine transform.
Draw a text instance.
GraphicsContextBaseThe graphics context.
The x location of the text in display coords.
The y location of the text baseline in display coords.
The text string.
FontPropertiesThe font properties.
The rotation angle in degrees anti-clockwise.
If True, use mathtext parser.
TextThe original text object to be rendered.
Notes
Notes for backend implementers:
RendererBase.draw_text also supports passing "TeX" to the ismath
parameter to use TeX rendering, but this is not required for actual
rendering backends, and indeed many builtin backends do not support
this. Rather, TeX rendering is provided by draw_tex.
Get the width, height, and descent (offset from the bottom to the baseline), in
display coords, of the string s with FontProperties prop.
Whitespace at the start and the end of s is included in the reported width.
Return an instance of a GraphicsContextBase.
Convert points to display units.
You need to override this function (unless your backend doesn't have a dpi, e.g., postscript or svg). Some imaging systems assume some value for pixels per inch:
points to pixels = points * pixels_per_inch/72 * dpi/72
FigureCanvasFigureCanvasCairoFigureCanvasCairo.copy_from_bbox()FigureCanvasCairo.get_renderer()FigureCanvasCairo.print_pdf()FigureCanvasCairo.print_png()FigureCanvasCairo.print_ps()FigureCanvasCairo.print_raw()FigureCanvasCairo.print_rgba()FigureCanvasCairo.print_svg()FigureCanvasCairo.print_svgz()FigureCanvasCairo.restore_region()GraphicsContextCairoGraphicsContextCairo.get_antialiased()GraphicsContextCairo.get_rgb()GraphicsContextCairo.restore()GraphicsContextCairo.set_alpha()GraphicsContextCairo.set_antialiased()GraphicsContextCairo.set_capstyle()GraphicsContextCairo.set_clip_path()GraphicsContextCairo.set_clip_rectangle()GraphicsContextCairo.set_dashes()GraphicsContextCairo.set_foreground()GraphicsContextCairo.set_joinstyle()GraphicsContextCairo.set_linewidth()RendererCairo
Copyright 20022012 John Hunter, Darren Dale, Eric Firing, Michael Droettboom and the Matplotlib development team; 20122026 The Matplotlib development team.
Created using Sphinx 9.1.0.
Built from v3.11.2-1-g879ad8ebba.
Built with the PyData Sphinx Theme 0.16.1.
| Web Proxy Viewer | New URL | Original Page |