[Finished] Weather - Temperature in Celsius (1 Viewer)

octessence

Portal Pro
May 8, 2012
76
10
Germany
Home Country
United Kingdom United Kingdom
The weather plugin supplied by default does not provide a configuration option to show the temperature in Celsius. It would be nice for us non-Americans.
 

chefkoch

Retired Team Member
  • Premium Supporter
  • October 5, 2004
    3,129
    1,635
    Dresden / Munich / Maastricht
    Home Country
    Germany Germany
    The weather plugin supplied by default does not provide a configuration option to show the temperature in Celsius. It would be nice for us non-Americans.
    This is already working, but:

    It depends on your localization settings in windows, whether it is displayed in Celsius or Fahrenheit.
    Please check you system's control panel: (the screenshots are from German OS, hope it still helps)
    20130621_002506.png

    Without changing anything in the system's control panel you should configure you Culture / Region within the MP2 settings by setting the correct language, see my example:
    • My system's default culture is German (Germany)
      Weather is display in °C
      20130621_002946.png
    • MP2 uses by default the system's culture:
      20130621_003516.png
    • Now let's change the culture to English (USA)
      20130621_003540.png
    • Tada, what a magic.
      20130621_003555.png
    This is a great example that it is not necessary to reinvent the wheel over and over again and having a setting for every small part of an application.
    This is the MP2 way of doing things :) ;)
    The locale defined in MP2 is reused for the language / translations and for the measuring units. :)
    If this is a non-US, metric culture you'll get Celsius.

    I assume for 99.98 % of all users this is perfectly fine. And for the other 0.02% we have to say sorry, but this simplifies the configuration and the code for a default plugin. Nevertheless, if a developer would like to implement such additional customizations, it is no problem to fork the weather plugin and release it as an additional community plugin Weather++ or something like that ;)


    For the relevant code see:
    https://github.com/MediaPortal/Medi...er/Grabbers/WorldWeatherOnlineCatcher.cs#L238
    https://github.com/MediaPortal/Medi...er/Grabbers/WorldWeatherOnlineCatcher.cs#L317

    I added this to the todo list for documentation in wiki.
     
    Last edited:

    octessence

    Portal Pro
    May 8, 2012
    76
    10
    Germany
    Home Country
    United Kingdom United Kingdom
    Thanks. My locale setting were already set to Metric and I still saw Fahrenheit. Only changing the language to English (United Kingdom) made it change to Celsius.

    Associating what is seen to the system locale makes perfect sense however associating it to the language setting makes no sense at all. In the UK there are plenty of people who still think in imperial but that has nothing to do with the language they speak.

    EDIT:
    If the "Language" page in the MP2 settings was called something more general like "Locale" it would be obvious but having a language option that also controls other things is misleading.
     
    Last edited:

    chefkoch

    Retired Team Member
  • Premium Supporter
  • October 5, 2004
    3,129
    1,635
    Dresden / Munich / Maastricht
    Home Country
    Germany Germany
    EDIT:
    If the "Language" page in the MP2 settings was called something more general like "Locale" it would be obvious but having a language option that also controls other things is misleading.
    I fully agree with you and will add this to the todo list as well. I'll report the link here when I added it to the issue tracker. This also might needs some general planning / discussion for what the locale is / could be used as well.

    Nevertheless thanks for reporting this :)
     

    jpichie

    Portal Pro
    May 12, 2011
    102
    8
    Home Country
    Canada Canada
    Sorry to bring this back up, I was looking for an answer for this today.
    I will make that change, but why not just have a celsius/fahrenheit changer under the weather module config?
     

    morpheus_xx

    Retired Team Member
  • Team MediaPortal
  • March 24, 2007
    12,070
    7,459
    Home Country
    Germany Germany
    Sorry to bring this back up, I was looking for an answer for this today.
    I will make that change, but why not just have a celsius/fahrenheit changer under the weather module config?
    There are many places where a regional setting is used inside MP2. It would not be consistent to change only °C/°F for this special case.
    So selecting your region is all you need actually.
     

    octessence

    Portal Pro
    May 8, 2012
    76
    10
    Germany
    Home Country
    United Kingdom United Kingdom
    My only issue was that the option said it was for language only and it wasn't clear that this also controlled region.
     

    morpheus_xx

    Retired Team Member
  • Team MediaPortal
  • March 24, 2007
    12,070
    7,459
    Home Country
    Germany Germany
    Ok, we consider a clearer message. Thanks for your input!
     

    jpichie

    Portal Pro
    May 12, 2011
    102
    8
    Home Country
    Canada Canada
    Thanks for the info @morpheus_xx I am just thinking back to other weather apps, and they all have the option to change from celcius to fahrenheit and vice-versa regardless of region.
     

    Users who are viewing this thread

    Similar threads

    Hi. I was probably being a bit fast and loose with my terminology. I meant "somewhere within the files that MP2 uses in its database". Anyway, I found a way to do this which was far from automated but relatively low effort. I found what looked like all the images (CD covers, DVD covers, backgrounds etc all lumped together in...
    Hi. I was probably being a bit fast and loose with my terminology. I meant "somewhere within the files that MP2 uses in its...
    I am in the process of setting up a legacy media player (Mede8er) which I happened to have laying around into my home cinema setup...
    Replies
    2
    Views
    352
    Are the media/video folders on the Mint host?
    Are the media/video folders on the Mint host?
    I've used Mediaportal for years on a Windows Host with restricted online-access. Lately I reinstalled...
    Replies
    1
    Views
    1K
    Got a reply from SD ... "Looks like your last successful download was on 5/23. On 5/24 for some reason we received 194 connections between 10:54 and 11:05 triggering a denial of service attack ban. The logs show it was lifted on 5/25, but I still see the entry in iptables. I reset fail2ban and hopefully you're working again." Weird...
    Got a reply from SD ... "Looks like your last successful download was on 5/23. On 5/24 for some reason we received 194...
    I'm using MediaPortal 1.38.1 x64 and have an SD-DD lineup account. In the last week, I have not been able to update my EPG, and...
    Replies
    3
    Views
    302
    Thanks very much, Jasmeet. Worked. But note that this setting has moved, apparently, to: Settings > TV (not Plugins)
    Thanks very much, Jasmeet. Worked. But note that this setting has moved, apparently, to: Settings > TV (not Plugins)
    I recently did a fresh install of 2.5 on a new Windows 11 PC. My previous (Windows 10) version of 2.5 gave my broadcast TV channel...
    Replies
    2
    Views
    2K
    Thankyou High_Five, that worked perfectly, I now remember doing that 10 years ago, thanks for jogging my old memory. Cheers Tony
    Thankyou High_Five, that worked perfectly, I now remember doing that 10 years ago, thanks for jogging my old memory. Cheers Tony
    Hi everyone, I have been using it For 16 years now (from V1.1.1) and it has worked flawlessly. I only use TV Series and Moving...
    Replies
    2
    Views
    247
    Top Bottom