MozillaZine

Help getting 'tooltip' to show on hover

Discuss application theming and theme development.
Lunar

User avatar
 
Posts: 484
Joined: July 6th, 2004, 5:08 am
Location: Texas, США

Post Posted March 29th, 2013, 12:22 am

Hello,
First, i want, need to say. The lack of 'HowTo' and documentation at mozilla.org is making my brain hurt.... on top of that, the 'coder' change things faster than any addon developer could possibly keep up with and with that and the lack of documenting changes, again, it makes my brain hurt... : ),, phew.. thanks, i'm needed to get that off my chest...

OK. With that said,
I'm working on an 'add-on' and everything is working like I want (in Aurora nightly), but I can Not get the 'Tool Tip' to show.
When I hover mouse over toolbar button, No 'tooltip'. the button get focus, highlights, but again no tooltip.

I have these things defined, i think.

browser-overlay.dtd -
Code: Select all
<!ENTITY restartbutton.message "Restart">
<!ENTITY restartbutton.tooltip "Restart Firefox">


overlay.xul -
Code: Select all
<!DOCTYPE overlay SYSTEM "chrome://restartbutton/locale/browser-overlay.dtd">
and -
<toolbarpalette id="BrowserToolbarPalette">
    <toolbarbutton
    id="restartbuttonButton"
    engine="fx"
    label="&restartbutton.message;"
    class="toolbarbutton-1 chromeclass-toolbar-additional"
    oncommand="(new restartButton()).restartApp();"
    />
</toolbarpalette>


restartbutton.css -
Code: Select all
#restartbuttonButton {
  list-style-image: url("chrome://restartbutton/skin/button.png");
}


any thing obvious?
Landis.

p.s., I tried to install this addon in central nightly 22.0a2. It seemingly installed, but the icon does not show up in toolbar and when I right click toolbar > choose customize, there are only space and divide items in the customize palate. No 'apps' and not mine, but it's in "addon manager" as installed.. what's up with that? is that normal for 'central' nightly? I Always use Aurora, so I'm not sure.
'Microsucks' made me nuts, Linux is making me crazy...
...at least with Linux, I can afford the therapy.. : )
openSuSE | KDE | enlightenment | mozilla Aurora 55 / Nightly 106 Konqueror /Opera/ Aurora Dev Ed | Now, down to Firefox 45 52 ESR as the 'new' direction... sxxxs!

Paenglab

User avatar
 
Posts: 206
Joined: December 30th, 2006, 2:20 am
Location: Switzerland

Post Posted March 29th, 2013, 1:55 am

Try it with adding a tooltiptext="&restartbutton.tooltip;" to your toolbabutton definition in overlay.xul.
Nuvola theme for Firefox and Thunderbird

Lunar

User avatar
 
Posts: 484
Joined: July 6th, 2004, 5:08 am
Location: Texas, США

Post Posted March 29th, 2013, 2:58 am

Paenglab wrote:Try it with adding a tooltiptext="&restartbutton.tooltip;" to your toolbabutton definition in overlay.xul.


Paenglab... Thank You very much!... That was it. Done!

would you be able to tell me, quickly, when one uses locale or browser-overlay ?

Again, Thank you.

Landis.
'Microsucks' made me nuts, Linux is making me crazy...
...at least with Linux, I can afford the therapy.. : )
openSuSE | KDE | enlightenment | mozilla Aurora 55 / Nightly 106 Konqueror /Opera/ Aurora Dev Ed | Now, down to Firefox 45 52 ESR as the 'new' direction... sxxxs!

Paenglab

User avatar
 
Posts: 206
Joined: December 30th, 2006, 2:20 am
Location: Switzerland

Post Posted March 29th, 2013, 3:34 am

Lunar wrote:Paenglab... Thank You very much!... That was it. Done!

You're welcome.
Lunar wrote:would you be able to tell me, quickly, when one uses locale or browser-overlay ?

I don't understand your question, so here's my guess what you mean. The name of this file is free. You can also name it restartbutton.dtd. This file is used for translation. For other languages it's only this file to translate. Then this files have to be in locale/en-US/ and for example locale/de/. In chrome.manifest you have then to define the path to this locales depending of the used locale:
Code: Select all
locale    restartbutton en-US chrome/locale/en-US/
locale    restartbutton de chrome/locale/de/


Best would be to analize a other Add-on to learn how it works.
Nuvola theme for Firefox and Thunderbird

Return to Theme Development


Who is online

Users browsing this forum: No registered users and 1 guest