Problem with text buttons installed by extensions and Flexible Space Topic is solved

This board is for discussions, bug reports, etc. for pre-releases of the v28 milestone building on UXP.
User avatar
JoeyG
Astronaut
Astronaut
Posts: 655
Joined: 2017-06-12, 13:27
Location: How can you be in two places at once, when you're not anywhere at all?

Problem with text buttons installed by extensions and Flexible Space

Unread post by JoeyG » 2018-06-29, 21:42

From the outset, I'd like to state that I'm not posting this to "complain" in any sense. I'm simply seeking to bring the "problem" to the attention of anyone out there who might be interested. I do NOT expect a "fix", nor am I requesting one.

The reason I'm even mentioning it is because the issue doesn't occur in the PaleMoon release or Basilisk. By the way, it started (I think) with the next-to-last update of the unstable version. And, yes, I know that it's an "unstable" version.

------------------------------------------------------------------------------------------

Anyway, what I'm trying to achieve is for the items in my Menu Bar to be centered.

I hope these three screenshots will illustrate what's happening in the unstable version.
Image
In the top one, you can see that to the left of the Menu Bar, I have numerous "Spaces" and to the right a single Flexible Space. You can also see the four "text buttons" installed by some of the extensions I use. (And yes, I'm one of the only people in the Universe who uses PaleMoon's "Text Only" option.)

In the middle one, you can see how it should be. And when I place the flexible space to the right and then close the "Customize Browser" panel. It works fine for the rest of my session.

The "problem" occurs when I close and reopen the browser. In the bottom image, you see what happens: Somehow, of its own accord, the flexible space "hops" to the left of the four text buttons in question.

Of course I realize that my browser desktop is pretty weird and that this might be related to the full theme I use (Red Cats, Green Flavor).

Thanks for reading this. I'm looking forward to reading your observations.

P.S. I wonder if this is related to the issue mentioned in the thread "Appearance addon not displayed properly" by cartel (29 Jun 2018, 00:46)
Last edited by JoeyG on 2018-06-29, 21:53, edited 3 times in total.
"And you can believe me because I never lie - and I'm always right."
(Asserted by George Leroy Tirebiter* and my wife; only the latter is telling the truth.)
*Firesign Theater version

GMforker

Re: Problem with text buttons installed by extensions and Flexible Space

Unread post by GMforker » 2018-06-30, 06:59

AFAIK: This is an extension issue. customize_titlebar_v2 ? - Unfortunately, I don't have his code now (viewtopic.php?f=37&p=132116#p132116)...
Last edited by GMforker on 2018-06-30, 07:00, edited 1 time in total.

User avatar
JoeyG
Astronaut
Astronaut
Posts: 655
Joined: 2017-06-12, 13:27
Location: How can you be in two places at once, when you're not anywhere at all?

Re: Problem with text buttons installed by extensions and Flexible Space

Unread post by JoeyG » 2018-06-30, 11:40

GMforker wrote:AFAIK: This is an extension issue. customize_titlebar_v2 ?
Thank you for your reply.

1. I've now removed (not disabled) the extension you mentioned, but the problem still exists.
2. As I wrote in my original post, the problem doesn't exist in "normal" PM, only the unstable version.
3. A bit more experimentation revealed that a brand-new profile in which neither "customize_titlebar_v2" nor my third-party theme is installed manifests the exact same problem.
4. Now I'm pretty sure it's a bug that was introduced rather recently to the unstable builds.

My justification for writing this is
a) I just downloaded "palemoon-unstable-latest.win64.portable".
b) I installed only one extension (Cookie Shield 0.4.0), which I know adds its own button to the Navigation Bar.
c) I moved the button to the Menu Bar.
d) I added Flexible Spaces to the left and right and restarted the browser.
e) When it reopened, the added button was all the way to the right, confirming the problem.

I'm going to file a bug on GitHub ...
Last edited by JoeyG on 2018-06-30, 11:41, edited 1 time in total.
"And you can believe me because I never lie - and I'm always right."
(Asserted by George Leroy Tirebiter* and my wife; only the latter is telling the truth.)
*Firesign Theater version

User avatar
JoeyG
Astronaut
Astronaut
Posts: 655
Joined: 2017-06-12, 13:27
Location: How can you be in two places at once, when you're not anywhere at all?

Re: Problem with text buttons installed by extensions and Flexible Space

Unread post by JoeyG » 2018-06-30, 14:27

First the bad news: The problem still exists in today's update: 28.0.0b2 (unstable/portable -2018-07-01).

Now the good news: One of the devs, who wrote she or he knows the cause of the bug, has just contacted me (via GitHub) and will look at it.

My most sincere thanks to this person ("janekptacijarabaci"???).
Last edited by JoeyG on 2018-06-30, 15:08, edited 2 times in total.
"And you can believe me because I never lie - and I'm always right."
(Asserted by George Leroy Tirebiter* and my wife; only the latter is telling the truth.)
*Firesign Theater version

