Skip to main content

inset_embedder/
lib.rs

1//! Flutter's `dart:ui`: host traits (`Platform`, `View`) and value types
2//! (`Offset`, `Color`, `Canvas`, `Paint`, `Shadow`).
3//!
4//! The framework depends on this crate. This crate does not depend on the
5//! framework. Hosts implement [`Platform`] and [`View`], and invoke
6//! [`EmbedderClient`] on the client the start closure returns. They do not
7//! name `App`.
8
9// A test image carries a wgpu texture, and proving one `Sync` walks a type graph deeper than the
10// default limit.
11#![recursion_limit = "256"]
12
13mod caption_style;
14mod client;
15mod clipboard;
16mod composition;
17mod cue;
18mod drag_drop;
19mod file_dialogs;
20mod fonts;
21mod geometry;
22mod image;
23mod key;
24mod locale;
25mod media;
26mod menus;
27mod mouse_cursor;
28mod notifications;
29mod opener;
30mod painting;
31mod paragraph;
32mod platform;
33mod pointer;
34mod pointer_data_packet_converter;
35mod pointer_report;
36mod restoration;
37mod scene;
38mod system_context_menu;
39#[cfg(feature = "test-support")]
40pub mod test_support;
41mod text;
42mod text_editing;
43mod text_input;
44mod views;
45mod vsync;
46mod window;
47
48pub use caption_style::{
49    CaptionBehavior, CaptionSetting, CaptionSettings, CaptionStyle, CaptionTypeface,
50    GenericCaptionFont,
51};
52pub use client::EmbedderClient;
53pub use clipboard::{
54    Clipboard, ClipboardError, ClipboardEvent, ClipboardItem, ClipboardItemsFuture,
55    ClipboardReadFuture, ClipboardWriteFuture, Content, ContentFuture, CopyOptions, CopyRequest,
56    DataTransferItem, FileSink, URI_LIST, WriteFuture,
57};
58pub use composition::{CompositionLayer, Compositor, HardwareBuffer};
59pub use cue::{
60    Cue, CueAnchor, CueContent, CueImage, CueLine, CueTextAlignment, CueTextEdge, CueTextRun,
61    CueVertical,
62};
63pub use drag_drop::{DragChange, DragReport, DraggedItems};
64pub use file_dialogs::{
65    EntryKind, FileDialogError, FileDialogFuture, FileDialogs, FileFinishFuture, FileHandle,
66    FileOpenFuture, FileReadFuture, FileSizeFuture, FileStream, FileType, FileWriteFuture,
67    FileWriter, FolderEntriesFuture, FolderEntry, FolderHandle, FolderOptions, OpenOptions,
68    PickedFile, PickedFolder, SaveOptions,
69};
70pub use fonts::{
71    FontCollection, FontDemand, FontId, FontManager, FontSource, SystemFontSource, Typeface,
72    default_font_families, set_default_font_manager,
73};
74pub use geometry::*;
75pub use image::{
76    ImageCodec, ImageCodecFuture, ImageDecodeError, ImageFrame, ImageFrameFuture, ImageRepetition,
77};
78pub use key::{KeyData, KeyEventDeviceType, KeyEventType};
79pub use locale::Locale;
80pub use media::{
81    Camera, CameraDevice, CameraError, CameraFacing, CameraFormat, CameraId, CameraInterruption,
82    CameraListFuture, CameraOpenFuture, CameraOutputs, CameraStartFuture, Cameras, CaptureSession,
83    CaptureState, EncodedImage, MediaChangeFuture, MediaError, MediaMetadata, MediaPlayer,
84    MediaTrack, MediaTrackKind, MovieOptions, PauseReason, Photo, PhotoFuture, PlayerActivity,
85    PlayerError, PlayerErrorKind, PlayerState, PlayerStatus, Players, RecordingFuture,
86    SeekTolerance, TimeRange, VideoFrame, VideoFrameReader, VideoFrameReaders, VideoOutput,
87    WaitReason,
88};
89pub use menus::{
90    AttachedMenu, CheckState, DockMenu, EditCommand, IconImage, MenuAtIcon, MenuBar, MenuEntry,
91    MenuId, MenuItem, MenuItemCheck, MenuShortcut, PopupMenuFuture, PopupMenus, ProvidedItem,
92    ShortcutModifiers, TrayIcon, TrayIconError, TrayIconEvent, TrayIconFuture, TrayIconId,
93    TrayIcons,
94};
95pub use mouse_cursor::SystemMouseCursorKind;
96pub use notifications::{
97    Notification, NotificationAction, NotificationActivation, NotificationError,
98    NotificationPermission, NotificationReplies, NotificationScheduling, Notifications,
99    PermissionFuture, PermissionState, PostFuture,
100};
101pub use opener::{OpenError, OpenFuture, OpenRequest, Opener, file_uri_path};
102pub use painting::*;
103pub use paragraph::*;
104pub use platform::{
105    AppExit, AppExitReply, AppExitResponse, AppExitType, AppLifecycleState,
106    ApplicationSwitcherDescription, Brightness, Dispatcher, Frame, HapticFeedbackType, Haptics,
107    InertDispatcher, InertPlatform, Platform, PlatformRef, Restoration, Screen, ScreenId, Screens,
108    SystemChrome, SystemContextMenu, SystemUiOverlayStyle, TargetPlatform, TextServices, ViewRef,
109};
110pub use pointer::{
111    PointerChange, PointerData, PointerDataPacket, PointerDeviceKind, PointerSignalKind,
112};
113pub use pointer_data_packet_converter::PointerDataPacketConverter;
114pub use pointer_report::{Contact, PointerReport, ReportedChange};
115pub use restoration::{RestorationData, RestorationMap, RestorationUpdate};
116pub use scene::{
117    ContainerLayer, DisplayListLayer, Effect, EmbeddedLayer, EngineLayer, Layer, Mutator, Part,
118    Placement, Scene, SceneBuilder, Slices, VideoLayer, slices,
119};
120pub use system_context_menu::SystemContextMenuItem;
121pub use text::*;
122pub use text_editing::*;
123pub use text_input::*;
124pub use views::{
125    GestureSettings, TextInputHost, View, ViewConstraints, ViewEmbedder, ViewFocusDirection,
126    ViewFocusEvent, ViewFocusState, ViewHost, ViewId, ViewMetrics, ViewPadding,
127};
128pub use vsync::{VsyncObserver, VsyncWaiter};
129pub use web_time::Instant;
130pub use window::{
131    HostWindow, RawWindowHandle, RequestId, ViewError, WindowBackground, WindowConfig, WindowLevel,
132    WindowRef,
133};