[Release] Swarth

Dedicated board for extension releases/support threads

Moderators: FranklinDM, Lootyhoof

Forum rules
Please do not create new topics here unless you are an extension author in need of a dedicated releases&support thread!
User avatar
moonbat
Knows the dark side
Knows the dark side
Posts: 4942
Joined: 2015-12-09, 15:45
Contact:

Re: [Release] Swarth

Unread post by moonbat » 2021-12-03, 02:05

Off-topic:
Ah, I thought his posting style and snark sounded familiar.
"One hosts to look them up, one DNS to find them and in the darkness BIND them."

Image
Linux Mint 21 Xfce x64 on HP i5-5200 laptop, 12 GB RAM.
AutoPageColor|PermissionsPlus|PMPlayer|Pure URL|RecordRewind|TextFX

User avatar
FranklinDM
Add-ons Team
Add-ons Team
Posts: 570
Joined: 2017-01-14, 02:40
Location: Philippines
Contact:

Re: [Release] Swarth

Unread post by FranklinDM » 2022-02-01, 15:38

Update to Swarth: v1.0.3
  • Ensure that the method ID is an integer when setting the method to be used for a particular scope in the scopes dialog
  • Implement migration for scope configuration
    - Move scope information to scopes property and include a version property in the configuration file
    - Handle previous configurations that contain string method IDs and convert them if necessary
  • Update install manifest (from v1.0.2, not published on add-ons site)
Update options: GitHub releases, APO, Basilisk Add-ons, check for updates using the Add-ons Manager.

User avatar
FranklinDM
Add-ons Team
Add-ons Team
Posts: 570
Joined: 2017-01-14, 02:40
Location: Philippines
Contact:

Re: [Release] Swarth

Unread post by FranklinDM » 2022-02-02, 15:15

Update to Swarth: v1.0.4
  • Reset scope if location change was caused by (push/pop/replace)State
Update options: GitHub releases, APO, Basilisk Add-ons, check for updates using the Add-ons Manager.

User avatar
FranklinDM
Add-ons Team
Add-ons Team
Posts: 570
Joined: 2017-01-14, 02:40
Location: Philippines
Contact:

Re: [Release] Swarth

Unread post by FranklinDM » 2022-02-12, 07:55

