Skip to content

Commit

Permalink
fix: doc is not shown for set_fallback api (#718)
Browse files Browse the repository at this point in the history
  • Loading branch information
Decodetalkers authored Apr 30, 2024
1 parent ff3b13d commit 1f6f4f5
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions wayland-cursor/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -218,15 +218,15 @@ impl CursorTheme {
///
/// For example, this defines a generic fallback cursor image and uses it for all missing cursors:
/// ```ignore
/// # use wayland_cursor::CursorTheme;
/// # use wayland_client::{Connection, backend::InvalidId, protocol::wl_shm};
/// # fn example(conn: &Connection, shm: wl_shm::WlShm, size: u32) -> Result<CursorTheme, InvalidId> {
/// # let mut theme = CursorTheme::load_or(conn, shm, "default", size)?;
/// # theme.set_callback(|name, size| {
/// # include_bytes!("./icons/default")
/// # });
/// # Ok(theme)
/// # }
/// use wayland_cursor::CursorTheme;
/// use wayland_client::{Connection, backend::InvalidId, protocol::wl_shm};
/// fn example(conn: &Connection, shm: wl_shm::WlShm, size: u32) -> Result<CursorTheme, InvalidId> {
/// let mut theme = CursorTheme::load_or(conn, shm, "default", size)?;
/// theme.set_callback(|name, size| {
/// include_bytes!("./icons/default")
/// });
/// Ok(theme)
/// }
/// ```
pub fn set_callback<F>(&mut self, fallback: F)
where
Expand Down

0 comments on commit 1f6f4f5

Please sign in to comment.