You are not logged in.

#41 2025-11-18 00:04:20

marens
Member
From: World without M$
Registered: 2023-02-02
Posts: 1,006

Re: The Carbon Conky

The colors I'm using (DADADA, FF8080) look pretty good in your screenshots.
There is a possibility for a couple of 'cosmetic' changes.

If you want the quote (without the author's name) to use an italic font, the first line (text part) could look like this:

${font :size=10:italic}${color DADADA}${texeci 3600 curl -s "https://www.calendarlabs.com/today/" | grep '<p>' | sed '3q;d' | sed 's/<p>//' | sed 's/<\/p>//' | sed 's/^[ \t]*//' | fmt -w 40}${font}

quote1.png

If you want the entire quote (including the author's name) to use an italic font, just delete the ${font}  at the end of the example above.

quote2.png

Guys, you decide.
Tastes are different.


If people would know how little brain is ruling the world, they would die of fear.

Offline

#42 2025-11-18 01:12:42

DeepDayze
Like sands through an hourglass...
From: In Linux Land
Registered: 2017-05-28
Posts: 1,921

Re: The Carbon Conky

marens wrote:

The colors I'm using (DADADA, FF8080) look pretty good in your screenshots.
There is a possibility for a couple of 'cosmetic' changes.

If you want the quote (without the author's name) to use an italic font, the first line (text part) could look like this:

${font :size=10:italic}${color DADADA}${texeci 3600 curl -s "https://www.calendarlabs.com/today/" | grep '<p>' | sed '3q;d' | sed 's/<p>//' | sed 's/<\/p>//' | sed 's/^[ \t]*//' | fmt -w 40}${font}

https://i.postimg.cc/SKbXTW12/quote1.png

If you want the entire quote (including the author's name) to use an italic font, just delete the ${font}  at the end of the example above.

https://i.postimg.cc/yxGxF9SW/quote2.png

Guys, you decide.
Tastes are different.

Nice. Either one looks good and just changing that setting to taste would be the chefs kiss.


Real Men Use Linux

Offline

#43 2025-11-18 01:42:40

marens
Member
From: World without M$
Registered: 2023-02-02
Posts: 1,006

Re: The Carbon Conky

^ I hope you meant a female chef.  smile
Otherwise...


If people would know how little brain is ruling the world, they would die of fear.

Offline

#44 2025-11-18 01:56:36

johnraff
nullglob
From: Nagoya, Japan
Registered: 2015-09-09
Posts: 12,874
Website

Re: The Carbon Conky

The italic font is a nice touch!

micko01 wrote:

Oh, I see you're running 2 conkys.

Yes, I thought that would be more flexible.

---
Those imgbb shots are taking forever to display!

---
@marens "chef's kiss" is when the chef makes a circle with his fingers and kisses it. (I think)

Last edited by johnraff (2025-11-18 02:01:02)


...elevator in the Brain Hotel, broken down but just as well...
( a boring Japan blog (currently paused), now on Bluesky, there's also some GitStuff )

Introduction to the Bunsenlabs Boron Desktop

Offline

#45 2025-11-18 02:16:20

marens
Member
From: World without M$
Registered: 2023-02-02
Posts: 1,006

Re: The Carbon Conky

^ Thanks.
I don't know the English phrases very well, but.. I still don't change my mind.  cool


If people would know how little brain is ruling the world, they would die of fear.

Offline

#46 2025-11-18 05:01:14

Döbbie03
Resident Metalhead
From: New Zealand
Registered: 2015-09-29
Posts: 3,934

Re: The Carbon Conky

johnraff wrote:

---
@marens "chef's kiss" is when the chef makes a circle with his fingers and kisses it. (I think)

I liken it to the "cherry on top"....


"All we are is dust in the wind, dude"
                                       - Theodore "Ted" Logan
"Led Zeppelin didn't write tunes that everybody liked, they left that to the Bee Gees."
                                       - Wayne Campbell

Offline

#47 2025-11-18 06:36:24

johnraff
nullglob
From: Nagoya, Japan
Registered: 2015-09-09
Posts: 12,874
Website

Re: The Carbon Conky

Just now, the lastest quote came with an html entity included:

Children aren&#39;t a class. They are merely human beings at different stages of maturity. All of them have a human intelligence which even at its lowest is a pretty wonderful thing, and the entire world in front of them.

There's a nice utility html2text which will translate that into the necessary apostrophe, but at the same time also remove the <p> tags and set the width, so this command will work:

john@boron:~$ curl -s "https://www.calendarlabs.com/today/" | grep '<p>' | sed '3q;d' | html2text -utf8 -width 39
Children aren't a class. They are
merely human beings at different stages
of maturity. All of them have a human
intelligence which even at its lowest
is a pretty wonderful thing, and the
entire world in front of them.

html2text doesn't come with BL by default, so if we were going to use it we'd need to make it a dependency of bunsen-conky. But it's quite small, and might be useful in other conkys??

Last edited by johnraff (2025-11-18 06:41:47)


...elevator in the Brain Hotel, broken down but just as well...
( a boring Japan blog (currently paused), now on Bluesky, there's also some GitStuff )

Introduction to the Bunsenlabs Boron Desktop

Offline

#48 2025-11-18 14:46:20

marens
Member
From: World without M$
Registered: 2023-02-02
Posts: 1,006

Re: The Carbon Conky

^ Good catch and solution.

This time I didn't install html2text:

$ curl -s "https://www.calendarlabs.com/today/" | grep '<p>' | sed '3q;d' | sed 's/<p>//' | sed 's/<\/p>//' | sed 's/^[ \t]*//' | sed "s/&#39;/'/g" | fmt -w 40
Children aren't a class. They are
merely human beings at different stages
of maturity. All of them have a human
intelligence which even at its lowest
is a pretty wonderful thing, and the
entire world in front of them.

If it happens often, I'll think about it.

Last edited by marens (2025-11-18 18:05:40)


If people would know how little brain is ruling the world, they would die of fear.

Offline

#49 2025-11-18 16:13:36

DeepDayze
Like sands through an hourglass...
From: In Linux Land
Registered: 2017-05-28
Posts: 1,921

Re: The Carbon Conky

perhaps make html2text a recommends?


Real Men Use Linux

Offline

#50 2025-11-19 02:20:45

johnraff
nullglob
From: Nagoya, Japan
Registered: 2015-09-09
Posts: 12,874
Website

Re: The Carbon Conky

marens wrote:

^ Good catch and solution.

This time I didn't install html2text:

$ curl -s "https://www.calendarlabs.com/today/" | grep '<p>' | sed '3q;d' | sed 's/<p>//' | sed 's/<\/p>//' | sed 's/^[ \t]*//' | sed "s/&#39;/'/g" | fmt -w 40
Children aren't a class. They are
merely human beings at different stages
of maturity. All of them have a human
intelligence which even at its lowest
is a pretty wonderful thing, and the
entire world in front of them.

If it happens often, I'll think about it.

&#39; is only one of a possibly large number of html entities that might be included in the text ( eg &amp; &lt; and any non-ascii utf8 characters ), so you'd have to add sed commands like that each time they appeared...


...elevator in the Brain Hotel, broken down but just as well...
( a boring Japan blog (currently paused), now on Bluesky, there's also some GitStuff )

Introduction to the Bunsenlabs Boron Desktop

Offline

#51 2025-11-19 02:25:53

johnraff
nullglob
From: Nagoya, Japan
Registered: 2015-09-09
Posts: 12,874
Website

Re: The Carbon Conky

DeepDayze wrote:

perhaps make html2text a recommends?

That's a possibility, yes, considering that even if it was used in that conky, it would be only one out of the whole collection that would be affected by html2text being missing. But it's really quite a small package, and might be useful in other conkys that download web pages, so why not just make it a dependency of bunsen-conky?


...elevator in the Brain Hotel, broken down but just as well...
( a boring Japan blog (currently paused), now on Bluesky, there's also some GitStuff )

Introduction to the Bunsenlabs Boron Desktop

Offline

#52 2025-11-19 03:18:20

marens
Member
From: World without M$
Registered: 2023-02-02
Posts: 1,006

Re: The Carbon Conky

johnraff wrote:

&#39; is only one of a possibly large number of html entities that might be included in the text ( eg &amp; &lt; and any non-ascii utf8 characters ), so you'd have to add sed commands like that each time they appeared...

Of course.
The apostrophe (&#39;) was expected in a quote.

I have no idea what would happen next in a normal sentence.
For now, I will only treat the symptoms of the 'disease'.

You have found an excellent 'cure' for the cause.
Thanks.


If people would know how little brain is ruling the world, they would die of fear.

Offline

Board footer

Powered by FluxBB