為了改善您的使用體驗,本網站正在進行維護,部分功能暫時無法使用。若本站的文件無法解決您的問題,想要向社群發問的話,請到 Twitter 上的 @FirefoxSupport 或 Reddit 上的 /r/firefox 發問,我們的社群成員將很快會回覆您的疑問。

搜尋 Mozilla 技術支援網站

防止技術支援詐騙。我們絕對不會要求您撥打電話或發送簡訊,或是提供個人資訊。請用「回報濫用」功能回報可疑的行為。

了解更多

How do I customize the font in the tooltip hoverbox that shows when over the navigation bar buttons (back, forward,..home, url/site button, google "G" button ?

  • 4 回覆
  • 5 有這個問題
  • 1 次檢視
  • 最近回覆由 jofeder

more options

I'm doing userchromecss customization of firefox 3.0.19 on slackware linux 12.2 and none of the css lines I've tried would ever change (in size and style) the font inside the hover box. I've tried same css lines on thunderbird and seamonkey and they work, but not on firefox. Here are the css lines I've tride:

    */ set text font of hover box */
    .tooltip:hover {
        font-size: 9pt !important;
        font-family: Tahoma !important;
    }

Result : no change in tooltip font

    */ set text font of hover box */
    .tooltip {
        font-size: 9pt !important;
        font-family: Tahoma !important;
    }

Result : no change in tooltip font

    */ set text font of hover box */
    tooltip {
        font-size: 9pt !important;
        font-family: Tahoma !important;
    }

Result : no change in tooltip font

...and more , but still no change in tool tip font.
I'm doing userchromecss customization of firefox 3.0.19 on slackware linux 12.2 and none of the css lines I've tried would ever change (in size and style) the font inside the hover box. I've tried same css lines on thunderbird and seamonkey and they work, but not on firefox. Here are the css lines I've tride: */ set text font of hover box */ .tooltip:hover { font-size: 9pt !important; font-family: Tahoma !important; } Result : no change in tooltip font */ set text font of hover box */ .tooltip { font-size: 9pt !important; font-family: Tahoma !important; } Result : no change in tooltip font */ set text font of hover box */ tooltip { font-size: 9pt !important; font-family: Tahoma !important; } Result : no change in tooltip font ...and more , but still no change in tool tip font.

所有回覆 (4)

more options

This code work for me in 3.0.19 and 5.0 (haven't checked the others, but should work there as well)

@namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul");
tooltip:not([id="aHTMLTooltip"]) {font-size:18px!important}

Does other code in the file userChrome.css (name is case sensitive) work?

more options

Thanks. I tried your code but it only affects the tooltip font of "Getting Started"-tab. The buttons along the navigation toolbar (i.e., back arrow, forward arrow, reload, stop, home including those on the url bar and the search bar have their tooltip font remaining unchanged. I've checked also with two other versions (firefox 3.0.4 and 3.6.19) where same tooltip fonts resist customization but your code have same effect as I have described. And yes I have come along many times to those 2 http pages you mentioned, though there are too many things I don't understand in there, and tried those related codes in http://www.mozilla.org/unix/customizing.html but no success yet. This could be a minor thing to others but I don't like to give up on this...or at least, not yet.

more options

The code works for me on Linux for the toolbar buttons and for long lines on chrome pages like about:config
If it isn't working for you on the toolbars then your Linux distribution may be disabling it somehow.

more options

It seems you're right. I was finally able to customize it (the fonts inside the yellow hoverbox when you hover the pointer above such buttons as "go forward", "go back", "Reload", and others along the navigation tool bar of firefox) by going to these directories : .kde share config ; then editing gtkrc-2.0 by adding the following:

                      style "user-font" {
                      font_name = "Verdana 9"
                      }
                      widget_class "*" style "user-font"
                      gtk-font-name="Verdana 9"

So its not in the userchrome.css file but in another config file in my distro. Again, thanks for your suggestion.