Files
pywebview/examples/move_window.py
Roman c875c8d98d Move window (#402)
* add move function to gtk.py

* add move function to qt.py

* add move function to window.py

* blind implementation of move function for winforms.py

* blindly implementing move in cocoa.py

* Add x,y
Update documentation
Fix GTK

* [Win] Center window by default

* [GTK] Center window by default
2019-10-18 23:50:03 +03:00

17 lines
328 B
Python

import webview
from time import sleep
"""
This example demonstrates how to load HTML in a web view window
"""
def move(window):
sleep(2)
window.move(0, 0)
if __name__ == '__main__':
window = webview.create_window('Move window example', html='<h1>Move window</h1>', x=100, y=200)
webview.start(move, window)