Racket Webview
1 Overview
2 Core Concepts
3 Modules
4 Typical Usage
9.1

Racket Webview🔗ℹ

Hans Dijkema <hans@dijkewijk.nl>

1 Overview🔗ℹ

Racket Webview is a class-oriented webview library built on top of a Qt-based native runtime.

The library is layered. At the lowest level a native FFI layer is used. On top of that, racket-webview provides a functional API. The class-oriented API described in this manual is built from smaller modules on top of that layer.

2 Core Concepts🔗ℹ

The library is structured around two main concepts:

  • a context, representing an isolated runtime with its own local HTTPS server

  • a window, representing a webview instance within such a context

A context manages local file serving, certificates, and settings. A window loads content, handles events, and provides access to DOM elements.

3 Modules🔗ℹ

The public API is divided into the following modules:

4 Typical Usage🔗ℹ

A typical application creates a wv-context% object and then creates one or more wv-window% objects within that context. DOM elements are retrieved using (send window element 'id), after which their state can be read or modified using the element and input wrapper classes. Interaction with the browser is handled through event callbacks and bindings.