Weather Watcher for Linux?

No, I’m not requesting a port of Weather Watcher to Linux! I am wondering how many are already using it in Linux, with WINE, the Windows compatability layer. I can’t be the only one!

True, not much works without Internet Explorer. But the icon does attach itself to the system tray (using OpenSUSE 10.2 with KDE 3.5.5). The icon is solid black, but the tooltip does work. And right clicking on the icon produces the usual menu, with access to options. Logging and export work, and not much else, but those features provide some interesting options.

After trying such weather monitors as I could find for Linux, I decided that good old Weather Watcher offered more flexibility.

I am using the export option to generate a page of html with most of the information I want, and my browser reloads the local file every minute. By putting the current temperature in the title for the page, I get the temperature on the browser window’s title bar and consequently it appears on the task bar.

I do have two requests for new data tags, but I don’t expect them to be a high priority. :slight_smile:

I’d like to have an [Updated time] tag, which I think is self-explanator, to use in the html title.

And I would also really appreciate a tag that might be called [Alert If]. If there were no currently active alerts, this tag would produce an empty field, but if there were active alerts, it would return the text, “ALERT!”

Has anyone else found ways to make other features work?

Edit: adding images. Second edit: correcting links:

Here’s what my Weather Watching browser looks like, with the blank WW icon below:
http://img267.imageshack.us/img267/3770/wwlinuxwf1.jpg

And this shows the current temperature on the task bar:

http://img267.imageshack.us/img267/4147/linuxtaskbarnh4.jpg

(Images hosted at ImageShack Free Image Hosting)

The Export template shown here: http://www.singerscreations.com/forum/v … php?p=7844[/url] displays the updated time as does the one here: [url=http://www.singerscreations.com/forum/viewtopic.php?p=7795]http://www.singerscreations.com/forum/v … php?p=7795. :icon_smile:

In fact the window titles in your images show the update time so I’m not sure what you’re asking.

There are several tags that relate to Alerts that can be used to display an alert icon or msg. I don’t remember off hand which one contains the alert message but a couple of my skins use the tags. You can find them here: http://www.singerscreations.com/forum/v … php?t=1120 If you use similar code found in them you should be able to display an alert indicator when one is issued.

What does your template look like?

BTW As for the blank tray icon, try changing the icon’s background color. Pure white doesn’t work well. Also some fonts work better than others. Try using a non-True Type font.

hth

Thanks for your help, Ed! I really need to remember that what’s obvious to me is often much less so to anyone else. What I’d like is a tag that returns just the time of the observation, without the date or any other information. As the task bar fills up the space given to each title diminishes. Using [Updated Datetime] works, but the time disappears if seven or more applications are running. I’d like to have just temperature and date in the title.

There are several tags that relate to Alerts that can be used to display an alert icon or msg. I don’t remember off hand which one contains the alert message but a couple of my skins use the tags. You can find them here: http://www.singerscreations.com/forum/v … php?t=1120 If you use similar code found in them you should be able to display an alert indicator when one is issued.

Thanks and I’ll take a look at your skins, but again, what I’m doing is weird enough that it’s hard to make other solutions apply! The alert popup does not work, so I’m trying to find something that will let me know when an alert is issued, but will not appear otherwise. That’s why I’d like one that simply returns an empty string when there’s no alert. Then I could change the title in my template to something like this:

<TITLE>[Alert If] [Temp] @ [Updated Time]</TITLE>

This would show “ALERT!” as the first thing in the title, and therefore on the task bar, and might catch my attention. The rest of the time, when there was no alert, it would just say “72F @ 11:45 AM” or whatever.

What does your template look like?

BTW As for the blank tray icon, try changing the icon’s background color. Pure white doesn’t work well. Also some fonts work better than others. Try using a non-True Type font.

I’ll copy my template below.

As for the tray icon, I think this is one case where the two operating systems remain incompatible, for now. I’ve tried changing colors and fonts, and all I get is a black square. Now if Weather Watcher had an option to export a temperature icon… But that’s more than I’m willing to ask!

Export template:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
	<meta http-equiv="Refresh" content="60; url=/windows/E/More_programs/stuff/current_wx.html">
	<META HTTP-EQUIV="CONTENT-TYPE" CONTENT="text/html; charset=utf-8">
	<TITLE>[Temp]  [Updated Datetime]</TITLE>
	<link rel="shortcut icon" href="/home/robbh/[Icon]" type="image/vnd.microsoft.icon">
