Stop using rsvg_handle_render_cairo
It is deprecated. Using rsvg_handle_render_document() instead.
This commit is contained in:
parent
e59686f942
commit
20d45409ce
2 changed files with 17 additions and 3 deletions
|
|
@ -6,7 +6,7 @@ Copyright (c) 2002-2023
|
||||||
Various contributors (see below, and AUTHORS.txt)
|
Various contributors (see below, and AUTHORS.txt)
|
||||||
https://tuxpaint.org/
|
https://tuxpaint.org/
|
||||||
|
|
||||||
2023.June.13 (0.9.31)
|
2023.June.18 (0.9.31)
|
||||||
* New Magic Tools:
|
* New Magic Tools:
|
||||||
----------------
|
----------------
|
||||||
* Loops - Draw loop-the-loops.
|
* Loops - Draw loop-the-loops.
|
||||||
|
|
@ -141,6 +141,10 @@ https://tuxpaint.org/
|
||||||
was running and generating a cache, which was unexpected.)
|
was running and generating a cache, which was unexpected.)
|
||||||
Tim Dickson <dickson.tim@googlemail.com>
|
Tim Dickson <dickson.tim@googlemail.com>
|
||||||
|
|
||||||
|
* WIP Replaced deprecated RSVG library calls.
|
||||||
|
https://sourceforge.net/p/tuxpaint/bugs/278/
|
||||||
|
Bill Kendrick <bill@newbreedsoftware.com>
|
||||||
|
|
||||||
2023.May.18 (0.9.30)
|
2023.May.18 (0.9.30)
|
||||||
* Improvements to Stamp tool:
|
* Improvements to Stamp tool:
|
||||||
---------------------------
|
---------------------------
|
||||||
|
|
|
||||||
|
|
@ -20979,7 +20979,7 @@ static SDL_Surface *_load_svg(const char *file)
|
||||||
int width, height, stride;
|
int width, height, stride;
|
||||||
float scale;
|
float scale;
|
||||||
int bpp = 32, btpp = 4;
|
int bpp = 32, btpp = 4;
|
||||||
RsvgDimensionData dimensions;
|
RsvgRectangle viewport;
|
||||||
SDL_Surface *sdl_surface, *sdl_surface_tmp;
|
SDL_Surface *sdl_surface, *sdl_surface_tmp;
|
||||||
Uint32 rmask, gmask, bmask, amask;
|
Uint32 rmask, gmask, bmask, amask;
|
||||||
|
|
||||||
|
|
@ -21063,8 +21063,18 @@ static SDL_Surface *_load_svg(const char *file)
|
||||||
|
|
||||||
/* FIXME: We can use cairo_rotate() here to rotate stamps! -bjk 2007.06.21 */
|
/* FIXME: We can use cairo_rotate() here to rotate stamps! -bjk 2007.06.21 */
|
||||||
|
|
||||||
rsvg_handle_render_cairo(rsvg_handle, cr);
|
viewport.x = 0;
|
||||||
|
viewport.y = 0;
|
||||||
|
viewport.width = width;
|
||||||
|
viewport.height = height;
|
||||||
|
|
||||||
|
/* FIXME: This returns a gboolean; not using (not 100% sure what to expect) -bjk 2023.06.18 */
|
||||||
|
rsvg_handle_render_document(
|
||||||
|
rsvg_handle,
|
||||||
|
cr,
|
||||||
|
&viewport,
|
||||||
|
&gerr);
|
||||||
|
/* FIXME: ignoring errors (gerr) for now -bjk 2023.06.18 */
|
||||||
|
|
||||||
cairo_surface_finish(cairo_surf);
|
cairo_surface_finish(cairo_surf);
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue