Page 6 of 23

Re: MX-21 Screenshots

Posted: Mon Feb 21, 2022 1:08 am
by asqwerth
siamhie wrote: Sun Feb 20, 2022 11:38 am
Glad you like it. I lurk in the conky sub Reddit and came across this reply from moongya on setting up wttr.in in conky.

Conky Weather

I started with their base code and modified it using the output format from the wttr.in wiki page.

https://github.com/chubin/wttr.in#one-line-output

I know what you mean when you plug in the basic wttr.in command in conky. It ends up occupying the whole screen....
Nope, that's not what I mean. I'm referring to your exact conky you shared in the MXFB screenshots. There was no maximum width set in your conky. And here's the current weather condition for my area yesterday, as displayed by my modified conky:

siamhie-wttr-resize-weather2lines.png

It's so long that if I had not edited the conky config to split the weather condition into 2 lines, and added a max width, the conky would stretch to become a long horizontal rectangle as long as the weather condition text.

... If I'm not running my weather conky but I still want to check my weather using wttr.in, I have this entry in my Fluxbox menu which does include all the ascii art and the three day forecast.

Code: Select all

[exec] (Weather) {xfce4-terminal --hide-menubar --title "Weather" --geometry 130x40 -x bash -c "curl 'http://wttr.in/Forest+Grove, Oregon'; read -N1;"}
Image


I adapted a conky to show just the current weather condition with ascii art, like so:

siamhie-wttr-weatherreport_ascii.png

Code: Select all

${color orange}${alignc}Current Weather

${execpi 600 curl wttr.in/YOUR+LOCATION?T0Q}${color}
where
T=suppress some terminal output (weird characters show up in the conky if not suppressed),
0=just show current weather,
Q= super quiet, ie suppress the actual title "WEATHER REPORT: [LOCATION AS STATED IN YOUR wttr.in command]" that appears at the top of this output. As you can imagine, if your location has more than 1 word and you have to add a "+" in between each word of your location, the actual title will display those + signs, which looks silly.


Yes, the "partly cloudy" ascii art in the screenshot is not too bad. However, the "thunderstorm" ascii art has a sun, a cloud, rain drops and lightning bolts. It's just too cluttered with too many characters in such a small space. Looks terrible.

Re: MX-21 Screenshots

Posted: Mon Feb 21, 2022 10:03 am
by ceeslans
Like asqwerth, I mostly use the fabulous 'accuweather' script or 'openweathermap' json-output for weather conkys. But actually the wttr.in data is pretty much configurable too.
I found that it isn't (or shouldn't be) necessary to enter a location in the wttr.in curl code. If left blank, then the returned data will be based on the geo location.
That would for example look like:

Code: Select all

curl wttr.in/?T0Q
instead of

Code: Select all

curl wttr.in/Rotterdam?T0Q
In my case, wttr.in will provide the data on basis of my geo location and display weather for 'Schiedam, Netherlands' (suburb of Rotterdam).

In below screen grab, that geo location is automatically displayed in the weather conky.

Re: MX-21 Screenshots

Posted: Mon Feb 21, 2022 10:42 am
by asqwerth
@ceeslans

I don't have geolocation enabled so it doesn't work. Tried it quite a few times when I was first checking out wttr.in.

I just ran the generic command curl wttr.in/?T0Q, and sure enough, I got the weather forecast of somewhere with snow, heh. Definitely nowhere near me.

