Include light themes as default themes

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.
riiis
Lunatic
Lunatic
Posts: 471
Joined: 2014-05-17, 15:51
Location: USA

Include light themes as default themes

Unread post by riiis » 2018-03-24, 00:15

Persona/lightweight themes must currently be added by the user. When added, the persona/lightweight theme is recorded in "about:config" as a "user set" preference ("lightweightThemes.usedThemes"). Until the user adds a persona/lightweight theme to Pale Moon, the "lightweightThemes.usedThemes" preference is empty and hidden. Instead of "lightweightThemes.usedThemes" being empty by default, a few persona/lightweight themes could be easily preloaded in "lightweightThemes.usedThemes", as the default value of the "lightweightThemes.usedThemes" preference. That is, change the default value of "lightweightThemes.usedThemes"
from:

Code: Select all

[]
to say, something like this:

Code: Select all

[{"id":"LT-#3c7650-#000000","name":"Green","headerURL":"resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif","footerURL":"resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif","textcolor":"#000000","accentcolor":"#3c7650"},{"id":"LT-#404040-#f1f1f1","name":"Dark","headerURL":"resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif","footerURL":"resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif","textcolor":"#f1f1f1","accentcolor":"#404040"},{"id":"LT-#dcb97e-#000000","name":"Oak","headerURL":"resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif","footerURL":"resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif","textcolor":"#000000","accentcolor":"#dcb97e"},{"id":"LT-#aabcc8-#000000","name":"Sea","headerURL":"resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif","footerURL":"resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif","textcolor":"#000000","accentcolor":"#AABCC8"},{"id":"LT-#c83838-#efefef","name":"Red","headerURL":"resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif","footerURL":"resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif","textcolor":"#efefef","accentcolor":"#c83838"},{"id":"LT-#e3c100-#000000","name":"Golden","headerURL":"resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif","footerURL":"resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif","textcolor":"#000000","accentcolor":"#e3c100"},{"id":"LT-#dddddd-#000000","name":"Light","headerURL":"resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif","footerURL":"resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif","textcolor":"#000000","accentcolor":"#dddddd"},{"id":"LT-#ff8000-#000000","name":"Orange","headerURL":"resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif","footerURL":"resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif","textcolor":"#000000","accentcolor":"#ff8000"}]

Code: Select all

[{
		"id": "LT-#3c7650-#000000",
		"name": "Green",
		"headerURL": "resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif",
		"footerURL": "resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif",
		"textcolor": "#000000",
		"accentcolor": "#3c7650"
	}, {
		"id": "LT-#404040-#f1f1f1",
		"name": "Dark",
		"headerURL": "resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif",
		"footerURL": "resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif",
		"textcolor": "#f1f1f1",
		"accentcolor": "#404040"
	}, {
		"id": "LT-#dcb97e-#000000",
		"name": "Oak",
		"headerURL": "resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif",
		"footerURL": "resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif",
		"textcolor": "#000000",
		"accentcolor": "#dcb97e"
	}, {
		"id": "LT-#aabcc8-#000000",
		"name": "Sea",
		"headerURL": "resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif",
		"footerURL": "resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif",
		"textcolor": "#000000",
		"accentcolor": "#AABCC8"
	}, {
		"id": "LT-#c83838-#efefef",
		"name": "Red",
		"headerURL": "resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif",
		"footerURL": "resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif",
		"textcolor": "#efefef",
		"accentcolor": "#c83838"
	}, {
		"id": "LT-#e3c100-#000000",
		"name": "Golden",
		"headerURL": "resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif",
		"footerURL": "resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif",
		"textcolor": "#000000",
		"accentcolor": "#e3c100"
	}, {
		"id": "LT-#dddddd-#000000",
		"name": "Light",
		"headerURL": "resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif",
		"footerURL": "resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif",
		"textcolor": "#000000",
		"accentcolor": "#dddddd"
	}, {
		"id": "LT-#ff8000-#000000",
		"name": "Orange",
		"headerURL": "resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif",
		"footerURL": "resource://chrome/toolkit/skin/classic/global/scrollbar/slider.gif",
		"textcolor": "#000000",
		"accentcolor": "#ff8000"
	}
]
These light themes require no downloads or external images. These light themes all use one image file ("slider.gif"), a 2px file already included in Pale Moon chrome. As a test of concept, I've listed eight persona/light themes. But, of course, the default value of the "lightweightThemes.usedThemes" preference could contain fewer or more light themes, or entirely different light themes from the above. And, more complex persona/light themes could be added to the defaults, by adding needed light theme images to Pale Moon chrome.

The latest versions of Firefox no longer support complete themes. And, Firefox calls persona/light themes simply "Themes". In contrast, the Pale Moon add-on site calls its healthy number of complete themes "Themes", whereas persona/lightweight themes are no where to be found or referenced. These differences have to be confusing to Pale Moon users migrating from Firefox or other browsers. Including a few light themes in the default value of the "lightweightThemes.usedThemes" preference-- such inclusion should partially mitigate this confusion.

New Tobin Paradigm

Re: Include light themes as default themes

Unread post by New Tobin Paradigm » 2018-03-24, 00:28

Request denied.

Locked