v1.6.1
New Features
- sys.set_bar_text() / sys.set_bar_lua(): WebView can now update bar display with plain text or rich Lua expressions
- WebView lua_path binding: Each WebView knows its owner script, bridge callbacks target the correct bar
- Dialog size persistence: All dialogs save position AND size on close, restore on next open
- K-Line Demo:
kline_demo.lua— BTC/USDT candlestick chart via WebView2 + lightweight-charts, real-time WebSocket updates
Improvements
- WebView creation deferred via PostMessage to prevent stack overflow from recursive WM_PAINT
webview_creatingguard prevents duplicate creation attempts- Stack size increased to 8MB as safety margin for WebView2 initialization
set_bar_luauses directreturn exprinstead of function wrapper (fixes syntax error with..operator)__bar_luaglobal persists last bar expression across script re-execution- Dialog position/size saved for all dialogs (removed borderless-only restriction)
Bug Fixes
- Fix WebView2 stack overflow crash (0xC00000FD) when opening webview dialogs
- Fix
set_bar_luaincorrectly wrapping expressions infunction()...end() - Fix webview bridge callbacks affecting wrong bar (global lua_path race condition)
Full Changelog: v1.6.0...v1.6.1