webui-dev / webui

Use any web browser or WebView as GUI, with your preferred language in the backend and HTML5 in the frontend, all in a lightweight portable lib.
https://webui.me
MIT License
2.35k stars 144 forks source link

`set_title` function #381

Open ttytm opened 1 month ago

ttytm commented 1 month ago

Currently, upon a window start the window title is the localhost path until the windows is full loaded. Then the windows html <title> is used.

Similar to the webui_set_icon function a webui_set_title function could be used to achive setting a consistent window title for a webui application.

hassandraga commented 1 month ago

If we add webui_set_title then it will behave like this:

If you don't see any issue in this, then let's add it.

ttytm commented 1 month ago

Since WebUI is about making GUI apps, I think it can be a good think to set a consistent title (/ allow more control over the title) from the backend via an API function that is provided by WebUI.

I think there might be some options/workarounds to fully prevent the localhost, this would then make a webui app feel even more like a native gui app. I didn't made any tests yet though.