README

mizchi/kagura_engine/platform does not have a README file

#
PlatformDriver

pub trait PlatformDriver {
fn initialize(Self, options : WindowOptions) -> Unit raise
fn poll_events(Self) -> Unit
fn should_close(Self) -> Bool
fn outside_size(Self) ->
OutsideSize

fn capture_input(Self, tick : Int) ->
InputSnapshot

fn monitor_info(Self) -> MonitorInfo
fn set_fullscreen(Self, enabled : Bool) -> Unit
fn is_fullscreen(Self) -> Bool
fn set_cursor_mode(Self, mode : CursorMode) -> Unit
fn cursor_mode(Self) -> CursorMode
fn set_device_scale_factor(Self, scale : Double) -> Unit
fn device_scale_factor(Self) -> Double
fn set_vsync_enabled(Self, enabled : Bool) -> Unit
fn is_vsync_enabled(Self) -> Bool
fn close_window(Self) -> Unit
fn request_attention(Self) -> Unit
fn set_mouse_touch_fallback(Self, enabled : Bool) -> Unit
fn mouse_touch_fallback_enabled(Self) -> Bool
fn fullscreen_request_status(Self) -> AsyncRequestStatus
fn cursor_mode_request_status(Self) -> AsyncRequestStatus
}

#
AsyncRequestStatus

pub enum AsyncRequestStatus {
Idle
Pending
Confirmed
Rejected
} derive(
Debug
)

#
CursorMode

pub enum CursorMode {
Visible
Hidden
Captured
} derive(
Debug
)

impl Show for CursorMode

#
DesktopGlfwPlatform

pub struct DesktopGlfwPlatform {
initialized : Bool
poll_count : Int
close_after_polls : Int
native_active : Bool
options : WindowOptions
current_input :
InputSnapshot

fullscreen : Bool
cursor_mode : CursorMode
device_scale_factor : Double
vsync_enabled : Bool
close_requested : Bool
attention_requests : Int
mouse_touch_fallback : Bool
fullscreen_request_status : AsyncRequestStatus
cursor_mode_request_status : AsyncRequestStatus
}

#
DesktopNativeHooks

pub struct DesktopNativeHooks {
try_initialize : (WindowOptions) -> Bool
poll : (Bool) -> Unit
should_close : () -> Bool
outside_size : (Int, Int) ->
OutsideSize

capture_input : (Bool, Int) ->
InputSnapshot

set_fullscreen : (Bool, Bool) -> Bool
is_fullscreen : (Bool, Bool) -> Bool
set_cursor_mode : (Bool, CursorMode) -> CursorMode
cursor_mode : (Bool, CursorMode) -> CursorMode
set_device_scale_factor : (Bool, Double) -> Double
device_scale_factor : (Bool, Double) -> Double
set_vsync_enabled : (Bool, Bool) -> Bool
is_vsync_enabled : (Bool, Bool) -> Bool
close_window : (Bool) -> Unit
request_attention : (Bool) -> Unit
set_mouse_touch_fallback : (Bool, Bool) -> Unit
mouse_touch_fallback_enabled : (Bool) -> Bool
}

#
FullscreenMode

pub enum FullscreenMode {
Windowed
Borderless
Exclusive
} derive(
Debug
)

#
MonitorInfo

pub struct MonitorInfo {
width : Int
height : Int
device_scale_factor : Double
refresh_rate_hz : Int
} derive(
Debug
)

impl Show for MonitorInfo

#
WebCanvasHooks

pub struct WebCanvasHooks {
try_initialize : (String, WindowOptions) -> Bool
poll : (Bool) -> Unit
should_close : () -> Bool
outside_size : (Int, Int) ->
OutsideSize

current_surface : (String, WindowOptions) ->
SurfaceToken

capture_input : (Bool, Int) ->
InputSnapshot

set_fullscreen : (String, Bool, Bool) -> Bool
is_fullscreen : (String, Bool, Bool) -> Bool
set_cursor_mode : (String, Bool, CursorMode) -> CursorMode
cursor_mode : (String, Bool, CursorMode) -> CursorMode
set_device_scale_factor : (String, Bool, Double) -> Double
device_scale_factor : (String, Bool, Double) -> Double
set_vsync_enabled : (String, Bool, Bool) -> Bool
is_vsync_enabled : (String, Bool, Bool) -> Bool
close_window : (String, Bool) -> Unit
request_attention : (String, Bool) -> Unit
set_mouse_touch_fallback : (String, Bool, Bool) -> Unit
mouse_touch_fallback_enabled : (String, Bool) -> Bool
fullscreen_request_status : (String, Bool, Int) -> Int
cursor_mode_request_status : (String, Bool, Int) -> Int
}

