index.xht location

Talk about code development, features, specific bugs, enhancements, patches, and similar things.
Forum rules
Please keep everything here strictly on-topic.
This board is meant for Pale Moon source code development related subjects only like code snippets, patches, specific bugs, git, the repositories, etc.

This is not for tech support! Please do not post tech support questions in the "Development" board!
Please make sure not to use this board for support questions. Please post issues with specific websites, extensions, etc. in the relevant boards for those topics.

Please keep things on-topic as this forum will be used for reference for Pale Moon development. Expect topics that aren't relevant as such to be moved or deleted.
User avatar
szczelnybez
Apollo supporter
Apollo supporter
Posts: 34
Joined: 2021-01-20, 00:11

index.xht location

Unread post by szczelnybez » 2024-02-19, 14:40

I'd like to modify the default start "blank" page which opens when a new tab is added with no default starting web page set.
It has got only a faded PaleMoon logo in the middle.
I think it is likely defined in the index.xht file. The thing is I couldn't find it, tried palemoon and profile folders. Any help?
Sorry if this is wrong forum section.

User avatar
therube
Board Warrior
Board Warrior
Posts: 1651
Joined: 2018-06-08, 17:02

Re: index.xht location

Unread post by therube » 2024-02-19, 19:07

Easier.

about:config, change the value of browser.newtab.url to about:blank.

User avatar
szczelnybez
Apollo supporter
Apollo supporter
Posts: 34
Joined: 2021-01-20, 00:11

Re: index.xht location

Unread post by szczelnybez » 2024-02-19, 20:49

Apologies - I wasn't clear enough.
What I'd like to achieve is to create a custom html/xht page by modifying the code of the existing about:logopage.
Is there a way to do it? I presume that file must be stored somewhere, possibly it is index.xht.

User avatar
athenian200
Contributing developer
Contributing developer
Posts: 1536
Joined: 2018-10-28, 19:56
Location: Georgia

Re: index.xht location

Unread post by athenian200 » 2024-02-19, 21:15

https://addons.palemoon.org/addon/browsepaper/

I don't know if you can just modify the index.xht directly, but there is an extension called Browsepaper that does pretty much what I think you want. You would definitely need a browser extension for this.
"The Athenians, however, represent the unity of these opposites; in them, mind or spirit has emerged from the Theban subjectivity without losing itself in the Spartan objectivity of ethical life. With the Athenians, the rights of the State and of the individual found as perfect a union as was possible at all at the level of the Greek spirit." -- Hegel's philosophy of Mind

User avatar
szczelnybez
Apollo supporter
Apollo supporter
Posts: 34
Joined: 2021-01-20, 00:11

Re: index.xht location

Unread post by szczelnybez » 2024-02-19, 22:21

Thanks for that hint. The recommended add-on display an image in place of an empty tab and that's not really what I intended to do.
It would be great to be able to fully customize the look of that blank page by simply editing a dedicated html file. Not sure if that's possible....

User avatar
somdcomputerguy
Lunatic
Lunatic
Posts: 385
Joined: 2014-02-23, 17:25
Location: Greenbrier County, West Virginia
Contact:

Re: index.xht location

Unread post by somdcomputerguy » 2024-02-19, 23:38

szczelnybez wrote:
2024-02-19, 22:21
It would be great to be able to fully customize the look of that blank page by simply editing a dedicated html file. Not sure if that's possible....
Why not just create an HTML file yourself, exactly to your liking, and set that as your start page?
:cool: -bruce /* somdcomputerguy.com */
'If you change the way you look at things, the things you look at change.'

User avatar
szczelnybez
Apollo supporter
Apollo supporter
Posts: 34
Joined: 2021-01-20, 00:11

Re: index.xht location

Unread post by szczelnybez » 2024-02-20, 13:00

That's actually a solution!
However, few difference from the effect I wanted to achieve are following:
- tab name no longer being "New Tab",
- non-empty address bar,
- possible performance issue - loading time might be longer, as index.xht might be preloaded in memory, together with Palemoon - this is to be confirmed,

User avatar
somdcomputerguy
Lunatic
Lunatic
Posts: 385
Joined: 2014-02-23, 17:25
Location: Greenbrier County, West Virginia
Contact:

Re: index.xht location

Unread post by somdcomputerguy » 2024-02-20, 13:13

szczelnybez wrote:
2024-02-20, 13:00
That's actually a solution!
However, few difference from the effect I wanted to achieve are following:
- tab name no longer being "New Tab",
- non-empty address bar,
- possible performance issue - loading time might be longer, as index.xht might be preloaded in memory, together with Palemoon - this is to be confirmed,
Well I hope it helps you out. Some possible solutions to the differences - define a title tag to whatever, a small bit of j/s or something might be a solution to a non-empty address bar, I don't think there will be any extra noticeable time to performance.
:cool: -bruce /* somdcomputerguy.com */
'If you change the way you look at things, the things you look at change.'