Update to Swarth: v1.0.5
  • Ensure all cached stylesheets are cleared upon receiving invalidation event (#2)
Update options: GitHub releases, APO, Basilisk Add-ons, check for updates using the Add-ons Manager.

User avatar
Pallid Planetoid
Knows the dark side
Knows the dark side
Posts: 4279
Joined: 2015-10-06, 16:59
Location: Los Angeles CA USA

Re: [Release] Swarth

Unread post by Pallid Planetoid » 2022-05-18, 04:23

Does the preference settings include a setting where all websites will render as "normal" (that is not be "dark") unless a specific website is set to render as "dark".

In other words, ALL websites would ONLY be "dark" if a preference to be "dark" is "enabled" (the default would be "disabled" for all websites) - thus all website would start-out (begin) with "dark" disabled hence render as "normal" (unless otherwise previously set to render as "dark").
Current Pale Moon(x86) Release | WIN10 | I5 CPU, 1.7 GHz, 6GB RAM, 500GB HD[20GB SSD]
Formerly user Pale Moon Rising - to provide context involving embedded reply threads.
Good judgment comes from experience and a lot of that comes from bad judgment. - Will Rogers
Knowing Pale Moon is indisputably #1 is defined by knowing the totality of browsers. - Pale Moon Rising

User avatar
FranklinDM
Add-ons Team
Add-ons Team
Posts: 570
Joined: 2017-01-14, 02:40
Location: Philippines
Contact:

Re: [Release] Swarth

Unread post by FranklinDM » 2022-05-18, 07:34

Yes.

Go to Swarth's Preferences and set Default color method to Retain page style. With this, all sites will remain unmodified except for scopes whose color method is set to anything other than Retain page style.

htuyar
Moonbather
Moonbather
Posts: 69
Joined: 2015-09-11, 10:19
Location: Istanbul

Re: [Release] Swarth

Unread post by htuyar » 2022-05-18, 07:44

Would it be possible to have an option to retain the page style if the site already has rules for a dark color scheme preference?

User avatar
FranklinDM
Add-ons Team
Add-ons Team
Posts: 570
Joined: 2017-01-14, 02:40
Location: Philippines
Contact:

Re: [Release] Swarth

Unread post by FranklinDM » 2022-05-18, 08:07

htuyar wrote:
2022-05-18, 07:44
Would it be possible to have an option to retain the page style if the site already has rules for a dark color scheme preference?
This option already exists via Swarth's toolbar button, which allows you to select the scope of the current website/URL and choose what color method will be used. The Retain page style option is available in that button's menu.
Screenshot 2022-05-18 160655.png

htuyar
Moonbather
Moonbather
Posts: 69
Joined: 2015-09-11, 10:19
Location: Istanbul

Re: [Release] Swarth

Unread post by htuyar » 2022-05-18, 09:17

I had suspected that I should have expressed it more clearly. What I mean is a general setting, not specific to a site/scope. Something like "if there's a prefers-color-scheme: dark in the CSS, retain the page style". I still might be overlooking something, though.

User avatar
FranklinDM
Add-ons Team
Add-ons Team
Posts: 570
Joined: 2017-01-14, 02:40
Location: Philippines
Contact:

Re: [Release] Swarth

Unread post by FranklinDM » 2022-05-18, 09:23

That would require scanning all the style sheets for the existence of prefers-color-scheme. This is possible and can be implemented in the future as the extension already has the prerequisites for this in place, but it will require that the stylesheet processor color method to be used as the default.

EDIT: Tracked in Swarth/Issue #4. I currently don't have much free time to tackle this, but patches are welcome. The file that needs to be changed is StylesheetProcessor.jsm plus changes to the preferences.

htuyar
Moonbather
Moonbather
Posts: 69
Joined: 2015-09-11, 10:19
Location: Istanbul

Re: [Release] Swarth

Unread post by htuyar » 2022-05-18, 09:33

OK, thanks. I'll take a look at the code and see if I can make an attempt.

User avatar
nguyen9173
Banned user
Banned user
Posts: 95
Joined: 2022-06-02, 13:38

Re: [Release] Swarth

Unread post by nguyen9173 » 2022-06-02, 18:13

Hi. Could you make your addon work with SeaMonkey, too? Only a few additions needed:

https://www.seamonkey-project.org/dev/extensions

On SeaMonkey we have the official DBGALT but it's currently having a bug. If you open a new private window on start by passing -private into the SeaMonkey shortcut then on this window DBGALT will not work. You will have to go addons manager to disable then re-enable it for it to work right in this private window. Swarth doesn't suffer from this bug. I was able to get Swarth installed and working on SeaMonkey by applying the additions as guided above and repack the xpi. But this repacked Swarth suffers another bug. It will not save site preferences if the preferences were modified on the private window. It only saves the preferences made on normal window. This moment I realize I can't continue with my own little hacks but would better to contact you directly.

User avatar
FranklinDM
Add-ons Team
Add-ons Team
Posts: 570
Joined: 2017-01-14, 02:40
Location: Philippines
Contact:

Re: [Release] Swarth

Unread post by FranklinDM » 2022-06-03, 04:03

nguyen9173 wrote:
2022-06-02, 18:13
Could you make your addon work with SeaMonkey, too?
I'm not willing to introduce official support for non-UXP applications, such as SeaMonkey. However, patches are welcome, and if it breaks in that application, someone else other than me must fix it.
nguyen9173 wrote:
2022-06-02, 18:13
It will not save site preferences if the preferences were modified on the private window. It only saves the preferences made on normal window.
Go to Swarth's preferences and enable Keep scope changes in private browsing mode.
Screenshot 2022-06-03 120154.png

User avatar
Pallid Planetoid
Knows the dark side
Knows the dark side
Posts: 4279
Joined: 2015-10-06, 16:59
Location: Los Angeles CA USA

Re: [Release] Swarth

Unread post by Pallid Planetoid » 2022-06-03, 07:13

It appears the Swarth extension has caused a permanent issue with my start.me start-page of which Pale Moon has partnered with (even after removing the add-on). --- Please read followup post below!

I have lost one of the widgets that I had on my start-page as result of installing the Swarth add-on.

And for some reason I am unable to undo this damage to my start-page in Pale Moon - the issue remains after removing the add-on.

I have cleared cookies (for the web page) and cleared Pale Moon cache but no help.

Here is what Pale Moon used to and should render (this is what I get in Firefox because of course Swarth was not installed on Firefox and is what I did get in Pale Moon prior to installing the Swarth add-on on Pale Moon):
PIC-1 What it should look like - with 'STARTPAGE SEARCH' widget.png
You can see the "STARTPAGE SEARCH" Widget in the upper-right area of the page under the "START PAGE DESIGNED BY..." text (my name has been blacked out for privacy). This ("STARTPAGE SEARCH" Widget) was present in Pale Moon prior to installing the Swarth extension (and is missing since installing the extension - even after removing the extension).

I am using the same exact URL for both Pale Moon and Firefox - so by any manner of logic I should obviously get the same start-page for both browsers (absent any interference specific to either browser).

But for some reason after installing Swarth (and then removing the extension in the hope this would fix the problem) - I am now missing (permanently) the "STARTPAGE SEARCH" Widget and I am unable to add it back to Pale Moon. What happens if I attempt to add the widget back on Pale Moon is that nothing happens in Pale Moon but I will get two "search" widgets in any of my other browsers using this same start-page including Firefox (which makes sense actually since the Widget is actually in the start-page - it just does not render in Pale Moon for some reason since I installed the extension).

This is what I now get in Pale Moon for my start-page (using the same, start-page, URL as I use for Firefox):
PIC-2 What I get in Pale Moon after installing and then removing 'swarth' add-on.png
As you can see the said Widget is not present in Pale Moon (and I cannot add this widget in Pale Moon either).

It appears that adding the Swarth extension has caused this widget to fail to function at all in any manner (including rendering it - even though as evidenced by Firefox it is present in the URL used for the start-page - and any attempt to add the said Widget (which should not be necessary considering the widget actually does exist in the start-page as evidenced by the Firefox screen-shot) the said Widget fails to be added as well in any manner as it should, all of which functioned properly prior to adding the Swarth extension.

This is very disturbing :eh: - please advise as to what to do to undo whatever Swarth has done to my start-page....

Please read followup below.
Last edited by Pallid Planetoid on 2022-06-03, 11:31, edited 2 times in total.
Current Pale Moon(x86) Release | WIN10 | I5 CPU, 1.7 GHz, 6GB RAM, 500GB HD[20GB SSD]
Formerly user Pale Moon Rising - to provide context involving embedded reply threads.
Good judgment comes from experience and a lot of that comes from bad judgment. - Will Rogers
Knowing Pale Moon is indisputably #1 is defined by knowing the totality of browsers. - Pale Moon Rising

User avatar
Pallid Planetoid
Knows the dark side
Knows the dark side
Posts: 4279
Joined: 2015-10-06, 16:59
Location: Los Angeles CA USA

Re: [Release] Swarth

Unread post by Pallid Planetoid » 2022-06-03, 08:16

^ Followup to above post - I have installed Swarth again (in the hope to undo the referenced issue) - this is what I found:

1) After installing the add-on again
2) I tried to undo a setting I had made in "Manage configured pages" - which was that I had set the setting near the top of this dialog page (just under the "Address" box) from the default (of which I don't recall what it was) to "Retain page style" - I did this based on the answer to my question HERE in this topic of which the answer was:
FranklinDM wrote:
2022-05-18, 07:34
Yes.

Go to Swarth's Preferences and set Default color method to Retain page style. With this, all sites will remain unmodified except for scopes whose color method is set to anything other than Retain page style.
- which is why I set the drop-down mentioned to "Retain page style".

continuing on....
3) I found this drop-down value to still be "Retain page style" (after re-installing the add-on) as opposed to whatever the default had been previously.
4) Unfortunately I found that the drop-down was unresponsive - I was unable to change the value of the drop-down as there was no response to clicking on the drop-down.
5) At this point I disabled the add-on within it's own settings by unchecking "Enable Swarth" in the "General" Preferences to see if this would help resolve my issue with the said missing Widget in Pale Moon.
6) I then checked to see if said Widget rendered successfully at this stage and was pleased to find that it did now render on the page (that had formerly not rendered or function properly as of the initial install).

