[bug] zoom.minPercent > 100

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
biopsin
Fanatic
Fanatic
Posts: 122
Joined: 2016-02-07, 17:15

[bug] zoom.minPercent > 100

Unread post by biopsin » 2020-03-14, 14:14

I've noticed that if I set a zoom.minPercent value above 100 and after restarting of PM,
error is printed in console after 5 sec
Timestamp: 03/10/2020 12:06:38 PM
Error: A promise chain failed to handle a rejection. Did you forget to '.catch', or did you forget to 'return'?
See https://developer.mozilla.org/Mozilla/J ... sm/Promise

Date: Tue Mar 10 2020 12:06:34 GMT+0100 (CET)
Full Message: 2147942487
Full Stack: JS frame :: resource://gre/modules/Promise.jsm -> resource://gre/modules/Promise-backend.js :: register :: line 194
JS frame :: resource://gre/modules/Promise.jsm -> resource://gre/modules/Promise-backend.js :: completePromise :: line 715
JS frame :: resource://gre/modules/Promise.jsm -> resource://gre/modules/Promise-backend.js :: process :: line 968
JS frame :: resource://gre/modules/Promise.jsm -> resource://gre/modules/Promise-backend.js :: walkerLoop :: line 813
JS frame :: resource://gre/modules/Promise.jsm -> resource://gre/modules/Promise-backend.js :: scheduleWalkerLoop/< :: line 747
voidlinux_x64 glibc-2.78 / selfcompiled latest Palemoon (gcc-13.2.0) / GTK2

User avatar
adesh
Board Warrior
Board Warrior
Posts: 1277
Joined: 2017-06-06, 07:38

Re: [bug] zoom.minPercent > 100

Unread post by adesh » 2020-03-15, 09:53

That looks like a very generic error message and can be caused in a lot of situations which can throw exceptions. Are you sure you don't see this error if you reset minPercent?

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

Re: [bug] zoom.minPercent > 100

Unread post by therube » 2020-03-15, 10:58

If you reset zoom.minPercent, then the messages are not logged.

User avatar
biopsin
Fanatic
Fanatic
Posts: 122
Joined: 2016-02-07, 17:15

Re: [bug] zoom.minPercent > 100

Unread post by biopsin » 2020-03-15, 15:37

I would not post this otherwise.
Can I read from your comments that you both tested it and you both don't see this in console?
voidlinux_x64 glibc-2.78 / selfcompiled latest Palemoon (gcc-13.2.0) / GTK2

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35597
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: [bug] zoom.minPercent > 100

Unread post by Moonchild » 2020-03-16, 08:40

The important part of the message (the code location) was not included in your posted error message.

I'm pretty sure what happens here is that by setting this value, the default zoom value (100%) falls outside of the acceptable range which causes a failure on a deferred task.
Why are you setting this to > 100% to begin with? There is no reason for that as it indicates your overall minimum allowed zoom level which should always be 100 or less (same with max, which should always be 100 or more).
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

User avatar
biopsin
Fanatic
Fanatic
Posts: 122
Joined: 2016-02-07, 17:15

Re: [bug] zoom.minPercent > 100

Unread post by biopsin » 2020-03-16, 11:30

Hey,
You mean in about:config?
Since I switched to a 4K 32" monitor all pages are uber-tiny, setting minimum zoom to 170, I can quickly zoom in on page with ctrl-0.
So how come zoom.maxPercent is set at 300% without error in console?.
Last edited by biopsin on 2020-03-16, 11:45, edited 1 time in total.
voidlinux_x64 glibc-2.78 / selfcompiled latest Palemoon (gcc-13.2.0) / GTK2

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35597
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: [bug] zoom.minPercent > 100

Unread post by Moonchild » 2020-03-16, 11:37

The correct solution is setting your system's DPI to the proper value, so "100%" is normal size.
biopsin wrote:
2020-03-16, 11:30
So how come zoom.maxPercent is set at 300% without error in console?.
...because max should be > 100 which it is.
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

User avatar
biopsin
Fanatic
Fanatic
Posts: 122
Joined: 2016-02-07, 17:15

Re: [bug] zoom.minPercent > 100

Unread post by biopsin » 2020-03-16, 12:12

I did check with xrandr and also included the output of cvt -r 3840 2160 60 into xorg.conf for the sake of it, but I don't see any difference.
will continue tinker with the system some more, if not guess I'll leave 170 and ignore the message in console, at least I know why it's printed.
voidlinux_x64 glibc-2.78 / selfcompiled latest Palemoon (gcc-13.2.0) / GTK2

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35597
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: [bug] zoom.minPercent > 100

Unread post by Moonchild » 2020-03-16, 14:30

I'm not a Linux person so I don't know what that command does but it doesn't seem to actually do anything for dpi (which at your screen size and res should be set higher than whatever is default, since your pixel density is considerably higher).
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

User avatar
Lootyhoof
Themeist
Themeist
Posts: 1569
Joined: 2012-02-09, 23:35
Location: United Kingdom

Re: [bug] zoom.minPercent > 100

Unread post by Lootyhoof » 2020-03-16, 15:53

You could set layout.css.devPixelsPerPx to 1.70 in about:config to get a similar effect.

User avatar
biopsin
Fanatic
Fanatic
Posts: 122
Joined: 2016-02-07, 17:15

[solved] zoom.minPercent > 100

Unread post by biopsin » 2020-03-16, 17:34

Lootyhoof wrote:
2020-03-16, 15:53
You could set layout.css.devPixelsPerPx to 1.70 in about:config to get a similar effect.
I could, but it scales everything up and PM window is fine as it is..
it also works setting toolkit.zoomManager.zoomValues with fewer values;
ctrl+ jumps straight to 170% and ctrl+mousewheel for finnishing touches if needed.
Anyways thanks for the suggestion and feedback.
voidlinux_x64 glibc-2.78 / selfcompiled latest Palemoon (gcc-13.2.0) / GTK2

Locked