MCPcopy Index your code
hub / github.com/TheRedDeveloper/ply-engine

github.com/TheRedDeveloper/ply-engine @1.1.0

Chat with this repo
repository ↗ · DeepWiki ↗ · release 1.1.0 ↗ · + Follow
1,026 symbols 3,368 edges 33 files 315 documented · 31%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Ply

Beautiful UIs in Rust. Cross-platform. Dead simple.

Website · Docs · Examples

crates.io License: 0BSD


Ply is an engine for building apps in Rust that run on Linux, macOS, Windows, Android, iOS, and the web. One codebase, every platform. GPU-accelerated rendering, text editing, styling, accessibility, shaders, networking, sound and more, made easy and fast.

cargo install plyx
plyx init

What you get

ui.element().width(grow!()).height(grow!())
  .background_color(0x262220)
  .corner_radius(12.0)
  .layout(|l| l.direction(TopToBottom).padding(24))
  .children(|ui| {
    ui.text("Hello, Ply!", |t| t.font_size(32).color(0xFFFFFF));
  });

Everything is an element. Builder pattern, closure-based children, one import. Read the docs →

Highlights

  • Layout engine: Flexbox-like sizing, padding, gaps, alignment, scrolling, floating elements
  • Text input: Cursor, selection, undo/redo, multiline, password mode, keyboard shortcuts
  • Rich text styling: Inline colors, wave, pulse, gradient, typewriter, fade, works in inputs too
  • Shaders: GLSL fragment shaders, built-in effects, SPIR-V build pipeline
  • Accessibility: AccessKit on desktop, JS bridge on web. Screen readers, keyboard nav, focus rings, tab order, live regions
  • Debug view: Chrome DevTools-style inspector. One line: ply.set_debug_mode(true)
  • Networking: HTTP + WebSocket, polling-based, never blocks the UI, works everywhere
  • Images & vectors: PNG, TinyVG vectors, render_to_texture, procedural vectors
  • Rotation: Visual (children included) and shape (vertex-level)
  • Sound: WAV/OGG playback, volume control, looping
  • Interactivity: ui.hovered(), ui.pressed(), ui.focused() inline, callback events, ID-based queries

Platforms

Platform Build command
Desktop (Linux, macOS, Windows) cargo build
Web (WASM) plyx web
Android plyx apk
iOS plyx ios

Feature flags

Feature What it adds
a11y Screen reader support via AccessKit (default)
text-styling Rich text with inline colors, animations, effects
tinyvg TinyVG vector graphics
built-in-shaders Pre-made shader effects (foil, glow, CRT, etc.)
shader-build Shader compilation pipeline (SPIR-V Cross)
net HTTP and WebSocket
net-json JSON deserialization for network responses
storage Cross-platform persistent file storage
audio Sound playback (WAV, OGG)

Examples

See the interactive examples on the website:

  • Shader Playground (207 lines): live GLSL editor with code highlighting
  • Snake (295 lines)
  • Todo List (242 lines)

License

Zero-Clause BSD. Use it for anything. No attribution required.

Extension points exported contracts — how you extend this code

Lerp (Interface)
Linear interpolation trait. [7 implementers]
src/lerp.rs

Core symbols most depended-on inside this repo

debug_text
called by 192
src/engine.rs
clone
called by 143
src/engine.rs
get
called by 142
src/renderer.rs
is_empty
called by 81
src/id.rs
close_element
called by 81
src/engine.rs
width
called by 78
src/lib.rs
height
called by 78
src/lib.rs
element
called by 77
src/lib.rs

Shape

Function 445
Method 443
Class 103
Enum 34
Interface 1

Languages

Rust94%
TypeScript6%
Java1%

Modules by API surface

src/text_input.rs209 symbols
src/engine.rs171 symbols
src/lib.rs117 symbols
src/renderer.rs53 symbols
src/elements.rs45 symbols
src/text_styling.rs41 symbols
js/ply_bundle.js39 symbols
src/accessibility.rs38 symbols
src/shader_build.rs30 symbols
src/easing.rs30 symbols
src/accessibility_native.rs30 symbols
src/layout.rs24 symbols

For agents

$ claude mcp add ply-engine \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact