Crate puppeteer

Source
Expand description

Puppeteer crates.io Docs Rust

A Minimal Dependency and Easy to Use GUI Creator in Rust using Async Channels

Re-exports§

pub use arrayvec;
pub use async_trait;
pub use smol;
pub use thiserror;
pub use tracing;
pub use wry;

Macros§

asset
Include asset bytes at compile time
assets
Include asset bytes at compile time from an absolute path
assets_from_manifest_dir
Include asset bytes at compile time but load the path from the manifest directory
items_counter
Count the number of items inside a macro
load_cow
Load strings within a Clone-on-Write with a 'static lifetime styles
load_strs
Load static strings
static_str
Include asset in UTF-8 format at compile time

Structs§

ActiveAppEnv
Environment variables set when the app is initialized
AppEnvironment
The environment the app is running on. This includes the Operating System and other supported environment variables
AssetFile
An asset to be used in the app
AssetFileLoader
Default resource file size is 1MiB
ColorPalette
This is the color palette of the app
ContextMenu
This provides the context menu builder
Logging
Custom logging handler for Puppeteer apps. Text filtering can be done by searching for [app_title]»
PuppeteerApp
This struct us used to build your app
Shell
The Shell of the app contains all the imports like fonts, styles and scripts
StaticAsset
An asset that has a static lifetime
TitleBar
This is helper function to create a title bar for the app
TitleBarCSS
Create CSS for the title bar based on the color palette

Enums§

CpuArchitecture
What is the architecture of the CPU that the app is running on
DynLibExtension
The extension used by the shared libraries on the Operating System the app is running on
DynLibPrefix
The extension used by the shared libraries on the Operating System the app is running on.
ModifyView
Used to modify the view which can be a WebView
OsFamily
Check if operating system is Unix-like or Microsoft Windows based
OsType
The type of operating system the Window is running on
PuppeteerError
The error type for Puppeteer
Theme
Whether it is a dark or light theme or whether it will respect system settings
UiEvent
Event Handler for Puppeteer
WindowResize
An window resize operation

Constants§

BUFFER_CAPACITY
The buffer capacity of a bufreader
DEFAULT_RESOURCE_SIZE
The default resource size set to avoid high memory usage and data
DEFAULT_WINDOW_ACTIONS
The default minimize, maximize and close buttons
DEFAULT_WINDOW_ACTIONS_SCRIPT
The default styles for the default window actions as defined by DEFAULT_WINDOW_ACTIONS const
DEFAULT_WINDOW_ACTIONS_STYLE
The default styles for the default window actions as defined by DEFAULT_WINDOW_ACTIONS const
LOGGING_SYMBOL
Name that can be used to quickly identify all filters of the running app in logs.
PUPPETEER_APP_ELEMENT
The HTML element where all the app body will be injected
TITLE_BAR_SCRIPT
The default script to use when a drag event is done on the title bar

Traits§

AssetProperties
Methods to detect file type and convert to encoding formats like base64
Puppeteer
This trait is used to perform UI operations like parsing the IPC messages and generating content to be displayed
StaticAssetProperties
Methods to detect file type and convert to encoding formats like base64
UiPaint
Trait that ensures a type can be converted to code that can be rendered into current view

Type Aliases§

CowStr
A type that defines [Cow<’p, str>] for easier reuse
JsCallback
The callback used to modify a node based on the result of computation of it’s text content
PuppeteerResult
A wrapper to Result<T, PuppeteerError>
StaticCowStr
A type that defines [Cow<’static, str>] for easier reuse
StaticStr
A type of &’static str