JustOff

Re: Problem with text buttons installed by extensions and Flexible Space

Unread post by JustOff » 2018-06-30, 20:00

It turns out that this problem occurs because of a fault in the button positioning code that I wrote to support sdk-based add-ons in Pale Moon. I'll deal with it.

PS: Thanks @janekptacijarabaci, who also known as GMforker ;)

User avatar
JoeyG
Astronaut
Astronaut
Posts: 655
Joined: 2017-06-12, 13:27
Location: How can you be in two places at once, when you're not anywhere at all?

Re: Problem with text buttons installed by extensions and Flexible Space

Unread post by JoeyG » 2018-06-30, 20:14

JustOff wrote:It turns out that this problem occurs because of a fault in the button positioning code that I wrote to support sdk-based add-ons in Pale Moon. I'll deal with it.
Thanks for your reply.

It was I who filed the bug, so I've been following the GitHub messages. I think it's great that you all have jumped on it so fast.

Even though it's a "bug", I'm not sure if anyone else but me would have ever noticed it. I mean, centering the items on the Menu Bar doesn't seem to be a thing that many people do.

If I may say so, I consider this incident to be a great example of the beauty of the PaleMoon/Basilisk initiative. I'm really happy I made the jump from Firefox. I feel bad, though, that I don't have anything more constructive to offer than my good wishes.

In any case, thanks to you JustOff, to GMForker, and to everybody who's working on this very nice browser.
"And you can believe me because I never lie - and I'm always right."
(Asserted by George Leroy Tirebiter* and my wife; only the latter is telling the truth.)
*Firesign Theater version

User avatar
JoeyG
Astronaut
Astronaut
Posts: 655
Joined: 2017-06-12, 13:27
Location: How can you be in two places at once, when you're not anywhere at all?

Re: Problem with text buttons installed by extensions and Flexible Space

Unread post by JoeyG » 2018-07-05, 22:27

After today's (06 July 2018) update to the unstable release, I re-installed the three buttons that were produced by the Toolbar Buttons extension (v 1.1.1) from this site, which indicates they work in Pale Moon.
https://codefisher.org/toolbar_button/t ... ton_maker/

I'm happy to report that the issue in regard to the buttons' interaction with the Flexible Space has now been resolved.

My thanks, again, to the people who have responded to this posting and to the individual who kindly updated the code for today's unstable version in regard to this problem.
Last edited by JoeyG on 2018-07-05, 23:37, edited 3 times in total.
"And you can believe me because I never lie - and I'm always right."
(Asserted by George Leroy Tirebiter* and my wife; only the latter is telling the truth.)
*Firesign Theater version

doofy
Astronaut
Astronaut
Posts: 650
Joined: 2017-08-14, 23:43

Re: Problem with text buttons installed by extensions and Flexible Space

Unread post by doofy » 2018-07-06, 00:32

JoeyG wrote: I'm happy to report that the issue in regard to the buttons' interaction with the Flexible Space has now been resolved.

My thanks, again, to the people who have responded to this posting and to the individual who kindly updated the code for today's unstable version in regard to this problem.
I'm really impressed by this thread.

You could easily be the only person on earth who would have encountered this behaviour, and it was resolved inside a week. Respect, etc...

GMforker

Re: Problem with text buttons installed by extensions and Flexible Space

Unread post by GMforker » 2018-07-06, 04:46

Thanks also, @JustOff

And you are welcome.

But some (other) bugs are not easy at all... :)

User avatar
JoeyG
Astronaut
Astronaut
Posts: 655
Joined: 2017-06-12, 13:27
Location: How can you be in two places at once, when you're not anywhere at all?

Re: Problem with text buttons installed by extensions and Flexible Space

Unread post by JoeyG » 2018-07-06, 10:17

doofy wrote:I'm really impressed by this thread.

You could easily be the only person on earth who would have encountered this behaviour, and it was resolved inside a week. Respect, etc...
I repeat my sincere gratitude to all involved.

The browser Universe is a complex space; I'm very happy to have PM and Basilisk in my little corner of it.
"And you can believe me because I never lie - and I'm always right."
(Asserted by George Leroy Tirebiter* and my wife; only the latter is telling the truth.)
*Firesign Theater version

JustOff

Re: Problem with text buttons installed by extensions and Flexible Space

Unread post by JustOff » 2018-07-06, 13:35

JoeyG wrote:After today's (06 July 2018) update to the unstable release
You are lucky 8-)
I re-installed the three buttons that were produced by the Toolbar Buttons extension (v 1.1.1) from this site, which indicates they work in Pale Moon.

I'm happy to report that the issue in regard to the buttons' interaction with the Flexible Space has now been resolved.
Actually your problem was only with CookieShield, which is based on Add-on SDK, while the Toolbar Buttons extension(s) use the classic XUL technology to create buttons and so they are not affected by this issue.

