SeaFox - Development

Talk about add-ons and extension development.
Post Reply
Exalm
Posts: 137
Joined: July 28th, 2013, 3:29 pm

Re: [ext/dev] SeaFox - convert SeaMonkey into Firefox 3.x

Post by Exalm »

patrickjdempsey wrote:When they did the new Addons Manager, they didn't just rearrange and restyle the existing components like they did with the FindBar... this is a totally new implementation with it's own new hooks and all kinds of weird things happening in the styling. Which means you can't just drop the old addons manager code in. When I maintained my old Firefox Stratini themes, I seriously hacked the Addons Manager to look like this:

-snip-

It is still in a tab, but uses far less space and looks a little more like the old way. The problem is that doing something like this in an extension makes it not work well with Themes. And with my Themes, several popular addons manager modifying extensions where broken by my hacks. Getting something like that to work properly is a huge project that deserves it's own extension... the fact that there are multiple ones out there, all of which fail to do the job properly should give some indication of what a mess it is. ;)
Oh, I didn't know that it was re-implemented.

Well, in this case I think I'll just make a contribution to https://addons.mozilla.org/en-US/seamon ... n-manager/ so that the old addon manager is at least available.

Here's what I did by changing some attributes with DOM Inspector:
https://dl.dropboxusercontent.com/u/367 ... anager.png
That already looks pretty close, except that there is no bar on the bottom, and themes don't have preview pane (Are the previews even used anywhere now?). There are some problems, like when hidden categories don't shrink, but it can be fixed easily when modifying the files themselves. Also fake overlay scrollbars style causes some glitches, but they happen with the default manager as well. And Linux styling (native color for selected category, and -moz-appearance for most elements) is not there, but that's easy to fix.
User avatar
patrickjdempsey
Posts: 23686
Joined: October 23rd, 2008, 11:43 am
Location: Asheville NC
Contact:

Re: [ext/dev] SeaFox - convert SeaMonkey into Firefox 3.x

Post by patrickjdempsey »

If you want to really dig into it, I documented all of the work I did on my Stratini theme here:
viewtopic.php?f=18&t=1968575

Note that this is all very old, from over 2 years ago and it's very likely that much of that no longer works... as Mozilla has probably changed all of the names of things a dozen times since then, because they love doing that for some reason.

And no, "previews" were abandoned with Firefox 4.0/SeaMonkey 2.1... the images you see in the "details" pane are ripped from the addons.mozilla.org site.
Tip of the day: If it has "toolbar" in the name, it's crap.
What my avatar is about: https://addons.mozilla.org/en-US/seamonkey/addon/sea-fox/
Exalm
Posts: 137
Joined: July 28th, 2013, 3:29 pm

Re: [ext/dev] SeaFox - convert SeaMonkey into Firefox 3.x

Post by Exalm »

patrickjdempsey wrote:If you want to really dig into it, I documented all of the work I did on my Stratini theme here:
viewtopic.php?f=18&t=1968575

Note that this is all very old, from over 2 years ago and it's very likely that much of that no longer works... as Mozilla has probably changed all of the names of things a dozen times since then, because they love doing that for some reason.

And no, "previews" were abandoned with Firefox 4.0/SeaMonkey 2.1... the images you see in the "details" pane are ripped from the addons.mozilla.org site.
Thanks for the link. Used parts of your binding and styles, and now I have this:
Image

The next step is moving the bar on top to the bottom and replacing dropdown with some buttons. And removing Back/Forward buttons.

//Russian translator of Greasemonkey is a... bad person. Just "Скрипты" would be enough, and this works especially bad with the default layout where Greasemonkey's label makes categories take much more space than needed.
User avatar
patrickjdempsey
Posts: 23686
Joined: October 23rd, 2008, 11:43 am
Location: Asheville NC
Contact:

Re: [ext/dev] SeaFox - convert SeaMonkey into Firefox 3.x

Post by patrickjdempsey »

Progress: changed the method of rearranging the toolbars. In the old method, I did basically what the browser does when you hit the Restore Default Set button... I forced a list of buttons onto the toolbar, removing anything else. This is simple and easy, but it removes any customization the user has done as well as buttons placed into the toolbar by extensions, which the user may not understand how to move back. Now I'm using a regex match and replace method. I've split the nav-bar into two groups: the back/forward/reload/stop/home group, and the urlbar/splitter/searchbar group. Other extension icons can sit before or after these groups. The go-button, search-button, throbber and print-button are removed.
Tip of the day: If it has "toolbar" in the name, it's crap.
What my avatar is about: https://addons.mozilla.org/en-US/seamonkey/addon/sea-fox/
Exalm
Posts: 137
Joined: July 28th, 2013, 3:29 pm

