### ImageMagick version

7.1.1-25

### Operating system

Linux

### Operating system, version and so on

Ubuntu 22.04

### Description

Upon compiling with librsvg installed, I'm seeing a number of warnings of deprecated functions that are used in [coders/svg.c](https://github.com/ImageMagick/ImageMagick/blob/main/coders/svg.c), such as

* `rsvg_handle_write`: deprecated in librsvg 2.46
  https://github.com/GNOME/librsvg/blob/8b021170b46fd8854a0e22772c4a944804b15706/include/librsvg/rsvg.h#L571
  * called in [coders/svg.c:444:5](https://github.com/ImageMagick/ImageMagick/blob/570a9a048bb0e3a5c221ca87be9408ae35f711e2/coders/svg.c#L443), use `rsvg_handle_read_stream_sync` instead
* `rsvg_handle_close`: deprecated in librsvg 2.46
  https://github.com/GNOME/librsvg/blob/8b021170b46fd8854a0e22772c4a944804b15706/include/librsvg/rsvg.h#L601
  * called in [coders/svg.c:450:3](https://github.com/ImageMagick/ImageMagick/blob/570a9a048bb0e3a5c221ca87be9408ae35f711e2/coders/svg.c#L452), use `rsvg_handle_read_stream_sync` instead
* `rsvg_handle_get_dimensions`: deprecated in librsvg 2.52
  https://github.com/GNOME/librsvg/blob/8b021170b46fd8854a0e22772c4a944804b15706/include/librsvg/rsvg.h#L701
  * called in [coders/svg.c:455:3](https://github.com/ImageMagick/ImageMagick/blob/570a9a048bb0e3a5c221ca87be9408ae35f711e2/coders/svg.c#L461)
  * and in [coders/svg.c:467:7](https://github.com/ImageMagick/ImageMagick/blob/570a9a048bb0e3a5c221ca87be9408ae35f711e2/coders/svg.c#L473), use `rsvg_handle_get_intrinsic_size_in_pixels` instead
* `rsvg_handle_render_cairo`: deprecated in librsvg 2.52
  https://github.com/GNOME/librsvg/blob/8b021170b46fd8854a0e22772c4a944804b15706/include/librsvg/rsvg-cairo.h#L86
  * called in [coders/svg.c:569:7](https://github.com/ImageMagick/ImageMagick/blob/570a9a048bb0e3a5c221ca87be9408ae35f711e2/coders/svg.c#L574), use `rsvg_handle_render_document` instead

_(Permalinks to `coders/svg.c` included here refer to the main branch, so are a couple lines off compared to the lines indicated in the build results.)_



### Steps to Reproduce

1) Install latest `librsvg2-dev` on Ubuntu 22.04 "jammy" (currently [2.52.5](https://packages.ubuntu.com/jammy/librsvg2-dev))
2) compile ImageMagick 7.1.1-25 with `--with-rsvg` flag
```console
coders/svg.c: In function 'RenderRSVGImage':
coders/svg.c:444:5: warning: 'rsvg_handle_write' is deprecated: Use 'rsvg_handle_read_stream_sync' instead [-Wdeprecated-declarations]
  444 |     (void) rsvg_handle_write(svg_handle,buffer,(gsize) n,&error);
      |     ^
In file included from coders/svg.c:92:
/usr/include/librsvg-2.0/librsvg/rsvg.h:602:10: note: declared here
  602 | gboolean rsvg_handle_write (RsvgHandle   *handle,
      |          ^~~~~~~~~~~~~~~~~
coders/svg.c:450:3: warning: 'rsvg_handle_close' is deprecated: Use 'rsvg_handle_read_stream_sync' instead [-Wdeprecated-declarations]
  450 |   rsvg_handle_close(svg_handle,&error);
      |   ^~~~~~~~~~~~~~~~~
In file included from coders/svg.c:92:
/usr/include/librsvg-2.0/librsvg/rsvg.h:630:10: note: declared here
  630 | gboolean rsvg_handle_close (RsvgHandle *handle, GError **error);
      |          ^~~~~~~~~~~~~~~~~
coders/svg.c:455:3: warning: 'rsvg_handle_get_dimensions' is deprecated: Use 'rsvg_handle_get_intrinsic_size_in_pixels' instead [-Wdeprecated-declarations]
  455 |   rsvg_handle_get_dimensions(svg_handle,&dimension_info);
      |   ^~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from coders/svg.c:92:
/usr/include/librsvg-2.0/librsvg/rsvg.h:731:6: note: declared here
  731 | void rsvg_handle_get_dimensions (RsvgHandle *handle, RsvgDimensionData *dimension_data);
      |      ^~~~~~~~~~~~~~~~~~~~~~~~~~
coders/svg.c:467:7: warning: 'rsvg_handle_get_dimensions' is deprecated: Use 'rsvg_handle_get_intrinsic_size_in_pixels' instead [-Wdeprecated-declarations]
  467 |       rsvg_handle_get_dimensions(svg_handle,&dpi_dimension_info);
      |       ^~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from coders/svg.c:92:
/usr/include/librsvg-2.0/librsvg/rsvg.h:731:6: note: declared here
  731 | void rsvg_handle_get_dimensions (RsvgHandle *handle, RsvgDimensionData *dimension_data);
      |      ^~~~~~~~~~~~~~~~~~~~~~~~~~
coders/svg.c:569:7: warning: 'rsvg_handle_render_cairo' is deprecated: Use 'rsvg_handle_render_document' instead [-Wdeprecated-declarations]
  569 |       rsvg_handle_render_cairo(svg_handle,cairo_image);
      |       ^~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/librsvg-2.0/librsvg/rsvg.h:1464,
                 from coders/svg.c:92:
/usr/include/librsvg-2.0/librsvg/rsvg-cairo.h:95:10: note: declared here
   95 | gboolean rsvg_handle_render_cairo (RsvgHandle *handle, cairo_t *cr);
      |          ^~~~~~~~~~~~~~~~~~~~~~~~
```
### Images

_No response_
fix deprecated rsvg functions
This is a GitHub Issue
repo:ImageMagick
owner:ImageMagick
Title : fix deprecated rsvg functions
Issue date:

--- start body ---
### ImageMagick version

7.1.1-25

### Operating system

Linux

### Operating system, version and so on

Ubuntu 22.04

### Description

Upon compiling with librsvg installed, I'm seeing a number of warnings of deprecated functions that are used in [coders/svg.c](https://github.com/ImageMagick/ImageMagick/blob/main/coders/svg.c), such as

* `rsvg_handle_write`: deprecated in librsvg 2.46
  https://github.com/GNOME/librsvg/blob/8b021170b46fd8854a0e22772c4a944804b15706/include/librsvg/rsvg.h#L571
  * called in [coders/svg.c:444:5](https://github.com/ImageMagick/ImageMagick/blob/570a9a048bb0e3a5c221ca87be9408ae35f711e2/coders/svg.c#L443), use `rsvg_handle_read_stream_sync` instead
* `rsvg_handle_close`: deprecated in librsvg 2.46
  https://github.com/GNOME/librsvg/blob/8b021170b46fd8854a0e22772c4a944804b15706/include/librsvg/rsvg.h#L601
  * called in [coders/svg.c:450:3](https://github.com/ImageMagick/ImageMagick/blob/570a9a048bb0e3a5c221ca87be9408ae35f711e2/coders/svg.c#L452), use `rsvg_handle_read_stream_sync` instead
* `rsvg_handle_get_dimensions`: deprecated in librsvg 2.52
  https://github.com/GNOME/librsvg/blob/8b021170b46fd8854a0e22772c4a944804b15706/include/librsvg/rsvg.h#L701
  * called in [coders/svg.c:455:3](https://github.com/ImageMagick/ImageMagick/blob/570a9a048bb0e3a5c221ca87be9408ae35f711e2/coders/svg.c#L461)
  * and in [coders/svg.c:467:7](https://github.com/ImageMagick/ImageMagick/blob/570a9a048bb0e3a5c221ca87be9408ae35f711e2/coders/svg.c#L473), use `rsvg_handle_get_intrinsic_size_in_pixels` instead
* `rsvg_handle_render_cairo`: deprecated in librsvg 2.52
  https://github.com/GNOME/librsvg/blob/8b021170b46fd8854a0e22772c4a944804b15706/include/librsvg/rsvg-cairo.h#L86
  * called in [coders/svg.c:569:7](https://github.com/ImageMagick/ImageMagick/blob/570a9a048bb0e3a5c221ca87be9408ae35f711e2/coders/svg.c#L574), use `rsvg_handle_render_document` instead

_(Permalinks to `coders/svg.c` included here refer to the main branch, so are a couple lines off compared to the lines indicated in the build results.)_



### Steps to Reproduce

1) Install latest `librsvg2-dev` on Ubuntu 22.04 "jammy" (currently [2.52.5](https://packages.ubuntu.com/jammy/librsvg2-dev))
2) compile ImageMagick 7.1.1-25 with `--with-rsvg` flag
```console
coders/svg.c: In function 'RenderRSVGImage':
coders/svg.c:444:5: warning: 'rsvg_handle_write' is deprecated: Use 'rsvg_handle_read_stream_sync' instead [-Wdeprecated-declarations]
  444 |     (void) rsvg_handle_write(svg_handle,buffer,(gsize) n,&error);
      |     ^
In file included from coders/svg.c:92:
/usr/include/librsvg-2.0/librsvg/rsvg.h:602:10: note: declared here
  602 | gboolean rsvg_handle_write (RsvgHandle   *handle,
      |          ^~~~~~~~~~~~~~~~~
coders/svg.c:450:3: warning: 'rsvg_handle_close' is deprecated: Use 'rsvg_handle_read_stream_sync' instead [-Wdeprecated-declarations]
  450 |   rsvg_handle_close(svg_handle,&error);
      |   ^~~~~~~~~~~~~~~~~
In file included from coders/svg.c:92:
/usr/include/librsvg-2.0/librsvg/rsvg.h:630:10: note: declared here
  630 | gboolean rsvg_handle_close (RsvgHandle *handle, GError **error);
      |          ^~~~~~~~~~~~~~~~~
coders/svg.c:455:3: warning: 'rsvg_handle_get_dimensions' is deprecated: Use 'rsvg_handle_get_intrinsic_size_in_pixels' instead [-Wdeprecated-declarations]
  455 |   rsvg_handle_get_dimensions(svg_handle,&dimension_info);
      |   ^~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from coders/svg.c:92:
/usr/include/librsvg-2.0/librsvg/rsvg.h:731:6: note: declared here
  731 | void rsvg_handle_get_dimensions (RsvgHandle *handle, RsvgDimensionData *dimension_data);
      |      ^~~~~~~~~~~~~~~~~~~~~~~~~~
coders/svg.c:467:7: warning: 'rsvg_handle_get_dimensions' is deprecated: Use 'rsvg_handle_get_intrinsic_size_in_pixels' instead [-Wdeprecated-declarations]
  467 |       rsvg_handle_get_dimensions(svg_handle,&dpi_dimension_info);
      |       ^~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from coders/svg.c:92:
/usr/include/librsvg-2.0/librsvg/rsvg.h:731:6: note: declared here
  731 | void rsvg_handle_get_dimensions (RsvgHandle *handle, RsvgDimensionData *dimension_data);
      |      ^~~~~~~~~~~~~~~~~~~~~~~~~~
coders/svg.c:569:7: warning: 'rsvg_handle_render_cairo' is deprecated: Use 'rsvg_handle_render_document' instead [-Wdeprecated-declarations]
  569 |       rsvg_handle_render_cairo(svg_handle,cairo_image);
      |       ^~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/librsvg-2.0/librsvg/rsvg.h:1464,
                 from coders/svg.c:92:
/usr/include/librsvg-2.0/librsvg/rsvg-cairo.h:95:10: note: declared here
   95 | gboolean rsvg_handle_render_cairo (RsvgHandle *handle, cairo_t *cr);
      |          ^~~~~~~~~~~~~~~~~~~~~~~~
```
### Images

_No response_
--- end body ---