</HEAD>
<BODY LANG="en-US" DIR="LTR">
<P><IMG SRC="/home/robbh/[Icon]" NAME="[Condition]" ALIGN=LEFT>
</P>
<P>[Temp] [Condition] 
</P>
<P>[Location] 
</P>
<P>Observed [Updated Datetime] 
</P>
<P>Alerts: [Alerts Available]</P>
<P>Feels Like: [Feels]</P>
<P>Dew Point: [Dew]</P>
<P>Humidity: [Humidity]</P>
<P>Wind: [Wind]</P>
<P>Visibility: [Visibility]</P>
<P>Barometer: [Barometer]</P>
<P>UV Index: [UV]</P>
<P>Sunrise: [Sunrise AMPM]</P>
<P>Sunset: [Sunset AMPM]</P>
<P><IMG SRC="[Moon Icon]" NAME="[Moon]" ALIGN=LEFT>
<P>Moon: [Moon]</P>
</P>
<P><A HREF="http://www.weather.com/weather/local/30601?lswe=30601" NAME="Athens forecast">More
information from weather.com</A></P>
<P><BR><BR>
</P>
<P><BR><BR>
</P>
</BODY>
</HTML>

hmmmmm :book:

The problem is your tieing everything to the HTML Title tag.

For an alert indicator you could use the [ALERT SOUND] tag. Wrap it in HTML code to play the sound.

document.write('<EMBED SRC="' + [ALERT SOUND] +'" LOOP="TRUE" AUTOSTART="TRUE"' + ' HIDDEN="TRUE">'); document.write('<NOEMBED><BGSOUND SRC="' + [ALERT SOUND] +'" LOOP="INFINITE"></NOEMBED>');
You may not see it but you should be able to hear it. :icon_smile:

In the title you might use the [ALERTS COUNT] tag which I think is blank if less than 1. Or is it the [ALERTS AVAILABLE] tag? :-s

The time thing is tricker. It can be extracted easy enough, the problem is getting it to the TITLE tag. You could try letting the whole HTML section be generated by Javascript at the end of the template. I don’t have time to try this at this point so you’re going to have to wing it a bit. Sorry.

Thanks again for all your help, Ed! I’ll experiment with your suggestions. This may be a great opportunity for me to learn something about javascript. Anyway, please don’t lose any sleep over it. This is an ongoing project and it’s going to take some time and some trial and error to get things to work the way I want them to.

I’m just pleased to have so much of Weather Watcher working in Linux.

Temp & Time in the title

Try this Export template:

[code]

[LOCATION]



  [CONDITION]

  [TEMP]


Feels Like: [FEELS]

Dew Point: [DEW]

Humidity: [HUMIDITY]

Wind: [WIND]

Visibility: [VISIBILITY]

Barometer: [BAROMETER]

UV Index: [UV]

Sunrise: [SUNRISE AMPM]

Sunset: [SUNSET AMPM]

Moon: [MOON]



[DETAILED LOOP COUNT=1]
Forecast:
[DETAILED FORECAST]
[/DETAILED LOOP]

[UPDATED]
[/code]

The title wasn’t as hard to do as I thought. :icon_smile: It works for me under Windows, sans the META and LINK tags obviously, does it work for you under WINE?

HTH :wink:

Re: Temp & Time in the title

Wow! Yes, it works very well, thanks.

I haven’t tested the alert, but with spring here, it probably won’t be long before I find out how it works.

Thanks again, Ed!

:thumbright: :icon_smile:

As written the alert indicator will simply be a “*” in front of the temp in the title. You can change that to a different character or set of characters if you like. Changing the title’s color wasn’t an option nor was flashing it. :icon_smile:

I believe this approach works because the code doesn’t have a BODY tag. Everything is in the HTML tag. I’m somewhat surprised it works at all. :iconbiggrin:

To test the alert code, add a city whose location has an alert. This URL can be helpful: http://www.weather.com/newscenter/sever … ional.html

Weather Watcher in Wine

All Tray Icon and Tooltips working

I’m using Wine 9.46 and Weather Watcher 5.6.24a in Kubuntu 7.10 (initially preview version but updated; Kubuntu, of course, uses KDE).
I used native files from my Windows XP installation and Windows XP for ‘Windows version’ in Wine for WW.
Using ies4linux I installed Internet Explorer 6.
Weather Watcher installed okay with the default Wine settings.
Using native oleaut32.dll (Win XP) in Wine then in WW Options ‘Tray Icon Look and Feel’ set to Look Transparent results in a temperature and (if wished) condition graphic in the Tray Icon area.
The Tooltip pops up satisfactorily under the Tray Icon but in WW the main tabs
Current, Hourly, Daily and Maps (after one is selected) result in …
… shdocvw.dll builtin to Wine - “Runtime error ‘445’: Object doesn’t support this action”
… shdocvw.dll native Win XP - “Runtime error ‘-2147417848 (80010108)’: automation error”
This crash leaves residue in the Tray Icon area.
All others such as Update, Alerts and Options and all from the Tray Icon work.
A result as here should be possible without the IE6 via ies4linux as WW crashes before or when IE6 is called.
I might investigate this further as I’d like some way to have the forecasts too (though several of the Firefox addins are quite good).

dd