** Current - [X] Process spawning lua (+ stdio) - [X] Keybindings (lua api) - [X] Modal keys - [X] event loop for async work - [X] example: trigger dmenu for simple selection - [X] Fix segfault on quit - [X] view history navigation - [X] view next/prev - [X] Get view list api - [X] Assign ID to each view (reference in lua api) - [X] view select by id - [X] Multi-window - [X] New window on new window request - [X] Socket for opening window in current session (lua eval) - [X] Config loading and lua path - [X] Events/autocommands - [X] Url changed event - [X] History storage - [X] History completion - [X] Close window if last view closed - [X] Rename terms: tab to view? (also web.tabs) - [ ] Configuration lua api - [ ] Switch to __internals - [ ] Respect cli args for main window - [ ] Tests for api - [ ] Log stdout, errors and results from lua somewhere - [ ] Downloading/download path config - [ ] Run JS in page - [ ] INVESTIGATE: Segfault on close - [ ] INVESTIGATE: Errors in keymap segfaults ** Next - [ ] Search text in page - [ ] Dev tools - [ ] Fullscreen - [ ] Zoom in/out - [ ] Permission requests handling/persisting - [ ] window.opener controls (use createWindow api directly?) - [ ] Notifications - [ ] Conflict in keymap (keymap already exists) - [ ] Allow pattern filtering for event listeners - [ ] Allow tab_id, win_id filtering for event listeners - [ ] Handle resource cleanup + signal disconnecting - [ ] Open url sanitize/humanize (add protocol if missing, remove quotes, etc) - [ ] static linking for qt - [X] static linking for libluv - [ ] User scripts (greasemonkey?) - [ ] User stylesheets (per site and global?) - [ ] Bookmarking ** Later - [ ] Support multiple modes for keymap.set: `web.keymap.set({'n','i'}, ...)` - [ ] Read page contents via lua - [ ] `web.to_string`: like vim.inspect - [X] Update window title on current webview title change ** Later later - [ ] Custom file picker - [ ] remote debugging with cdp (spider-repl) ** Maybe - [ ] Floating webviews? - [ ] Move modal keymap management into lua? ** Notes - view = 0, nil, none: Current view - Win = 0: Current window - Win = nil, none: All windows or current window based on operation - Keep track of last focused window (current window is last focused) #+begin_src lua web.view.set_url(url) -- Set url for current view web.view.set_url(url, { view = 1 }) -- Set url for view 1 web.view.set_url(url, { view = 1, win = 1 }) -- Set url for view 1 in win 1 web.view.set_url(url, { win = 1 }) -- Set url for current view in win 1 web.view.new(url, { win = 1 }) -- New view in win 1 web.view.new(url) -- New view in current window web.view.close({ view = 1 }) -- Close view 1 web.view.close() -- Close current view in current window web.view.list({ win = nil }) -- List all tabs web.view.list({ win = 1 }) -- List win 1 tabs web.view.select({ view = 1, win = 1 }) -- Select win 1 view web.view.select({ view = 1, win = 0 }) -- Select view 1 in current window web.view.select({ view = 1 }) -- Select view 1 web.view.current({ win = 1 }) -- Current view in win 1 web.view.current() -- Current view in current win web.history.back(1) -- Back for current view in current window web.history.back(1, { view = 1 }) -- Back for view 1 web.history.back(1, { win = 1 }) -- Back for current view in win 1 web.keymap.set('n', '', ..., { view = 1 }) -- Set keymap for view 1 web.keymap.set('n', '', ..., { win = 1 }) -- Set keymap for win 1 web.opt.new_tab_url = 'https://duckduckgo.com' #+end_src