Re: [ext/dev] SeaFox - convert SeaMonkey into Firefox 3.x

Post by Exalm »

patrickjdempsey wrote:Progress: changed the method of rearranging the toolbars. In the old method, I did basically what the browser does when you hit the Restore Default Set button... I forced a list of buttons onto the toolbar, removing anything else. This is simple and easy, but it removes any customization the user has done as well as buttons placed into the toolbar by extensions, which the user may not understand how to move back. Now I'm using a regex match and replace method. I've split the nav-bar into two groups: the back/forward/reload/stop/home group, and the urlbar/splitter/searchbar group. Other extension icons can sit before or after these groups. The go-button, search-button, throbber and print-button are removed.

Shouldn't the throbber be at the end of menubar by default?
User avatar
patrickjdempsey
Posts: 23686
Joined: October 23rd, 2008, 11:43 am
Location: Asheville NC
Contact:

Re: [ext/dev] SeaFox - convert SeaMonkey into Firefox 3.x

Post by patrickjdempsey »

That looks pretty good! Moving the header to the bottom shouldn't be a problem, although you might have to fix some of the padding/margins: #header {-moz-box-ordinal-group:10!important;}

And 25 characters for a category name is pretty ridiculous but you can crop the names like this:

Code: Select all

.category { 
display: block;
overflow:hidden;
text-overflow: ellipsis;
white-space:nowrap;
}
.category-name {
width:6em!important;
}
Tip of the day: If it has "toolbar" in the name, it's crap.
What my avatar is about: https://addons.mozilla.org/en-US/seamonkey/addon/sea-fox/
Exalm
Posts: 137
Joined: July 28th, 2013, 3:29 pm

Re: [ext/dev] SeaFox - convert SeaMonkey into Firefox 3.x

Post by Exalm »

More progress on the old addon manager.
Looks not like a big difference, but in fact this has been rewritten from scratch, only using the categories binding from the previous implementation:
Image
The reason is that while doing that I refactored Classicish Addon Manager way too much, so contributing it back became almost impossible, so I decided to drop it completely.

However, themes now have to support it explicitly, because I override chrome://mozapps/skin/extensions/extensions.css completely (so that I don't have to fight with in-content-UI style). However, I don't think they worked perfectly with the previous one either, because the difference is large enough for most themes to look wrong.
Modern looks pretty good though, so at least some themes work well.

Additionally, for me this doesn't lag when scrolling, unlike the default addon manager, because the buttons are only visible on the selected addon.

Perhaps I should open a separate thread for this...

Edit: tweaked margins a bit and it's REALLY similar:
https://dl.dropboxusercontent.com/u/367 ... nager4.png (Large image, so it's not embedded)
Of course, bits of the new addon manager, like the new discover page or addon description pop up in many places, but the old look & feel that I love is back. :)
User avatar
patrickjdempsey
Posts: 23686
Joined: October 23rd, 2008, 11:43 am
Location: Asheville NC
Contact:

Re: [ext/dev] SeaFox - convert SeaMonkey into Firefox 3.x

Post by patrickjdempsey »

Yeah, looks good. The binding really is the only thing required, from then it's all style. I think a great deal of the stuff in my old thread no longer applies because they've made so many changes to it. You are right that the appropriate place for such an implementation is the theme... mostly due to the hacky nature of the way it was built in Firefox originally... probably why the SeaMonkey devs didn't bother changing it. Totally abandoning classic UI elements rendering was IMO just bad design and programming all around. The new Findbar has similar problems.
Tip of the day: If it has "toolbar" in the name, it's crap.
What my avatar is about: https://addons.mozilla.org/en-US/seamonkey/addon/sea-fox/
User avatar
patrickjdempsey
Posts: 23686
Joined: October 23rd, 2008, 11:43 am
Location: Asheville NC
Contact:

Re: [ext/dev] SeaFox - convert SeaMonkey into Firefox 3.x

Post by patrickjdempsey »