#
WebCanvasPlatform

pub struct WebCanvasPlatform {
canvas_selector : String
initialized : Bool
poll_count : Int
close_after_polls : Int
web_active : Bool
options : WindowOptions
current_input :
InputSnapshot

fullscreen : Bool
cursor_mode : CursorMode
device_scale_factor : Double
vsync_enabled : Bool
close_requested : Bool
attention_requests : Int
mouse_touch_fallback : Bool
fullscreen_request_status : AsyncRequestStatus
cursor_mode_request_status : AsyncRequestStatus
}

#
WindowOptions

pub struct WindowOptions {
title : String
width : Int
height : Int
transparent : Bool
resizable : Bool
focused : Bool
} derive(
Debug
)

#
async_request_status_from_int

fn async_request_status_from_int(status : Int) -> AsyncRequestStatus

#
async_request_status_to_int

fn async_request_status_to_int(status : AsyncRequestStatus) -> Int

#
create_desktop_glfw_platform

fn create_desktop_glfw_platform() -> DesktopGlfwPlatform

#
create_web_canvas_platform

fn create_web_canvas_platform(canvas_selector : String) -> WebCanvasPlatform

#
cursor_mode_from_int

fn cursor_mode_from_int(mode : Int) -> CursorMode

#
cursor_mode_to_int

fn cursor_mode_to_int(mode : CursorMode) -> Int

#
fullscreen_mode_from_int

fn fullscreen_mode_from_int(mode : Int) -> FullscreenMode

#
fullscreen_mode_to_int

fn fullscreen_mode_to_int(mode : FullscreenMode) -> Int

#
new_desktop_native_hooks

fn new_desktop_native_hooks(try_initialize : (WindowOptions) -> Bool, poll : (Bool) -> Unit, should_close : () -> Bool, outside_size : (Int, Int) ->
OutsideSize
, capture_input : (Bool, Int) ->
InputSnapshot
, set_fullscreen : (Bool, Bool) -> Bool, is_fullscreen : (Bool, Bool) -> Bool, set_cursor_mode : (Bool, CursorMode) -> CursorMode, cursor_mode : (Bool, CursorMode) -> CursorMode, set_device_scale_factor : (Bool, Double) -> Double, device_scale_factor : (Bool, Double) -> Double, set_vsync_enabled : (Bool, Bool) -> Bool, is_vsync_enabled : (Bool, Bool) -> Bool, close_window : (Bool) -> Unit, request_attention : (Bool) -> Unit, set_mouse_touch_fallback : (Bool, Bool) -> Unit, mouse_touch_fallback_enabled : (Bool) -> Bool) -> DesktopNativeHooks

#
new_web_canvas_hooks

fn new_web_canvas_hooks(try_initialize : (String, WindowOptions) -> Bool, poll : (Bool) -> Unit, should_close : () -> Bool, outside_size : (Int, Int) ->
OutsideSize
, current_surface : (String, WindowOptions) ->
SurfaceToken
, capture_input : (Bool, Int) ->
InputSnapshot
, set_fullscreen : (String, Bool, Bool) -> Bool, is_fullscreen : (String, Bool, Bool) -> Bool, set_cursor_mode : (String, Bool, CursorMode) -> CursorMode, cursor_mode : (String, Bool, CursorMode) -> CursorMode, set_device_scale_factor : (String, Bool, Double) -> Double, device_scale_factor : (String, Bool, Double) -> Double, set_vsync_enabled : (String, Bool, Bool) -> Bool, is_vsync_enabled : (String, Bool, Bool) -> Bool, close_window : (String, Bool) -> Unit, request_attention : (String, Bool) -> Unit, set_mouse_touch_fallback : (String, Bool, Bool) -> Unit, mouse_touch_fallback_enabled : (String, Bool) -> Bool, fullscreen_request_status : (String, Bool, Int) -> Int, cursor_mode_request_status : (String, Bool, Int) -> Int) -> WebCanvasHooks

#
new_window_options

fn new_window_options(title : String, width : Int, height : Int, transparent : Bool, resizable : Bool, focused? : Bool) -> WindowOptions

#
reset_desktop_native_hooks

fn reset_desktop_native_hooks() -> Unit

#
reset_web_canvas_hooks

fn reset_web_canvas_hooks() -> Unit

#
set_desktop_native_hooks

fn set_desktop_native_hooks(hooks : DesktopNativeHooks) -> Unit

#
set_web_canvas_hooks

fn set_web_canvas_hooks(hooks : WebCanvasHooks) -> Unit

Powered by MoonBit

Site sourceReport issuePackagesBuild queueSkillsStatistics

© 2026 mooncakes.io