From a70d3720a2b49ea72b6483e5f87b5dc04996bbea Mon Sep 17 00:00:00 2001 From: Vladimir Krasheninnikov Date: Tue, 25 Feb 2025 23:04:04 +0100 Subject: Describe interface.bindCanvas --- doc/lua/openstarbound/interface.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'doc/lua') diff --git a/doc/lua/openstarbound/interface.md b/doc/lua/openstarbound/interface.md index a0e50eb..70b2a4b 100644 --- a/doc/lua/openstarbound/interface.md +++ b/doc/lua/openstarbound/interface.md @@ -54,8 +54,10 @@ Displays a registered pane. --- -#### `?` interface.bindCanvas() -TODO +#### `CanvasWidget` interface.bindCanvas(`string` name, [`bool` ignoreInterfaceScale = false]) +Binds the canvas widget on the main interface with the specified name as userdata for easy access. The `CanvasWidget` has the same methods as described in widget.md. + +- **ignoreInterfaceScale** is used to ignore the current interface scaling and bind the canvas with the screen size. --- -- cgit v1.2.3