Slowly but surely Sea Fox is making it's way through the submission queue. We'll see what kind of response it gets and then go from there. I'm guessing Mozilla won't like some of the things I'm doing so we'll just wait and see. ;)
Tip of the day: If it has "toolbar" in the name, it's crap.
What my avatar is about: https://addons.mozilla.org/en-US/seamonkey/addon/sea-fox/
Exalm
Posts: 137
Joined: July 28th, 2013, 3:29 pm

Re: [ext/dev] SeaFox - convert SeaMonkey into Firefox 3.x

Post by Exalm »

patrickjdempsey wrote:Slowly but surely Sea Fox is making it's way through the submission queue. We'll see what kind of response it gets and then go from there. I'm guessing Mozilla won't like some of the things I'm doing so we'll just wait and see. ;)
And already a thing to fix: you should remove the separator after Home button when you rearrange them on first run. Right now it remains there, so the Personal Toolbar starts from a separator.
Bookmarks menu should not remain there as well. Also the throbber should be placed at the end of the menubar.

Would you consider adding Firefox 3 theme (Proper theme, not the one on AMO)? It may be distributed as a bundle.
Oops, you have theme in goals. Sorry. Still, Strata is not the only Firefox 3 theme, there should also be a metallic one with round buttons for Mac, and a theme that uses native icons for Linux. (Something like GNOMErunner/GTK, but only for stock icons)

Also, I would suggest to make grippy removal optional, controlled by the same option as hiding other SeaMonkey features.
User avatar
patrickjdempsey
Posts: 23686
Joined: October 23rd, 2008, 11:43 am
Location: Asheville NC
Contact:

Re: [ext/dev] SeaFox - convert SeaMonkey into Firefox 3.x

Post by patrickjdempsey »

Separator after Home button already fixed for awhile now... I just haven't uploaded as stated above. Current users won't see this change without resetting the first-run scenario... will publish how to do that when the time comes.

Bookmarks menu button will remain. My goal is not 100% Firefox 3.x features. It's more like... a right sensible mix. It's easy enough to remove if you don't like it... nothing about customizing toolbar buttons is difficult... I'm only providing this feature as a shortcut towards sanity so to speak.

I honestly don't know anything about themes in Linux Land... I'm assuming there are commands that allow the default theme to use Linux window manager buttons, but I don't know anything about that implementation. And as far as OSX goes... I could care less... the Firelight theme was Mozilla's first attempt to blatantly copy the hideous Safari interface and IMO it was just step 1 towards the current default theme. IF I bother to build a theme it will be for my own amusement, for the OS's that I use, and the Components I use. As I've stated I was never a huge fan of the original Strata theme to begin with. It was incredibly inconsistent and was neither truly native nor wholly it's own thing. The very definition of mediocrity.
Tip of the day: If it has "toolbar" in the name, it's crap.
What my avatar is about: https://addons.mozilla.org/en-US/seamonkey/addon/sea-fox/
Exalm
Posts: 137
Joined: July 28th, 2013, 3:29 pm

Re: [ext/dev] SeaFox - convert SeaMonkey into Firefox 3.x

Post by Exalm »

patrickjdempsey wrote:Separator after Home button already fixed for awhile now... I just haven't uploaded as stated above. Current users won't see this change without resetting the first-run scenario... will publish how to do that when the time comes.

Bookmarks menu button will remain. My goal is not 100% Firefox 3.x features. It's more like... a right sensible mix. It's easy enough to remove if you don't like it... nothing about customizing toolbar buttons is difficult... I'm only providing this feature as a shortcut towards sanity so to speak.

I honestly don't know anything about themes in Linux Land... I'm assuming there are commands that allow the default theme to use Linux window manager buttons, but I don't know anything about that implementation. And as far as OSX goes... I could care less... the Firelight theme was Mozilla's first attempt to blatantly copy the hideous Safari interface and IMO it was just step 1 towards the current default theme. IF I bother to build a theme it will be for my own amusement, for the OS's that I use, and the Components I use. As I've stated I was never a huge fan of the original Strata theme to begin with. It was incredibly inconsistent and was neither truly native nor wholly it's own thing. The very definition of mediocrity.
It can't use Linux window manager buttons. Even Australis Fx does not draw in titlebar in Linux, and Chromium tries to implement its own titlebar, ending with a horrible blue titlebar that knows nothing about system theme and an option to disable it. That's because there is no one "default" window manager: there are lots of WMs, and they all have different titlebars. Titlebar may look like anything, it can be hidden (In various tiling WMs, for example), or you can even run without WM at all (But you will not be able to even focus windows, heh). Additionally, Wayland and Mir are coming, with their own systems with that. Firefox in fullscreen uses some generic icons with -moz-appearance: toolbarbutton.

