Fix InputMethod::merge example in documentation

This commit is contained in:
Héctor Ramón Jiménez 2025-11-25 22:37:44 +01:00
parent 2804aff5b2
commit 71061b53bb
No known key found for this signature in database
GPG key ID: 7CC46565708259A7

View file

@ -87,16 +87,16 @@ impl InputMethod {
/// Merges two [`InputMethod`] strategies, prioritizing the first one when both open: /// Merges two [`InputMethod`] strategies, prioritizing the first one when both open:
/// ``` /// ```
/// # use iced_core::input_method::{InputMethod, Purpose, Preedit}; /// # use iced_core::input_method::{InputMethod, Purpose, Preedit};
/// # use iced_core::Point; /// # use iced_core::{Point, Rectangle, Size};
/// ///
/// let open = InputMethod::Enabled { /// let open = InputMethod::Enabled {
/// position: Point::ORIGIN, /// cursor: Rectangle::new(Point::ORIGIN, Size::UNIT),
/// purpose: Purpose::Normal, /// purpose: Purpose::Normal,
/// preedit: Some(Preedit { content: "1".to_owned(), selection: None, text_size: None }), /// preedit: Some(Preedit { content: "1".to_owned(), selection: None, text_size: None }),
/// }; /// };
/// ///
/// let open_2 = InputMethod::Enabled { /// let open_2 = InputMethod::Enabled {
/// position: Point::ORIGIN, /// cursor: Rectangle::new(Point::ORIGIN, Size::UNIT),
/// purpose: Purpose::Secure, /// purpose: Purpose::Secure,
/// preedit: Some(Preedit { content: "2".to_owned(), selection: None, text_size: None }), /// preedit: Some(Preedit { content: "2".to_owned(), selection: None, text_size: None }),
/// }; /// };