WM missing icons - using 2 WM in TLB
Started by Q Section


Rate this topic
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5


22 posts in this topic
shapeshifter
Senior Member
****


0
658 posts 24 threads Joined: Sep 2002
02-23-2003, 04:11 PM -
#15
Ok, once again, the only recognized headers for conditions in the provider file are as follows:
[Sun]
[Clouds]
[Mix]
[PartlyCloudy]
[Lightning]
[Rain]
[Snow]
[Wind]
NOTE: [Fog], [MostlyCloudy], and [Mostly Cloudy] are not in this list, therefor weather monitor will ignore them and all weather conditions in that section.

If you have a weather condition (as reported by the web site, such as "Mostly Cloudy") that does not fall into one of the 8 listed categories in the provider file you can still associate an icon with it so that weather monitor knows what to display. This is done in the skin.ini file, under a header that bears the same name as the provider file you are using. Again, the sample code looks like:
Code:
[instaweather.ini]
Mostly Cloudy = large\mostlycloudy.png
Where "instaweather.ini" is the provider file you are using, "Mostly Cloudy" is the condition being reported by the web page (verbatim, spaces included), and "large\mostlycloudy.png" is the path and file name of the icon you wish to use. The icon path is relative to the skin.ini file and weather monitor 1.2 only supports icons in png format.

To be clear, here is how the "Conditions" are translated from the web page to your plugin: Stage One, the plugin retrieves the HTML code from the url you specified. Next, the settings in the provider file's [Conditions] section are used to extract the text that becomes your "Conditions". Then, the plugin searches through each of the 8 conditions sections in the provider file ([Sun], [Clouds], etc) for your specific "Conditions". If there is a match, the plugin looks for a line that associates that condition section with an icon in the skin.ini file (i.e. Sun = large\sun.png). If this association is made, that icon is set as the active icon. Stage Two, the plugin looks in the current provider file's section of the skin.ini (i.e. [instaweather.ini]), if it exists, for an icon associated with your current "Conditions" (i.e. Mostly Cloudy = large\mostlycloudy.png). If there is a match, that icon becomes active, overriding any icon set in Stage One. If there is no active icon set in either stage, no icon is displayed.

I hope this clears things up.


Messages In This Thread
[No subject] - by Q Section - 02-21-2003, 02:58 AM
[No subject] - by shapeshifter - 02-21-2003, 07:51 AM
[No subject] - by Q Section - 02-21-2003, 08:44 AM
[No subject] - by shapeshifter - 02-21-2003, 10:15 AM
[No subject] - by Q Section - 02-22-2003, 06:38 PM
[No subject] - by shapeshifter - 02-22-2003, 08:25 PM
[No subject] - by Q Section - 02-22-2003, 09:51 PM
[No subject] - by Q Section - 02-22-2003, 10:44 PM
[No subject] - by shapeshifter - 02-23-2003, 08:00 AM
[No subject] - by Q Section - 02-23-2003, 11:59 AM
[No subject] - by Yuri Kobets - 02-23-2003, 12:36 PM
[No subject] - by Q Section - 02-23-2003, 03:15 PM
[No subject] - by Q Section - 02-23-2003, 03:27 PM
[No subject] - by Yuri Kobets - 02-23-2003, 04:00 PM
[No subject] - by shapeshifter - 02-23-2003, 04:11 PM
[No subject] - by Q Section - 02-24-2003, 09:45 AM
[No subject] - by Q Section - 02-24-2003, 12:04 PM
[No subject] - by Q Section - 02-24-2003, 12:17 PM
[No subject] - by Q Section - 02-24-2003, 10:08 PM
[No subject] - by shapeshifter - 02-25-2003, 07:00 AM
[No subject] - by Yuri Kobets - 02-25-2003, 04:11 PM
[No subject] - by Q Section - 02-26-2003, 06:11 PM
[No subject] - by Q Section - 02-26-2003, 07:57 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)