proton

MoonBit bindings for the Proton native desktop runtime.

proton
gui
web
desktop-app
moon add justjavac/proton@0.1.14
Download zip
Author
Version
0.1.14
License
Apache-2.0
Last updated
13 days ago
Downloads
177
README

justjavac/proton does not have a README file

#
NativeError

#
ProcessResult

#
RuntimeConfig

#
RuntimeEvent

#
RuntimeInfo

#
WindowConfig

#
App

type App

High-level application facade for ordinary Proton apps.

#
App::debug

fn App::debug(self : App, enabled? : Bool) -> App

Enables or disables runtime debug mode.

#
App::debug_level

fn App::debug_level(self : App, debug : Int) -> App

Sets the runtime debug level.

#
App::entry_asset

fn App::entry_asset(self : App, path : String) -> App

Overrides the primary app entry with an asset path.

#
App::entry_file

fn App::entry_file(self : App, path : String) -> App

Overrides the primary app entry with a file path.

#
App::entry_html

fn App::entry_html(self : App, html : String) -> App

Overrides the primary app entry with inline HTML.

#
App::entry_url

fn App::entry_url(self : App, url : String) -> App

Overrides the primary app entry with a URL.

#
App::extension

fn App::extension(self : App, extension :
Extension
, options? : Json) -> App

Registers one extension setting with the app facade.

The native DLL route exposes command extensions through window.__MoonBit__.core.invokeOp(...) and a generated high-level proxy for inline HTML entries.

#
App::extensions

fn App::extensions(self : App, extensions :
Extensions
) -> App

Registers a set of extension settings with the app facade.

#
App::run

async fn App::run(self : App) -> Result[Unit, String]

Runs the configured app through the native Proton runtime.

#
App::run_or_abort

async fn App::run_or_abort(self : App) -> Unit

Runs the configured app and aborts with the error message on failure.

#
App::size

fn App::size(self : App, width~ : Int, height~ : Int) -> App

Sets the primary window size.

#
App::title

fn App::title(self : App, title : String) -> App

Sets the primary window title.

#
abi_version

fn abi_version() -> Int

#
asset

fn asset(title : String, path : String, width? : Int, height? : Int, debug? : Bool, resizable? : Bool) -> App

Creates an inline asset application.

#
config

fn config(path : String) -> App

Creates an application backed by a moon.proton config file.

#
file

fn file(title : String, path : String, width? : Int, height? : Int, debug? : Bool, resizable? : Bool) -> App

Creates an inline file application.

#
html

fn html(title : String, html : String, width? : Int, height? : Int, debug? : Bool, resizable? : Bool) -> App

Creates an inline HTML application.

#
last_error_message

fn last_error_message() -> String

#
runtime_info_json

fn runtime_info_json() -> Result[String,
NativeError
]

#
url

fn url(title : String, url : String, width? : Int, height? : Int, debug? : Bool, resizable? : Bool) -> App

Creates an inline URL application.

Powered by MoonBit

Site sourceReport issuePackagesBuild queueSkillsStatistics

© 2026 mooncakes.io