programming musings
19 Oct 2020

in no particular order xiv

Interesting bits elsewhere, emacs edition:

Tags: sundry emacs
07 Oct 2020

the simulacra


Philip K. Dick is always deeply original, in a very curious kind of off-hand way. Every year i pick at random one or two of his short novels (he was really prolific), and i always find food for thought and, at the same time, uncomplicated fun. It's a peculiar combination, but one i unreservedly recommend (although of course if you haven't read yet masterpieces such as Ubik or The Man in the High Castle, i'd start there).

Tags: books
07 Oct 2020

in no particular order xiii

Interesting bits elsewhere:

Tags: sundry
31 Aug 2020



Ted Chiang is up there with Greg Egan as my favourite hard SF living author, and his Exhalation was just as good as his previous books. While the first story about time travel didn't look exceptional (even though it's easily one of the best in that micro subgenre i've read), it's immediately followed by a charming entropy metaphor, an insightful mini-essay on free will, and on and on he goes, in a deluge of originality and, often, insight.

In Science Fiction Doesn’t Have to Be Dystopian, Joyce Carol Oates writes a much better review, but just reading the book is your best option!

Tags: books
27 Aug 2020

in no particular order xii

Interesting bits elsewhere:

Tags: sundry
08 Aug 2020

xmobar: a battery trick

i've been maintaining xmobar for more than a decade now, and i still use it daily and tweak it almost as often. With almost a hundred contributors besides myself, and many bugs to solve, i am always learning new things. The latest one, that font awesome thing everyone seems so fond of.

i just decided to add a bit more icons to my configuration, and, in particular, to have a battery monitor that displays graphically an approximation of time left.

For that, you specify the new font as one of the additional fonts:

additionalFonts = ["xft:FontAwesome-9"]

Then, find a list of glyphs that represent a charging battery (the ones between 0xf240 and 0xf244 work well), and assign that to the -f flag (the foreground of horizontal bars) with -W (the display width) set to 0, and use it in your battery monitor template, which should include somewhere <leftbar>; for instance:

BatteryN ["BAT0"]
         ["-t", "<acstatus>"
         , "-S", "Off", "-d", "0", "-m", "3"
         , "-L", "10", "-H", "90", "-p", "3"
         , "-W", "0"
         , "-f", "\xf244\xf243\xf243\xf243\xf242\xf242\xf242\xf241\xf241\xf240"
         , "--"
         , "-P"
         , "-a", "notify-send -u critical 'Battery running out!!!!!!'"
         , "-A", "5"
         , "-i", "<fn=1>\xf1e6</fn>"
         , "-O", "<fn=1><leftbar>  \xf1e6</fn> <timeleft>"
         , "-o", "<fn=1><leftbar></fn1> <timeleft>"
         , "-H", "10", "-L", "7"
         ] 50 "batt0"

where 0xf1e6 displays a little plug. here's a peek at the corner of my desktop with a charging battery:


The only thing we needed to enable this little feature was to implement indexing on the foreground bar string when the special value 0 is passed, a really small change codewise. Moroever, the feature is generic and applies to any horizontal bar in any monitor, so one can play similar tricks in many places.

This feature will be available in the forthcoming xmobar 0.36 release, but you can of course just grab it from its master branch.

Tags: programming xmobar
06 Aug 2020

in no particular order xi

Interesting bits elsewhere:

Tags: sundry
23 Jul 2020

in no particular order x

Interesting bits elsewhere:

Tags: sundry
14 Jul 2020

in no particular order ix

Interesting bits elsewhere:

Tags: sundry
09 Jul 2020

this is shakespeare


This Is Shakespeare: How to Read the World’s Greatest Playwright by Emma Smith

Emma Smith's tour through some of Shakespeare plays was a really interesting read. Her main thesis is that Shakespeare rarely provides answers, he just asks questions and plagues his plays with ambiguity: that's why every age finds works so modern, the key to their eternal relevance. We pick the interpretation that suits our times best, the genious being, of course, in writing something so malleable and covering so many facets of human experience.

One of the ways of being this wide is by a paucity of stage directions. For instance, in the final monologue of The taming of the shrew, there's no indication about the attitude and body language of Kate while she delivers her surrender, so one can imagine her kneeling and make it the misoginistic piece, or standing with a sneer, a stalwart of feminism (when i am feeling cynic, i suspect that Shakespeare was just being lazy, and the meaning was so obvious to everyone at the time, that no directions were needed).

Another funny example is discovering how A midsummer's night dream, our children and Christmas favourite, can very easily be read in a rather more lewd way.

I was also a bit surprised by how often Shakespeare reused and adapted plays and histories by other authors, most of them now forgotten. His genious here was of course writting them better and twisting their plots almost invariably to improve them; but it's funny to imagine what would have become of him in modern times, where the social media crowd would have immediatedly cried wolf, pointing their fingers to the plagiarist (and god knows what else) and asking to #CancelShakespeare.

Anyway, a very entertaining and highly recommended book!

Tags: books
Other posts
Creative Commons License by jao is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.