menu.css (4707B)
1 /* This Source Code Form is subject to the terms of the Mozilla Public 2 * License, v. 2.0. If a copy of the MPL was not distributed with this 3 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ 4 5 /* ===== menu.css ======================================================= 6 == Styles used by XUL menu-related elements. 7 ======================================================================= */ 8 9 @namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"); 10 11 /* ::::: menu/menuitem ::::: */ 12 13 menu, 14 menuitem, 15 menucaption, 16 .splitmenu-menuitem { 17 -moz-appearance: none; 18 -moz-box-align: center; 19 color: #FFFFFF; 20 font: menu; 21 list-style-image: none; 22 -moz-image-region: auto; 23 } 24 25 menuitem[default="true"] { 26 font-weight: bold; 27 } 28 29 menu[_moz-menuactive="true"], 30 menuitem[_moz-menuactive="true"], 31 .splitmenu-menuitem[_moz-menuactive="true"] { 32 color: #bfbbb6; 33 background-color: rgb(64,64,64); 34 } 35 36 menu[disabled="true"], 37 menuitem[disabled="true"], 38 .splitmenu-menuitem[disabled="true"], 39 menucaption[disabled="true"] { 40 color: GrayText; 41 } 42 43 menubar > menu { 44 padding: 0px 4px; 45 color: #bfbbb6; 46 } 47 48 menubar:-moz-lwtheme > menu { 49 text-shadow: none; 50 } 51 52 menubar:-moz-lwtheme > menu:not([open="true"]) { 53 color: inherit; 54 text-shadow: inherit; 55 } 56 57 menubar > menu[_moz-menuactive="true"]:not([open]):not([disabled="true"]):not(:-moz-lwtheme) { 58 color: #bfbbb6; 59 } 60 61 menubar > menu[open] { 62 color: #bfbbb6; 63 background-color: #181411; 64 } 65 menuitem.spell-suggestion { 66 font-weight:bold; 67 } 68 69 /* ::::: menu/menuitems in menulist popups ::::: */ 70 71 menulist > menupopup > menuitem, 72 menulist > menupopup > menucaption, 73 menulist > menupopup > menu { 74 padding: 1px 5px; 75 max-width: none; 76 font: message-box; 77 } 78 79 /* ..... internal content .... */ 80 81 .menu-text, 82 .menu-iconic-left, 83 .menu-iconic-right, 84 .menu-iconic-text { 85 margin-top: 0px !important; 86 margin-bottom: 0px !important; 87 margin-inline-start: 0px !important; 88 margin-inline-end: 2px !important; 89 color: inherit; 90 } 91 92 .menu-text { 93 /* This is (18 + the size of end-padding on .menu-iconic-left)px */ 94 margin-inline-start: 21px !important; 95 font-weight: inherit; 96 } 97 98 menucaption > .menu-text, 99 menucaption > .menu-iconic-text { 100 margin-inline-start: 0 !important; 101 font-weight: bold; 102 } 103 104 .menu-description { 105 font-style: italic; 106 color: GrayText; 107 margin-inline-start: 1ex !important; 108 } 109 110 .menu-accel, 111 .menu-iconic-accel { 112 margin-top: 0px !important; 113 margin-bottom: 0px !important; 114 margin-inline-start: 7px !important; 115 color: inherit; 116 } 117 118 .menu-accel-container { 119 -moz-box-pack: end; 120 } 121 122 .menu-iconic-left, 123 .menu-iconic-right { 124 width: 16px; 125 /* We can only hardcode this, to make the default GTK icon<->label spacing */ 126 padding-inline-end: 3px !important; 127 } 128 129 .menu-iconic-icon { 130 width: 16px; 131 height: 16px; 132 } 133 134 .menu-right { 135 margin-top: 0px; 136 margin-bottom: 0px; 137 margin-inline-start: 6px; 138 margin-inline-end: 0px; 139 width: 1ex; 140 height: 1ex; 141 /* These next two rules are needed to prevent inheritance and thus ugliness */ 142 list-style-image: url("chrome://global/skin/arrow/arrow-h.svg#rit"); 143 -moz-image-region: auto; 144 -moz-appearance: none; 145 } 146 147 .menu-right > image { 148 width: 5px; 149 } 150 151 .menubar-left { 152 margin-top: 0px; 153 margin-bottom: 0px; 154 margin-inline-start: 0px; 155 margin-inline-end: 2px; 156 color: inherit; 157 } 158 159 .menubar-text { 160 margin: 0 1px !important; 161 color: inherit; 162 } 163 164 165 menulist > menupopup > menuitem > .menu-iconic-left, 166 menulist > menupopup > menucaption > .menu-iconic-left, 167 menulist > menupopup > menu > .menu-iconic-left { 168 display: none; 169 } 170 171 menuitem[checked="true"] { 172 list-style-image: url("chrome://global/skin/menu/menu-check.svg#check"); 173 } 174 175 menuitem[checked="true"][disabled="true"], 176 menuitem[checked="true"][disabled="true"][_moz-menuactive="true"] { 177 list-style-image: url("chrome://global/skin/menu/menu-check.svg#check-dis"); 178 } 179 180 /* ::::: checkbox and radio menuitems ::::: */ 181 182 menuitem[checked="true"][type="radio"] { 183 list-style-image: url("chrome://global/skin/menu/menu-radio.svg#radio"); 184 } 185 186 menuitem[checked="true"][type="radio"][disabled="true"], 187 menuitem[checked="true"][type="radio"][disabled="true"][_moz-menuactive="true"] { 188 list-style-image: url("chrome://global/skin/menu/menu-radio.svg#radio-dis"); 189 } 190 191 /* ::::: menuseparator ::::: */ 192 193 menuseparator { 194 margin: 2px 3px; 195 border-top: 1px solid rgb(75,75,75); 196 } 197 198 menuseparator[collapsed="true"] { 199 margin: 0 !important; 200 } 201 202 menulist > menupopup > menuseparator, 203 .menulist-menupopup > menuseparator { 204 padding: 6px 0 5px 0; 205 border-top: 1px solid #FFFFFF; 206 border-bottom: none; 207 } 208 209 /* ::::: autocomplete ::::: */ 210 211 .autocomplete-history-popup > menuitem { 212 max-width: none !important; 213 font: message-box; 214 }