1
1
//! C API for librsvg, based on GObject.
2
//!
3
//! The main API is in the [`handle`] module.  The other modules
4
//! have utility functions and the legacy [pixbuf-based API][pixbuf_utils].
5

            
6
#![allow(clippy::missing_safety_doc)]
7

            
8
#[rustfmt::skip]
9
pub use handle::{
10
    rsvg_error_get_type,
11
    rsvg_handle_close,
12
    rsvg_handle_flags_get_type,
13
    rsvg_handle_get_base_uri,
14
    rsvg_handle_get_dimensions,
15
    rsvg_handle_get_dimensions_sub,
16
    rsvg_handle_get_geometry_for_element,
17
    rsvg_handle_get_geometry_for_layer,
18
    rsvg_handle_get_intrinsic_dimensions,
19
    rsvg_handle_get_intrinsic_size_in_pixels,
20
    rsvg_handle_get_position_sub,
21
    rsvg_handle_has_sub,
22
    rsvg_handle_internal_set_testing,
23
    rsvg_handle_new_from_data,
24
    rsvg_handle_new_from_file,
25
    rsvg_handle_new_from_gfile_sync,
26
    rsvg_handle_new_from_stream_sync,
27
    rsvg_handle_new_with_flags,
28
    rsvg_handle_read_stream_sync,
29
    rsvg_handle_render_cairo_sub,
30
    rsvg_handle_render_element,
31
    rsvg_handle_render_document,
32
    rsvg_handle_render_layer,
33
    rsvg_handle_set_base_gfile,
34
    rsvg_handle_set_base_uri,
35
    rsvg_handle_set_dpi_x_y,
36
    rsvg_handle_set_size_callback,
37
    rsvg_handle_write,
38
};
39

            
40
#[cfg(feature = "pixbuf")]
41
pub use handle::rsvg_handle_get_pixbuf_sub;
42

            
43
pub use dpi::{rsvg_set_default_dpi, rsvg_set_default_dpi_x_y};
44

            
45
#[rustfmt::skip]
46
#[cfg(feature = "pixbuf")]
47
pub use pixbuf_utils::{
48
    rsvg_pixbuf_from_file,
49
    rsvg_pixbuf_from_file_at_max_size,
50
    rsvg_pixbuf_from_file_at_size,
51
    rsvg_pixbuf_from_file_at_zoom,
52
    rsvg_pixbuf_from_file_at_zoom_with_max,
53
};
54

            
55
#[macro_use]
56
mod messages;
57

            
58
mod dpi;
59
pub mod handle;
60

            
61
#[cfg(feature = "pixbuf")]
62
pub mod pixbuf_utils;
63
pub mod sizing;