2022-12-06 16:12:59 +01:00
|
|
|
// Copyright 2022 System76 <info@system76.com>
|
|
|
|
|
// SPDX-License-Identifier: MPL-2.0
|
|
|
|
|
|
2022-12-23 15:10:13 +01:00
|
|
|
#![allow(clippy::module_name_repetitions)]
|
2024-08-26 13:22:04 -06:00
|
|
|
#![cfg_attr(target_os = "redox", feature(lazy_cell))]
|
2022-12-23 15:10:13 +01:00
|
|
|
|
2023-09-01 07:25:23 +02:00
|
|
|
/// Recommended default imports.
|
|
|
|
|
pub mod prelude {
|
2024-10-16 20:36:46 -04:00
|
|
|
#[cfg(feature = "winit")]
|
2023-10-02 17:51:33 +02:00
|
|
|
pub use crate::ApplicationExt;
|
2025-03-21 13:33:07 +01:00
|
|
|
pub use crate::ext::*;
|
2025-03-14 11:56:21 -04:00
|
|
|
pub use crate::{Also, Apply, Element, Renderer, Task, Theme};
|
2023-09-01 07:25:23 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
pub use apply::{Also, Apply};
|
|
|
|
|
|
2025-03-14 11:56:21 -04:00
|
|
|
/// Actions are managed internally by the cosmic runtime.
|
|
|
|
|
pub mod action;
|
|
|
|
|
pub use action::Action;
|
|
|
|
|
|
2026-02-19 18:15:22 -05:00
|
|
|
pub mod anim;
|
|
|
|
|
|
2024-10-16 20:36:46 -04:00
|
|
|
#[cfg(feature = "winit")]
|
2023-08-02 11:54:07 +02:00
|
|
|
pub mod app;
|
2024-10-16 20:36:46 -04:00
|
|
|
#[cfg(feature = "winit")]
|
2025-03-14 11:56:21 -04:00
|
|
|
#[doc(inline)]
|
2023-08-02 11:54:07 +02:00
|
|
|
pub use app::{Application, ApplicationExt};
|
|
|
|
|
|
2023-09-18 07:45:11 +02:00
|
|
|
#[cfg(feature = "applet")]
|
|
|
|
|
pub mod applet;
|
|
|
|
|
|
2025-03-14 11:56:21 -04:00
|
|
|
pub mod command;
|
|
|
|
|
|
|
|
|
|
/// State which is managed by the cosmic runtime.
|
|
|
|
|
pub mod core;
|
|
|
|
|
#[doc(inline)]
|
|
|
|
|
pub use core::Core;
|
2024-03-05 16:05:33 +01:00
|
|
|
|
|
|
|
|
pub mod config;
|
|
|
|
|
|
2024-05-20 17:19:42 +02:00
|
|
|
#[doc(inline)]
|
2023-05-30 12:03:15 -04:00
|
|
|
pub use cosmic_config;
|
2024-05-20 17:19:42 +02:00
|
|
|
|
|
|
|
|
#[doc(inline)]
|
2023-02-27 19:23:02 -05:00
|
|
|
pub use cosmic_theme;
|
2023-08-02 11:54:07 +02:00
|
|
|
|
2025-03-14 11:56:21 -04:00
|
|
|
#[cfg(feature = "single-instance")]
|
|
|
|
|
pub mod dbus_activation;
|
|
|
|
|
#[cfg(feature = "single-instance")]
|
|
|
|
|
pub use dbus_activation::DbusActivation;
|
|
|
|
|
|
2025-02-12 18:30:32 +01:00
|
|
|
#[cfg(feature = "desktop")]
|
|
|
|
|
pub mod desktop;
|
|
|
|
|
|
2024-01-22 08:08:45 +01:00
|
|
|
#[cfg(any(feature = "xdg-portal", feature = "rfd"))]
|
2023-08-15 10:58:46 +02:00
|
|
|
pub mod dialog;
|
|
|
|
|
|
2023-08-02 11:54:07 +02:00
|
|
|
pub mod executor;
|
|
|
|
|
#[cfg(feature = "tokio")]
|
|
|
|
|
pub use executor::single::Executor as SingleThreadExecutor;
|
|
|
|
|
|
|
|
|
|
mod ext;
|
|
|
|
|
|
|
|
|
|
pub mod font;
|
|
|
|
|
|
2024-05-20 17:19:42 +02:00
|
|
|
#[doc(inline)]
|
2022-09-30 09:35:55 -06:00
|
|
|
pub use iced;
|
2024-05-20 17:19:42 +02:00
|
|
|
|
|
|
|
|
#[doc(inline)]
|
2023-06-01 16:12:57 -06:00
|
|
|
pub use iced_core;
|
2024-05-20 17:19:42 +02:00
|
|
|
|
|
|
|
|
#[doc(inline)]
|
2023-06-01 16:12:57 -06:00
|
|
|
pub use iced_futures;
|
2024-05-20 17:19:42 +02:00
|
|
|
|
|
|
|
|
#[doc(inline)]
|
2023-06-01 16:12:57 -06:00
|
|
|
pub use iced_renderer;
|
2024-05-20 17:19:42 +02:00
|
|
|
|
|
|
|
|
#[doc(inline)]
|
2023-05-30 12:03:15 -04:00
|
|
|
pub use iced_runtime;
|
2024-05-20 17:19:42 +02:00
|
|
|
|
|
|
|
|
#[doc(inline)]
|
2023-05-30 12:03:15 -04:00
|
|
|
pub use iced_widget;
|
2024-05-20 17:19:42 +02:00
|
|
|
|
|
|
|
|
#[doc(inline)]
|
2022-11-15 23:11:48 +01:00
|
|
|
#[cfg(feature = "winit")]
|
2022-10-07 05:20:06 +02:00
|
|
|
pub use iced_winit;
|
2023-08-02 11:54:07 +02:00
|
|
|
|
2024-06-10 09:43:14 -06:00
|
|
|
#[doc(inline)]
|
|
|
|
|
#[cfg(feature = "wgpu")]
|
|
|
|
|
pub use iced_wgpu;
|
|
|
|
|
|
2023-08-02 11:54:07 +02:00
|
|
|
pub mod icon_theme;
|
2023-01-10 13:58:13 +01:00
|
|
|
pub mod keyboard_nav;
|
2022-09-30 09:35:55 -06:00
|
|
|
|
2025-09-05 18:50:25 +02:00
|
|
|
mod localize;
|
|
|
|
|
|
2025-05-29 00:40:06 -04:00
|
|
|
#[cfg(all(target_env = "gnu", not(target_os = "windows")))]
|
2025-02-12 18:30:32 +01:00
|
|
|
pub(crate) mod malloc;
|
|
|
|
|
|
2024-12-26 12:14:41 +01:00
|
|
|
#[cfg(all(feature = "process", not(windows)))]
|
2023-11-14 16:55:06 -05:00
|
|
|
pub mod process;
|
|
|
|
|
|
2023-08-02 11:54:07 +02:00
|
|
|
#[cfg(feature = "wayland")]
|
2023-11-14 16:55:06 -05:00
|
|
|
pub use cctk;
|
2023-01-18 15:09:55 -08:00
|
|
|
|
2025-03-14 11:56:21 -04:00
|
|
|
pub mod surface;
|
|
|
|
|
|
|
|
|
|
pub use iced::Task;
|
|
|
|
|
pub mod task;
|
|
|
|
|
|
2023-08-02 11:54:07 +02:00
|
|
|
pub mod theme;
|
2024-05-20 17:19:42 +02:00
|
|
|
|
2025-10-13 13:59:45 -07:00
|
|
|
pub mod scroll;
|
|
|
|
|
|
2024-05-20 17:19:42 +02:00
|
|
|
#[doc(inline)]
|
2025-03-21 13:33:07 +01:00
|
|
|
pub use theme::{Theme, style};
|
2023-01-05 14:16:27 +01:00
|
|
|
|
2023-08-02 11:54:07 +02:00
|
|
|
pub mod widget;
|
2024-10-16 20:36:46 -04:00
|
|
|
type Plain = iced_core::text::paragraph::Plain<<Renderer as iced_core::text::Renderer>::Paragraph>;
|
2023-11-30 14:01:42 -05:00
|
|
|
type Paragraph = <Renderer as iced_core::text::Renderer>::Paragraph;
|
2024-01-30 22:14:00 -05:00
|
|
|
pub type Renderer = iced::Renderer;
|
|
|
|
|
pub type Element<'a, Message> = iced::Element<'a, Message, crate::Theme, Renderer>;
|