iced-yoda/native/src/lib.rs

62 lines
2.1 KiB
Rust
Raw Normal View History

//! A renderer-agnostic native GUI runtime.
2019-09-20 19:15:31 +02:00
//!
//! ![`iced_native` crate graph](https://github.com/hecrj/iced/blob/cae26cb7bc627f4a5b3bcf1cd023a0c552e8c65e/docs/graphs/native.png?raw=true)
2019-09-20 19:15:31 +02:00
//!
//! `iced_native` takes [`iced_core`] and builds a native runtime on top of it,
//! featuring:
2019-09-20 19:15:31 +02:00
//!
//! - A custom layout engine, greatly inspired by [`druid`]
//! - Event handling for all the built-in widgets
//! - A renderer-agnostic API
2019-09-20 19:15:31 +02:00
//!
//! To achieve this, it introduces a bunch of reusable interfaces:
2019-09-20 19:15:31 +02:00
//!
//! - A [`Widget`] trait, which is used to implement new widgets: from layout
//! requirements to event and drawing logic.
//! - A bunch of `Renderer` traits, meant to keep the crate renderer-agnostic.
//! - A [`Windowed`] trait, leveraging [`raw-window-handle`], which can be
//! implemented by graphical renderers that target _windows_. Window-based
//! shells (like [`iced_winit`]) can use this trait to stay renderer-agnostic.
2019-09-20 19:15:31 +02:00
//!
//! # Usage
2019-09-20 19:15:31 +02:00
//! Check out the [`UserInterface`] type to learn how to wire everything up!
//!
//! [`iced_core`]: https://github.com/hecrj/iced/tree/master/core
//! [`iced_winit`]: https://github.com/hecrj/iced/tree/master/winit
//! [`druid`]: https://github.com/xi-editor/druid
//! [`raw-window-handle`]: https://github.com/rust-windowing/raw-window-handle
//! [`Widget`]: widget/trait.Widget.html
//! [`Windowed`]: renderer/trait.Windowed.html
2019-09-20 19:15:31 +02:00
//! [`UserInterface`]: struct.UserInterface.html
#![deny(missing_docs)]
//#![deny(missing_debug_implementations)]
2019-09-20 19:15:31 +02:00
#![deny(unused_results)]
#![deny(unsafe_code)]
#![deny(rust_2018_idioms)]
pub mod input;
2019-11-10 01:55:32 +01:00
pub mod layout;
2019-09-20 19:15:31 +02:00
pub mod renderer;
pub mod widget;
mod element;
mod event;
mod hasher;
mod mouse_cursor;
mod size;
2019-09-20 19:15:31 +02:00
mod user_interface;
pub use iced_core::{
Align, Background, Color, Command, Font, HorizontalAlignment, Length,
Point, Rectangle, Vector, VerticalAlignment,
};
2019-09-20 19:15:31 +02:00
pub use element::Element;
pub use event::Event;
pub use hasher::Hasher;
pub use layout::Layout;
pub use mouse_cursor::MouseCursor;
pub use renderer::Renderer;
pub use size::Size;
2019-09-20 19:15:31 +02:00
pub use user_interface::{Cache, UserInterface};
pub use widget::*;