As for icons from GTK theme, they can be used as this:
moz-icon://stock/gtk-go-up?size=toolbar&state=disabled (Where gtk-go-up is any icon (Fx only uses GTK stock icons though, but it's a convention, not a technical limitation), size — menu (16x16), button (16x16), toolbar (24x24), dialog (48x48). Toolbar size does not conform to Fx small icons, so both should be used in this case.
You can look in GNOMEunner/GTK Revived, it heavily uses that and looks pretty similar to the Fx3 theme, except that its goal is only integration, and Fx3 does integration while preserving general Fx style.

As for Firelight, IDK, looks pretty good for me. I don't use Mac though, so I don't exactly know how Safari looks.

If you don't want to do those, I can do. I care about them, and want to have a proper extension for all this. :)
User avatar
patrickjdempsey
Posts: 23686
Joined: October 23rd, 2008, 11:43 am
Location: Asheville NC
Contact:

Re: [ext/dev] SeaFox - convert SeaMonkey into Firefox 3.x

Post by patrickjdempsey »

Like I said, no clue how it works but I know Mozilla pulls (or at least used to?) buttons from the window manager so they will match other applications. I really only vaguely understand Linux terminology.

Progress: fixed the Identity Box so it properly displays tooltips and properly reacts to clicks to open the Page Info popup. Will need to do testing on various forms of broken encryption, untrusted connections etc to beef up security notifications.

Edit: position 10 in the Preliminary Review queue. Which hopefully means I'll be able to upload 0.1.5 before USA Turkey Day holiday.
Tip of the day: If it has "toolbar" in the name, it's crap.
What my avatar is about: https://addons.mozilla.org/en-US/seamonkey/addon/sea-fox/
User avatar
patrickjdempsey
Posts: 23686
Joined: October 23rd, 2008, 11:43 am
Location: Asheville NC
Contact:

Re: [ext/dev] SeaFox - convert SeaMonkey into Firefox 3.x

Post by patrickjdempsey »

Spent the evening beefing up the Identity box. It now displays the following styles:

-Normal website: nothing.

-Regular SSL: blue background, lock icon.

-EV SSL: green background, lock icon.

-Broken SSL: yellow background, broken lock icon.

-Untrusted Connection: yellow background, broken lock icon, !warning icon.

-Reported Web Forgery/Attack Site: dark red background, blacklist icon.

This goes above and beyond the current or Firefox 3.x identity-box imagery because I feel like this is important stuff. Note: this might break Modern and other themes that use super skinny urlbars. I will work on compatibility stuff in the future.
Tip of the day: If it has "toolbar" in the name, it's crap.
What my avatar is about: https://addons.mozilla.org/en-US/seamonkey/addon/sea-fox/
User avatar
patrickjdempsey
Posts: 23686
Joined: October 23rd, 2008, 11:43 am
Location: Asheville NC
Contact:

Re: [ext/dev] SeaFox - convert SeaMonkey into Firefox 3.x

Post by patrickjdempsey »

Well, Sea Fox has now been Preliminary Reviewed. Soon I'll upload version 0.1.5 which contains a truck-ton of changes. Have begun work on theme compatibility in order to properly support Modern. My plan is to offer three complete sets of icons: Default, Modern, and Strata. This will make the install size of Sea Fox appear to triple, however only half will be loaded into memory at a time. In addition to icons, the three themes will have slightly different support for the identity box, including different margins and different colors.

Gray Modern uses a rather weird overlay system so it will use the Modern icons and styles... although currently it doesn't appear to actually work as advertised anyway. If it is fixed by the developer, I will have Sea Fox direct it to use Modern icons and styles.

I'm directing Early Blue to use the Modern icons and styles.

The Firefox 3 theme for SeaMonkey will use the Strata icons and styles.

The nice thing about the system I'm using for this is that should the author of any of these themes decide to implement their own buttons and styles to support Sea Fox, it shouldn't be much of a hassle for them. I'll provide the code and instruction required.
Tip of the day: If it has "toolbar" in the name, it's crap.
What my avatar is about: https://addons.mozilla.org/en-US/seamonkey/addon/sea-fox/
Post Reply