DesktopApp.run#

DesktopApp.run(args=None, localization={}, gui=None, debug=False, http_server=False, http_port=None, user_agent=None, private_mode=True, storage_path=None, menu=[], server=<class 'webview.http.BottleServer'>, server_args={}, ssl=False)#

Start a GUI loop and display previously created windows. This function must be called from a main thread.

Parameters:
  • func – Function to invoke upon starting the GUI loop.

  • args – Function arguments. Can be either a single value or a tuple of values.

  • localization – A dictionary with localized strings. Default strings and their keys are defined in localization.py.

  • gui – Force a specific GUI. Allowed values are cef, qt, or gtk depending on a platform.

  • debug – Enable debug mode. Default is False.

  • http_server – Enable built-in HTTP server. If enabled, local files will be served using a local HTTP server on a random port. For each window, a separate HTTP server is spawned. This option is ignored for non-local URLs.

  • user_agent – Change user agent string. Not supported in EdgeHTML.

  • private_mode – Enable private mode. In private mode, cookies and local storage are not preserved. Default is True.

  • storage_path – Custom location for cookies and other website data

  • menu – List of menus to be included in the app menu

  • server – Server class. Defaults to BottleServer

  • server_args – Dictionary of arguments to pass through to the server instantiation