User avatar
JoeyG
Astronaut
Astronaut
Posts: 655
Joined: 2017-06-12, 13:27
Location: How can you be in two places at once, when you're not anywhere at all?

Re: Problem with text buttons installed by extensions and Flexible Space

Unread post by JoeyG » 2018-07-06, 14:12

JustOff wrote:
JoeyG wrote:After today's (06 July 2018) update to the unstable release
You are lucky 8-)
I just updated internally, and the magic happened by itself.
JustOff wrote:
JoeyG wrote:I re-installed the three buttons that were produced by the Toolbar Buttons extension (v 1.1.1) from this site, which indicates they work in Pale Moon.

I'm happy to report that the issue in regard to the buttons' interaction with the Flexible Space has now been resolved.
Actually your problem was only with CookieShield, which is based on Add-on SDK, while the Toolbar Buttons extension(s) use the classic XUL technology to create buttons and so they are not affected by this issue.
Well, if you really want to know, it didn't go sooooooooooo smoothly.

When I first updated PM unstable and checked to see if things had been fixed, I was pleasantly surprised to see that the "Cookie Shield" button was indeed where it was supposed to be. However, the three buttons produced by "Toolbar Maker" were still way over to the right, and the Flexible Space had somehow moved to the left of them again. That is, the Flexible Space was now between the "Cookie Shield" button and the "New Tab", "Minimum Font Size", and "Page Fonts" buttons.

It was at that point that I decided to delete the latter three, as well as the Flexible Space, and start from scratch.

I then went to the Toolbar Buttons website and checked the three buttons I wanted to have. They installed as expected. Next I put the Flexible Space Back where I wanted it.

Then I restarted the browser and held my breath.

Lo and behold everything was OK. :clap:

Just to make sure I wasn't hallucinating, I restarted PM unstable yet again.

As the poem says, "O frabjous day! Callooh! Callay! He chortled in his joy."

Now I'm a happy camper again.
Last edited by JoeyG on 2018-07-06, 14:13, edited 1 time in total.
"And you can believe me because I never lie - and I'm always right."
(Asserted by George Leroy Tirebiter* and my wife; only the latter is telling the truth.)
*Firesign Theater version

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

Re: Problem with text buttons installed by extensions and Flexible Space

Unread post by Moonchild » 2018-07-06, 14:36

JoeyG wrote:Now I'm a happy camper again.
Here's your new avatar image:
4c45b796f9f63a9d05442616a690b49c.jpg
Last edited by Moonchild on 2018-07-06, 15:11, edited 1 time in total.
"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
JoeyG
Astronaut
Astronaut
Posts: 655
Joined: 2017-06-12, 13:27
Location: How can you be in two places at once, when you're not anywhere at all?

Re: Problem with text buttons installed by extensions and Flexible Space

Unread post by JoeyG » 2018-07-06, 14:56

Moonchild wrote:
JoeyG wrote:Now I'm a happy camper again.
Here's your new avatar image: ...
Thanks, but if no one minds, I'll stay with the current one.
Last edited by JoeyG on 2018-07-06, 14:57, edited 1 time in total.
"And you can believe me because I never lie - and I'm always right."
(Asserted by George Leroy Tirebiter* and my wife; only the latter is telling the truth.)
*Firesign Theater version

User avatar
JoeyG
Astronaut
Astronaut
Posts: 655
Joined: 2017-06-12, 13:27
Location: How can you be in two places at once, when you're not anywhere at all?

Re: Problem with text buttons installed by extensions and Flexible Space

Unread post by JoeyG » 2018-07-10, 23:00

After a couple of days of testing, I've discovered that the "fix" to my problem seems to have caused another issue.

It's kind of hard to describe, but the combination of the fix, the Flexible Spaces to the left and right of the Menu Bar, and the buttons added with the Toolbar Buttons addon appear to cause the window of the two latest unstable builds to reopen with a different size than what was on the screen when the browser closed.

This occurs both when using the Restart function and when the browser is closed with the "x" in the top right corner.

It definitely doesn't happen with a new profile, so it seems to be due to my "strange" customizations.

I'm not going to file a bug on GitHub. I just thought I'd mention it in case anyone else sees anything that might somehow be related.
Last edited by JoeyG on 2018-07-10, 23:02, edited 1 time in total.
"And you can believe me because I never lie - and I'm always right."
(Asserted by George Leroy Tirebiter* and my wife; only the latter is telling the truth.)
*Firesign Theater version

GMforker

Re: Problem with text buttons installed by extensions and Flexible Space

Unread post by GMforker » 2018-07-11, 05:45

This: base/content/browser.xul#L62 remains the same (and generally - I don't see any such change in the code).
Maybe you have something (an extension) overwriting the value "main-window" (width, height...) in "xulstore.json" (in the profile folder) - e.g. using the command "XULStore.setValue...".

I tried different things and I can not confirm it (with the Toolbar Buttons addon - with one random button and several the Flexible Spaces).

Locked