User avatar
Kris_88
Keeps coming back
Keeps coming back
Posts: 939
Joined: 2021-01-26, 11:18

Re: index.xht location

Unread post by Kris_88 » 2024-02-22, 16:58

szczelnybez wrote:
2024-02-20, 13:00
However, few difference from the effect I wanted to achieve are following:
Are you still waiting for another solution?

User avatar
athenian200
Contributing developer
Contributing developer
Posts: 1536
Joined: 2018-10-28, 19:56
Location: Georgia

Re: index.xht location

Unread post by athenian200 » 2024-02-22, 18:21

szczelnybez wrote:
2024-02-19, 22:21
Thanks for that hint. The recommended add-on display an image in place of an empty tab and that's not really what I intended to do.
It would be great to be able to fully customize the look of that blank page by simply editing a dedicated html file. Not sure if that's possible....
Oh, you want to modify this file?

https://xref.palemoon.org/goanna-centra ... e.xhtml#41

It's not called index.xht, it's called logopage.xhtml. And you would need an extension to modify this, but doing so should be fairly simple.

You could just to use an extension to overlay your own copy of logopage.xhtml over the one that's baked into the browser. So you'd need some kind of XUL extension to overlay your own provided file over content/global/logopage.xhtml to get this to work. Modifying that file directly is not allowed because it's baked into the browser, and is effectively as much of a a security risk as opening the binary in a hex editor, but you can overlay it with your own copy.

https://xref.palemoon.org/goanna-centra ... /jar.mn#53

It's also worth noting... pretty sure the only reason the browser doesn't display "about:logopage" in the titlebar when you open a new tab, is because the definition of "about:logopage" uses a flag that makes it hide itself. I am wondering if you could define your own "about:" page this way using JS, and then point to it using the "browser.newtab.url" preference that therube pointed out.

https://xref.palemoon.org/goanna-centra ... tor.cpp#78
"The Athenians, however, represent the unity of these opposites; in them, mind or spirit has emerged from the Theban subjectivity without losing itself in the Spartan objectivity of ethical life. With the Athenians, the rights of the State and of the individual found as perfect a union as was possible at all at the level of the Greek spirit." -- Hegel's philosophy of Mind

vannilla
Moon Magic practitioner
Moon Magic practitioner
Posts: 2193
Joined: 2018-05-05, 13:29

Re: index.xht location

Unread post by vannilla » 2024-02-22, 22:28

You can read Browsepaper's source to see how to handle displaying a different file. With enough twiddling you should be able to adapt it to display an editable HTML page of your choice.

User avatar
szczelnybez
Apollo supporter
Apollo supporter
Posts: 34
Joined: 2021-01-20, 00:11

Re: index.xht location

Unread post by szczelnybez » 2024-02-23, 15:37

It seems there is some fiddling to be done to get there. Will try to do it.
Thanks everyone!

User avatar
somdcomputerguy
Lunatic
Lunatic
Posts: 385
Joined: 2014-02-23, 17:25
Location: Greenbrier County, West Virginia
Contact:

Re: index.xht location

Unread post by somdcomputerguy » 2024-02-23, 15:44

szczelnybez wrote:
2024-02-23, 15:37
It seems there is some fiddling to be done to get there. Will try to do it.
Thanks everyone!
You bet. Good luck!
:cool: -bruce /* somdcomputerguy.com */
'If you change the way you look at things, the things you look at change.'

User avatar
Kris_88
Keeps coming back
Keeps coming back
Posts: 939
Joined: 2021-01-26, 11:18

Re: index.xht location

Unread post by Kris_88 » 2024-02-23, 15:50

As athenian200 already said, you can override the embedded file with your own file. Moreover, if you really want, you can even do this without using add-ons.

1) Find the "palemoon.exe" file.
2) Find the "chrome.manifest" file in the same folder.
3) Add two lines to the contents of the chrome.manifest file.

Code: Select all

resource MyLogo MyLogo/
override chrome://global/content/logopage.xhtml  resource://MyLogo/page.htm
4) Create a “MyLogo” subfolder here.
5) Place the “page.htm” file in the “MyLogo” subfolder.

Your "MyLogo" folder will be mapped to the URL "resource://MyLogo/".
Accordingly, if you want to use a picture or other resources on your page, then you must use the full URL, like
"resource://MyLogo/image.jpg"

Post Reply