At this point - I'm frankly hesitant to try anything further - as I've got my start-page back the way it should be (with "Enable Swarth" unchecked) in as much as the add-on is set to "disabled".

So what to do now?

Questions as it stands now:
1) Why is the drop-down (that is presently set to "Retain page style") unresponsive?
2) Any idea as to what is the cause of what has transpired (as referenced in the prior post)?

My goal, or should I say expectation, was to have Swarth not impact any websites at all from the start and then for sites I want Swarth to render as "dark" - I would presumably add them to a Swarth list of sites to render as "dark". As you can see my start-page does not need Swarth (and in fact with Swarth impacting my start-page not only did I have the issue discussed here - but the page does not render well at all the way Swarth impacts the page). I'm assuming there will be other websites that may not render that well either (which is why my expectation was to have Swarth start-out by not impacting any sites at all until I set Swarth to do otherwise).

To clarify, I was hoping that Swarth would, from the start, by default not impact any sites at all unless I had previously enabled Swarth to change any specific sites as specified by me.

Any recommendation on what I should do going forward?

Possible Options:
1) leave well enough alone and remove Swarth (assuming this would not produce any undesirable results).
2) setup Swarth the way I wanted it to work (which is to be agnostic for all sites unless I tell Swath otherwise).

I would like to have Swarth work properly w/out any issues of this kind..... :think: (and to be sure, by default - not change any web-pages from the get-go unless I say so...) In other words - should perhaps the extension start-out by default as disabled (to initially avoid unintended consequences) or at least start-out by default in a way that no pages will be impacted (changed) until otherwise directed to do so by the user???

