Disclosure Statement: This site contains affiliate links, which means that I may receive a commission if you make a purchase using these links. As an eBay Partner, I earn from qualifying purchases.

title bar

Post Reply
Vaytl
Posts: 22
Joined: Tue Jan 04, 2022 12:52 pm

title bar

Post by Vaytl »

Thanks for WebUI4Delphi.
How can I remove the "localhost" caption when loading the window?
OS windows
User avatar
salvadordf
Posts: 4056
Joined: Thu Feb 02, 2017 12:24 pm
Location: Spain
Contact:

Re: title bar

Post by salvadordf »

Try setting the document title with JavaScript :

Code: Select all

MyWindow.Run('document.title = "My custom title";');
Vaytl
Posts: 22
Joined: Tue Jan 04, 2022 12:52 pm

Re: title bar

Post by Vaytl »

Unfortunately it didn't help.
Image

I understand that this is in the WebUI code itself.
User avatar
salvadordf
Posts: 4056
Joined: Thu Feb 02, 2017 12:24 pm
Location: Spain
Contact:

Re: title bar

Post by salvadordf »

If you control the page contents you can also use the <title> element in HTML.

Code: Select all

  LMyHTML := '<html><head><title>Page Title</title><script src="webui.js"></script></head> Hello World ! </html>';
  FWindow := TWebUIWindow.Create;
  FWindow.Show(LMyHTML);
If this is not what you need then add an issue with a feature request in the official WebUI project repository at GitHub.
https://github.com/webui-dev/webui
Vaytl
Posts: 22
Joined: Tue Jan 04, 2022 12:52 pm

Re: title bar

Post by Vaytl »

Added issue https://github.com/webui-dev/webui/issues/327
Post Reply