How does one enable geolocation outside of Gnome desktop (not that I'm sure I want that)? I'm on MX XFCE.

Re: MX-21 Screenshots

Posted: Mon Feb 21, 2022 11:31 am
by ceeslans
asqwerth wrote: Mon Feb 21, 2022 10:42 am @ceeslans
...
I just ran the generic command curl wttr.in/?T0Q, and sure enough, I got the weather forecast of somewhere with snow, heh. Definitely nowhere near me.
Did you try that comand without 'Q' -- which would show you the location name. Is that anywhere near you.

(Sorry, dont know how to enable/disable geo location detection in xfce)

Re: MX-21 Screenshots

Posted: Mon Feb 21, 2022 11:55 am
by asqwerth
ceeslans wrote: Mon Feb 21, 2022 11:31 am
asqwerth wrote: Mon Feb 21, 2022 10:42 am @ceeslans
...
I just ran the generic command curl wttr.in/?T0Q, and sure enough, I got the weather forecast of somewhere with snow, heh. Definitely nowhere near me.
Did you try that comand without 'Q' -- which would show you the location name. Is that anywhere near you.

(Sorry, dont know how to enable/disable geo location detection in xfce)
Strangely enough, when I run the command without Q, I get "weather report: not found" indicating no location was found. I still get a weather report for a cold misty place. It's not really an issue since I can always add my location to the curl wttr.in commands in my conkies.

@ceeslans

I'm more interested in how you are able to display the moon phase graphic in the screenshot of your demo conky. When I try inserting that, or previously when I tried the command for one-line output, eg "curl wttr.in/Nuremberg?format=3" in a conky, the graphic always shows up as those square boxes indicating "no appropriate character".

ksnip_20220222-005204.png

When run as a terminal command, the graphic shows up, but not in conky. I tried some googling but the most I could gather was that some font or emoji or character set was missing, but I couldn't figure out what. Do you know what I need to install? What have you added to the default MX21 install?

Re: MX-21 Screenshots

Posted: Mon Feb 21, 2022 12:11 pm
by ceeslans
@ceeslans
I'm more interested in how you are able to display the moon phase graphic in the screenshot of your demo conky. When I try inserting that, or previously when I tried the command for one-line output, eg "curl wttr.in/Nuremberg?format=3" in a conky, the graphic always shows up as those square boxes indicating "no appropriate character".

ksnip_20220222-005204.png

When run as a terminal command, the graphic shows up, but not in conky. I tried some googling but the most I could gather was that some font or emoji or character set was missing, but I couldn't figure out what. Do you know what I need to install? What have you added to the default MX21 install?
Not every font is capable to display it. No luck with e.g Noto Sans or Liberation Sans - but fonts like DejaVu Sans, DejaVu Mono, and Droid Sans will display it well.

Re: MX-21 Screenshots

Posted: Mon Feb 21, 2022 12:23 pm
by asqwerth
ceeslans wrote: Mon Feb 21, 2022 12:11 pm
Not every font is capable to display it. No luck with e.g Noto Sans or Liberation Sans - but fonts like DejaVu Sans, DejaVu Mono, and Droid Sans will display it well.
Ah ha! Got it. Thanks.

Re: MX-21 Screenshots

Posted: Tue Feb 22, 2022 8:11 pm
by Shifu
h3kt0r wrote: Mon Feb 14, 2022 7:02 am
Image

Resolution: 1600x900
DE: Xfce 4.16
WM: Xfwm4
WM Theme: Crux2
Theme: Matcha-dark-aliz [GTK2], Blackbird [GTK3]
Icons: Tango [GTK2/3]
There is no substitute for Irfanview. No matter how much people say otherwise. There just isn't.

Re: MX-21 Screenshots

Posted: Tue Feb 22, 2022 9:24 pm
by siamhie
asqwerth wrote: Mon Feb 21, 2022 1:08 am

Nope, that's not what I mean. I'm referring to your exact conky you shared in the MXFB screenshots. There was no maximum width set in your conky. And here's the current weather condition for my area yesterday, as displayed by my modified conky:


siamhie-wttr-resize-weather2lines.png


It's so long that if I had not edited the conky config to split the weather condition into 2 lines, and added a max width, the conky would stretch to become a long horizontal rectangle as long as the weather condition text.
Thanks for reminding me. I really need to make a default conky.conf template to use for my builds.

asqwerth wrote: Mon Feb 21, 2022 1:08 am
I adapted a conky to show just the current weather condition with ascii art, like so:


siamhie-wttr-weatherreport_ascii.png

Code: Select all

${color orange}${alignc}Current Weather

${execpi 600 curl wttr.in/YOUR+LOCATION?T0Q}${color}
where
T=suppress some terminal output (weird characters show up in the conky if not suppressed),
0=just show current weather,
Q= super quiet, ie suppress the actual title "WEATHER REPORT: [LOCATION AS STATED IN YOUR wttr.in command]" that appears at the top of this output. As you can imagine, if your location has more than 1 word and you have to add a "+" in between each word of your location, the actual title will display those + signs, which looks silly.


Yes, the "partly cloudy" ascii art in the screenshot is not too bad. However, the "thunderstorm" ascii art has a sun, a cloud, rain drops and lightning bolts. It's just too cluttered with too many characters in such a small space. Looks terrible.
I like that. Very small that I can tuck away in the upper left corner. :number1:

Re: MX-21 Screenshots

Posted: Tue Feb 22, 2022 9:26 pm
by AVLinux
asqwerth wrote: Mon Feb 21, 2022 10:42 am I got the weather forecast of somewhere with snow, heh. Definitely nowhere near me.
Lol, lucky you!! Plenty here to share if you want some! :p