MozillaZine

How does this work please? = SORTED

Discussion of general topics about Mozilla Firefox
madmudmob

User avatar
 
Posts: 710
Joined: August 30th, 2006, 7:34 am
Location: Somerset, UK

Post Posted August 27th, 2017, 7:27 am

I came across this which (I think) adds the capability to add extra spaces to my location bar via Customisation. I added it as a new UserStyle to my Stylish but can't seem to find how it works as there is no mention of it in Customisation.
Could some kind person help me please or tell me if I'm on the wrong track?
(I don't have Classic Theme Restorer installed if that is anything to do with it?).
Code: Select all
@namespace url(http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul);

@-moz-document url(chrome://browser/content/browser.xul) {
            
   /* spaces, flexible spaces, separators on toolbars in customizing mode */
   /* on palette */
   toolbarpaletteitem[place="palette"] > toolbarspring{
     background: url("chrome://classic_theme_restorer/content/images/flex_space.png") white center no-repeat;
     border: 1px solid black !important;
   }

   toolbarpaletteitem[place="palette"] > toolbarspacer{
     background: url("chrome://classic_theme_restorer/content/images/space1.png") center no-repeat;
   }
   
   toolbarpaletteitem[place="palette"] > toolbarseparator{
     background: url("chrome://classic_theme_restorer/content/images/separator.png") center no-repeat;
   }
   
   /* on toolbar */
   toolbarpaletteitem[place="toolbar"] > toolbarspring{
     background: url("chrome://classic_theme_restorer/content/images/flex_space.png") white center no-repeat;
     min-width: 32px;
     border: 1px solid black !important;
   }
   toolbarpaletteitem[place="toolbar"] > toolbarseparator{
     min-width: 5px;
     width: 5px;
   }
   toolbarpaletteitem[place="toolbar"] > toolbarspacer{
     background: url("chrome://classic_theme_restorer/content/images/space1.png") center no-repeat;
     min-width: 15px;
     width: 15px;
   }
   
   /* spaces, flexible spaces, separators in panel ui menu */
   toolbarpaletteitem toolbarspring[cui-areatype="menu-panel"]{
     background: url("chrome://classic_theme_restorer/content/images/flex_space.png") white center no-repeat;
     border: 1px solid black;
   }
   
   toolbarpaletteitem toolbarseparator[cui-areatype="menu-panel"]{
     background: url("chrome://classic_theme_restorer/content/images/separator.png") center no-repeat;
   }

   toolbarpaletteitem toolbarspacer[cui-areatype="menu-panel"]{
     background: url("chrome://classic_theme_restorer/content/images/space1.png") center no-repeat;
   }
   
   /* adjustments for spaces, flexible spaces, separators in panel menu */
   toolbarspring[cui-areatype="menu-panel"]{
     -moz-appearance: none !important;
     width: 260px !important;
     min-height: 20px !important;
     margin-right: 2px !important;
     margin-left: 2px !important;
   }
   toolbarseparator[cui-areatype="menu-panel"]{
     -moz-appearance: none !important;
     width: 260px !important;
     min-height: 0px !important;
     margin-right: 2px !important;
     margin-left: 2px !important;
     border-top: 1px solid rgba(0,0,0,.0) !important;
     border-bottom: 1px solid rgba(0,0,0,.5) !important;
   }
   toolbarspacer[cui-areatype="menu-panel"]{
     -moz-appearance: none !important;
     height: 67px !important;
      width: 89px !important;
      padding-top: 38px !important;
   }
   
   /* Fix separator visibility on Firefox 54+ and Windows Classic visual style */
   @media (-moz-windows-classic) {
      #main-window[fx54plus="true"][defaultfxtheme="true"] toolbar toolbarseparator{
        min-width: 5px !important;
        width: 5px !important;
        background: url("chrome://classic_theme_restorer/content/images/separator.png") center no-repeat !important;
        background-size: 5px 80% !important;
      }
      
      #main-window[fx54plus="true"][defaultfxtheme="true"] toolbarpaletteitem[place="palette"] > toolbarseparator{
        min-width: 5px !important;
        width: 5px !important;
      }
      
      #main-window[fx54plus="true"][defaultfxtheme="true"] toolbarpaletteitem[place="toolbar"] > toolbarseparator{
        background: url("chrome://classic_theme_restorer/content/images/separator.png") center no-repeat !important;
      }
      
      #main-window[fx54plus="true"][defaultfxtheme="true"]:-moz-lwtheme-brighttext toolbarpaletteitem[place="toolbar"] > toolbarseparator{
        background: url("chrome://classic_theme_restorer/content/images/separator.png") center no-repeat !important;
      }
   }

}
Last edited by madmudmob on August 27th, 2017, 10:47 am, edited 1 time in total.
Mud is good!