The one thing I do know is that I do not want to repeat the issue that occurred previously in as much as I had reloaded the page numerous times and got the same undesirable result in regards to the missing said widget that never did successfully render - that is until I re-installed Swarth and disabled the add-on by unchecking the add-ons "Enable Swarth" option. It's certainly a big relief to presumably get things back to "normal" thankfully... :relaxed:

I'm leaving things at this point for now and will wait for a reply (will continue test my START.ME START-PAGE <<< an FYI - link back to when START.ME first became the "official" default start-page for Pale Moon, to make sure the issue is now most assuredly resolved) and not add any further topic comments unless I find the issue has returned.
Current Pale Moon(x86) Release | WIN10 | I5 CPU, 1.7 GHz, 6GB RAM, 500GB HD[20GB SSD]
Formerly user Pale Moon Rising - to provide context involving embedded reply threads.
Good judgment comes from experience and a lot of that comes from bad judgment. - Will Rogers
Knowing Pale Moon is indisputably #1 is defined by knowing the totality of browsers. - Pale Moon Rising

User avatar
FranklinDM
Add-ons Team
Add-ons Team
Posts: 570
Joined: 2017-01-14, 02:40
Location: Philippines
Contact:

Re: [Release] Swarth

Unread post by FranklinDM » 2022-06-05, 05:45

Pallid Planetoid wrote:
2022-06-03, 08:16
1) Why is the drop-down (that is presently set to "Retain page style") unresponsive?
2) Any idea as to what is the cause of what has transpired (as referenced in the prior post)?
1) I can't really say for sure, are there any messages in the Error Console when this happens?
2) It is possible that this is a caching issue (Ctrl + F5 should do the trick for most cases, which forces a "hard" refresh). As a workaround, you might want to try resetting Swarth via the preferences and removing all scopes, then try again.

User avatar
nguyen9173
Banned user
Banned user
Posts: 95
Joined: 2022-06-02, 13:38

Re: [Release] Swarth

Unread post by nguyen9173 » 2022-06-15, 14:45

FranklinDM wrote:
2022-06-03, 04:03
nguyen9173 wrote:
2022-06-02, 18:13
Could you make your addon work with SeaMonkey, too?
I'm not willing to introduce official support for non-UXP applications, such as SeaMonkey. However, patches are welcome, and if it breaks in that application, someone else other than me must fix it.
nguyen9173 wrote:
2022-06-02, 18:13
It will not save site preferences if the preferences were modified on the private window. It only saves the preferences made on normal window.
Go to Swarth's preferences and enable Keep scope changes in private browsing mode.
Screenshot 2022-06-03 120154.png
So this is the designed behavior. Sorry for the inconvenient :(

User avatar
FranklinDM
Add-ons Team
Add-ons Team
Posts: 570
Joined: 2017-01-14, 02:40
Location: Philippines
Contact:

Re: [Release] Swarth

Unread post by FranklinDM » 2022-06-28, 11:51

Update to Swarth: v1.0.6
  • Guard against document shells that are either null or does not have any children
  • Implement support for Pale Moon 31 and restore support for Basilisk
Update options: Fresco, APO, Basilisk Add-ons, check for updates using the Add-ons Manager.

User avatar
FranklinDM
Add-ons Team
Add-ons Team
Posts: 570
Joined: 2017-01-14, 02:40
Location: Philippines
Contact:

Re: [Release] Swarth

Unread post by FranklinDM » 2022-07-27, 09:59

Update to Swarth: v1.0.7
  • Don't launch preferences window as modal from the toolbar button.
    • This should resolve issues with the frozen/stuck color picker on Linux and other platforms that use GTK.
Update options: Fresco, APO, Basilisk Add-ons, check for updates using the Add-ons Manager.

User avatar
FranklinDM
Add-ons Team
Add-ons Team
Posts: 570
Joined: 2017-01-14, 02:40
Location: Philippines
Contact:

Re: [Release] Swarth

Unread post by FranklinDM » 2023-01-27, 08:59

Update to Swarth: v1.0.8
  • Exclude uBlock Origin's element picker from scope application.
    • This also adds a hidden preference to adjust the delay before checking if the current page is uBlock Origin's element picker overlay (extensions.swarth.compatibility.ubo_epicker_check_delay)
  • Mark as compatible with Pale Moon 32.
Update options: Fresco, APO, Basilisk Add-ons, check for updates using the Add-ons Manager.

Locked