diff --git a/docs/.vuepress/config.js b/docs/.vuepress/config.js index f8f5f5a8..2c8b266e 100644 --- a/docs/.vuepress/config.js +++ b/docs/.vuepress/config.js @@ -54,6 +54,7 @@ module.exports = { '/examples/': [ 'cef', 'change_url', + 'close_confirm', 'confirmation_dialog', 'cookies', 'css_load', @@ -61,6 +62,8 @@ module.exports = { 'debug', 'destroy_window', 'events', + 'expose', + 'focus', 'frameless', 'fullscreen', 'get_elements', diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index f76c34c4..ee3bec59 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -1,5 +1,24 @@ # Changelog +## 4.2 + +_Released 22/06/2023_ + +### ⚡ Features + +- [All] `webview.create_window(focus=False)` to create a non-focusable window. Thanks @mi4code #1030. + +### 🚀 Improvements + +- [All] Modernization of project infrastructure + typing. Thanks @demberto. +- [Winforms] Top level menu item support. Thanks @zhengxiaoyao0716. +- [Winforms] Disable touchpad elastic overscroll. Thanks @firai. + +### 🐞 Bug fixes + +- [Winforms] Unable to load DLL 'WebView2Loader.dll': The specified module could not be found. Thanks @kawana77b #1078 +- [Cocoa] Fix missing pip dependency `pyobjc-framework-security`. + ## 4.1 _Released 02/05/2023_ diff --git a/docs/README.md b/docs/README.md index 90f83668..235d4740 100644 --- a/docs/README.md +++ b/docs/README.md @@ -7,7 +7,7 @@ actionLink: /guide/ footer: BSD Licensed | Copyright © 2014–present Roman Sirokov ---
-Current version: 4.1
+Current version: 4.2
What's new
diff --git a/docs/examples/focus.md b/docs/examples/focus.md new file mode 100644 index 00000000..346dcae4 --- /dev/null +++ b/docs/examples/focus.md @@ -0,0 +1,11 @@ +# Expose + +Create a non-focusable window that can be useful for onscreen floating tools. + +``` python +import webview + +if __name__ == '__main__': + webview.create_window('Nonfocusable window', html='

You shouldnt be able to type into this window...

...but still you can click elements in this window...

', focus=False) + webview.start() +``` \ No newline at end of file diff --git a/docs/guide/api.md b/docs/guide/api.md index 316fb18e..53de8dea 100644 --- a/docs/guide/api.md +++ b/docs/guide/api.md @@ -6,7 +6,7 @@ ``` python webview.create_window(title, url=None, html=None, js_api=None, width=800, height=600, x=None, y=None, resizable=True, fullscreen=False, min_size=(200, 100), - hidden=False, frameless=False, easy_drag=True, + hidden=False, frameless=False, easy_drag=True, focus=True, minimized=False, on_top=False, confirm_close=False, background_color='#FFFFFF', transparent=False, text_select=False, zoomable=False, draggable=False, server=http.BottleServer, server_args={}, localization=None) @@ -28,6 +28,7 @@ Create a new _pywebview_ window and returns its instance. Window is not shown un * `hidden` - Create a window hidden by default. Default is False * `frameless` - Create a frameless window. Default is False. * `easy_drag` - Easy drag mode for frameless windows. Window can be moved by dragging any point. Default is True. Note that easy_drag has no effect with normal windows. To control dragging on an element basis, see [drag area](/guide/api.html#drag-area) for details. +* `focus` - Create a non-focusable window if False. Default is True. * `minimized` - Start in minimized mode * `on_top` - Set window to be always on top of other windows. Default is False. * `confirm_close` - Whether to display a window close confirmation dialog. Default is False diff --git a/examples/focus.py b/examples/focus.py index 7340fd68..7100b885 100644 --- a/examples/focus.py +++ b/examples/focus.py @@ -1,7 +1,7 @@ import webview """ -This example demonstrates the 'focus' window option (which can be usefull for onscreen floating tools). +This example demonstrates a non-focusable window, which can be useful for onscreen floating tools. """ if __name__ == '__main__':