Brummelchen
 
Posts: 2591
Joined: March 19th, 2005, 10:51 am

Post Posted August 27th, 2017, 7:51 am

where did you get that code from?

from my view thats definition of an item with background image/colour, width, border and some [switches] in which manner it is shown at several places.

madmudmob

User avatar
 
Posts: 710
Joined: August 30th, 2006, 7:34 am
Location: Somerset, UK

Post Posted August 27th, 2017, 7:54 am

Mud is good!

Brummelchen
 
Posts: 2591
Joined: March 19th, 2005, 10:51 am

Post Posted August 27th, 2017, 8:19 am

i think you will have more luck when asking here:
viewtopic.php?f=48&t=2827985

but i dont recommend it for now to investigate in css or scripts which are not valid when v57 is upcoming, or trying them in v52-56 as long ctr is functional.

i can tell you for now
- Squared tabs (without separator mark). <-- v57 has square tabs
- Tabs not on top. <-- maybe, but later, much later
- Tabs Min-width is 70 px. <-- possible
- Add flexible space (additional toolbar) under Bookmarks Toolbar. <-- never happen (like chrome)
- Add "Reload" button on the right side of "Home" button. <-- each button needs an extension (like chrome) but this probably will never happen
- Hide close button from all tabs & show it on the current tab until hovered. <-- maybe
- Remove Firefox menu button. <-- probably never, like chrome

people think too much about solutions which wont work in v57. as i said earlier the new API will be much better 3 months after v57 has been released, around v60/61. and v57 is changing every day a bit. that code might work but i think it wont work.

i had invented my own full theme based on some minimal work and each firefox version (v4 up to australis design) had major changes and made me more grey hair. never ending story and i was glad australis came up. ctr gave me back the visibility.

madmudmob

User avatar
 
Posts: 710
Joined: August 30th, 2006, 7:34 am
Location: Somerset, UK

Post Posted August 27th, 2017, 8:23 am

Thankyou
Mud is good!

Frank Lion

User avatar
 
Posts: 19425
Joined: April 23rd, 2004, 6:59 pm
Location: ... The Exorcist....United Kingdom

Post Posted August 27th, 2017, 8:52 am

madmudmob wrote:Could some kind person help me please or tell me if I'm on the wrong track?

Wrong track. That's just showing the spaces, etc images in the Customise Window, but you still need the JavaScript side to provide the functionality.

I can probably get you a very small 10KB extension for that, if that's all you want.
Metal Lion latest SeaMonkey & Thunderbird Themes - Sea Monkey and Silver Sea Monkey
"The only thing necessary for the triumph of evil, is for good men to do nothing." - Edmund Burke (attrib.)

madmudmob

User avatar
 
Posts: 710
Joined: August 30th, 2006, 7:34 am
Location: Somerset, UK

Post Posted August 27th, 2017, 8:58 am

Thankyou, Frank Lion, that would be perfect :)
Mud is good!

Frank Lion

User avatar
 
Posts: 19425
Joined: April 23rd, 2004, 6:59 pm
Location: ... The Exorcist....United Kingdom

Post Posted August 27th, 2017, 10:39 am

madmudmob wrote:Thankyou, Frank Lion, that would be perfect :)

Here you go. It's the extension that I include in my Firefox Tiger themes and it'll do what you want - http://franklion.co.uk/metal_lion_custo ... -1.0.4.xpi (live install link)

It also allows you to move the addressbar around and adds a 'bottom toolbar' (like an Addons Bar or statusbar) which you can turn off if you don't need.
Metal Lion latest SeaMonkey & Thunderbird Themes - Sea Monkey and Silver Sea Monkey
"The only thing necessary for the triumph of evil, is for good men to do nothing." - Edmund Burke (attrib.)

madmudmob

User avatar
 
Posts: 710
Joined: August 30th, 2006, 7:34 am
Location: Somerset, UK

Post Posted August 27th, 2017, 10:47 am

That's wonderful - thankyou so much =D>
Mud is good!

Return to Firefox General


Who is online

Users browsing this forum: Bing [Bot] and 2 guests