Grey java windows

November 18th, 2008

A problem I’ve hit many times is the grey window java issue, where java-windows will be all grey and have no content. Danske Bank uses java for their homebanking solution and for every transaction a java-windows pops up. So this bug meant no homebanking for me (or rather, forced me to use a windows-based PC for paying my bills).

Today however, I stumbled across a mail on the awesome mailing list mentioning a tool called wmname that apparently solves this issue, by setting a proper netwmname… and lo and behold, this small (53 lines of C code) program actually made homebanking work again \o/. Just compile, install and run it with an argument (the name of your window manager, could be anything).

Is this awesome? (y/Y)

It is actually doable!

November 6th, 2008

See DR, it’s not impossible to give people access to your media archives in an easy way. Please get your act together and start working on something like that instead of that lame web-based player and your sucky “Bonanza”-imitation.

Since I’m forced to pay a fee to you because of my internet connection, please give me (and everybody else, not just us “opensource freaks”) content for my money’s worth.

Pointless project of the day

October 16th, 2008

I came across a link to Writeroom today. Apparently it is an application designed to give you:

  • A full-screen window with a minimalistic text-editor
  • No weird widgets, buttons or paperclips
  • No automatic spelling and grammar corrections
  • Menu-bars that only appear when you need them
  • Support for different kinds of cursors. The standard mouse-cursor, a blinking/non-blinking bar and so on
  • It runs either standalone or as part of other applications
  • Saves to plain-text
  • Choose your own fonts and colours!! ZOMG!

But wait, this sounds familiar right? I’m writing this in my favorite editor in my favorite terminal. Let’s see: A full-screen window and minimalistic text-editor? check. No widgets? check. No interference from spelling bees? check. No menu-bars unless you need them? check. Different cursors? check. Standalone and embedable? check. Saves to plain-text? check. Support for different fonts and colours? check.

Oh, and it’s free too!

Those who don’t know UNIX are doomed to reinvent it — badly

vim running fullscreen in awesome

The worst thing…

September 28th, 2008

The worst thing about Open Source Days [danish] isn’t choosing which talks to attend (I never have time for talks anyway). The worst thing is doing weird LaTeX hacks to get their logo placed correctly in the agenda
Turns out there’s this cool environment for wrapping figures in text named ‘wrapfig’ (gee, who thinks up all these names) that you can use for positioning an image a little more intelligently than the default, left-aligned placement. Alas, said environment (or something else - I am by no means a LaTeX guru), doesn’t play nicely with tables and as the majority of the page is made up by the actual agenda in a table, that means the logo ends up whereever it fits; in this case smack in the middle of the page. A lost cause? Of course not! <leonidas>This is LaTeX!</leonidas>. Take a look at this beauty:


\AddToShipoutPicture{
 \put(0,0){
  \parbox[b][420mm]{530mm}{
   \vfill
   \centering
   \includegraphics[width=60mm]{logo2008_small}
   \vfill
  }
 }
}

[courtesy of the same guy who wrote the aforementioned blagpost, Jesper Nyerup]

Of course, you might have to fiddle with the actual placement of the parbox but as far as I could tell from my experiments, this will place the image whereever you want it, no matter what is above or below it layerwise. At the point where Jesper pasted that, I had been driven to the nastier corners, fiddling with boundingboxes and another parbox-hack, none of which worked remotely as well as this solution.
An ugly hack, nonetheless, don’t use it if you can avoid it.

Also, this requires you to include the eso-pic package in your preamble.

Also, if you happen to attend Open Source Days on saturday, by all means come by the Exherbo user stand where we will be happy to act like the elistist bastards people assume we are and tell you exactly why you shouldn’t use Exherbo just yet.

radio on the command-line

September 16th, 2008

I got bored of remembering paths to playlists for streaming radio all the time, so I wrote a short script to do the job for me.
Rather than explaining what it can and can’t do, here’s some of the output from –help:

The following commands are recognised:
radio tag
plays the station associated with tag

radio info tag
shows information for tag

radio stop
stops playback

radio status
prints status

radio random
start playing a random station from your list

radio np
prints the currently playing track, if the stream supports it

radio
prints a list of stations. Use -v for detailed information

The script will fork, exec mplayer and then kill the parent so you won’t need to have the script running all the time. State is saved so you can get status info at any time (if you want now playing support in your IRC client of choice, for example), stop playback or switch station (if radio is already playing a station when you ask it to start playback, it will kill the old one first) and so forth.

The script needs mplayer, perl and the YAML perl-module. YAML is available from cpan and probably also from your distribution of choice.

The .radiostations file is a YAML-file with a simple layout:

tag:
   name: Name of the station
   desc: Description of the stations
   path: Path to the station's playlist (a .pls file, usually)
   stream: Misc. stream information.

The tag is what the script uses to identify a station, when you ask it to play one. It must be unique or a later station with the same tag will override the first one.

The radio script
A sample .radiostations file
The .radiostations file contain all SomaFM, DI.fm and SKY.fm stations and a few stations from DR (p1, p2, p3, boogie, barometer and electronica).

Note that the “Now Playing” feature is somewhat suboptimal. It reads the info from ICY, but not all streams use that and not all streams keep it updated. There is no general solution though, and for most sane stations (SomaFM and some DI and SKY.fm streams at least) it should work just fine. The DR streams won’t have np-support since DR sucks big time…

As usual, no guarantees or anything else. Use it if you want to :-)

There’s a similar shellscript [danish] written by Jesper Nyerup if you want to avoid perl and the YAML-module.

And it even works!

August 27th, 2008

How cool is that?
KDE 4.1.0 on Exherbo

Impressions from Beatday ‘08

August 18th, 2008

Although they’re a bit belated due to an extremely busy week, here are my impressions from Beatday ‘08.

Beatday took place at Docken which is very close to where I live (it was nice to ride a bike to a festival, for a change). It’s not a very big area but it set a nice scene and theme for the festival which appeared to be centered towards well-known subculture bands (ie. bands that are popular within their respective subcultures but who’ve seen none to moderate mainstream success).
Beatday sported three scenes where two of them could feature bands simultaneously.

It was pretty clear from the crowd that waited outside on the first day of the festival, that this was clearly the main day. Many of them seemed quite unimpressed with the program for sunday and did not appear to have intentions of returning. There’s no doubt that the most popular bands played saturday but you’d still think that artists such as Tina Dickow, Amy MacDonald, The Savage Rose and Yoav should be able to attract a crowd… but I digress.

Saturday started off with Blue Foundation and Veto playing at the same time — a nasty clash. I decided to go with Blue Foundation in the end and I definitely don’t regret that as they were as good as ever. Their setlist contained a fair mix of tracks from Life of a Ghost and Sweep of Days. As usual Blue Foundation are highly reccomendable :-)
Next up was Kissaway Trail which was… ok I guess. Nothing to write home about and I probably wouldn’t have seen their gig if there were anything else to do but oh well. We went to see The William Blakes after them and that was a very positive surprise. Apparently it was their first time playing live, but aside from a bit more chatter than usual you couldn’t really sense it. They delivered some very beautiful music with some highly interesting lyrics — interesting enough that I ended up buying the album last week. If you get the chance go see them! Or listen to their album ‘Wayne Coyne’ (yes, named after the guy from The Flaming Lips, who they had actually met up with the day before when The Flaming Lips played in Tivoli) it’s quite addictive.
Mercury Rev played at eight o’clock and though it was quite clear that a lot of people had come mainly to see them I didn’t find their gig or their music very pleasant. But again there weren’t a whole lot of alternatives so we sat through it. Next up was a choice between Figurines and Guillemots. I went with Guillemots after warm recommendations from a friend and it definitely wasn’t a letdown. It was wonderful music and yet again, my list of bands to check out a bit closer grew. I mostly suck at categorising music which is why I hardly ever do it but I think pretty much all people would have a hard time defining the music of Guillemots (which is probably why they’ve been shoved under the ‘indie’ label). You have to listen to it for yourself.
We rounded of the day with Sigur Ros. There’s not much to say about them — they just rock!

Sunday, as guessed, turned out to be a bit less anticipated and there weren’t nearly as many people when I showed up. There might’ve been more people to see Annika Aakhjær or Aura but I doubt it.
The first act I saw was Yoav. The guy and his one-man show gained fame here in Denmark after being played on national radio (a fact he mentioned as well and seemed quite thrilled about). If you’ve listened to P3 you’ve probably heard his ‘Club Thing’ or ‘Beautiful Girl’. Yoav belongs to that group of artists that only need a guitar and a mixer to create entire symphonies — and he’ll do it for you live, right there on the stage. Impressive, truly impressive. As a sidenote, I’m actually listening to his album ‘Charmed & Strange’ right now. Go find it!
After Yoav it was time for Thåström. Their music was strangely hypnotizing, their songs appearing to glide together. They sang about everything and nothing in particular… or maybe I was just getting tired… that’s highly possible :-)
Next up was Tina Dickow - highly recommendable and fantastic as usual. This time she was accompanied for a while by Søren Huss from Saybia, singing a song from Dickow’s Count to Ten album as well as a song from Saybia’s Eyes on the Highway album.
To round it all off was The Savage Rose. It was impressive to see a band full of vigor, even though, as Anisette said herself they started touring in ‘67… and they’ve toured ever since. The mood of this concert was something I think I’ve never seen before. Maybe it was because of the high concentration of fogheads and maybe it was simply because of the magic that Savage Rose has delivered for more than 40 years — but it was definitely special and a perfect way to end two days of music.

To sum things up Beatday was a nice mix of well-known bands I like and new ones I’ve never heard or never seen live before. They seem to have found that combination of names that will attract people and names people will be delighted to discover, that any successful festival will have to figure out, so I definitely hope I’ll have to opportunity to return again next year.

Ten Irssi scripts you should try before you die

August 13th, 2008

We all know it — the only real IRC client left is Irssi. Irssi is good, better & best but even the best piece of software can be adapted for your own needs. Pimped, in other words. As for theming, window handling, effective use of screen and other cool tricks you will find plenty of guides out there. But I thought I’d offer you my take on the Irssi scripts that turn an IRC client into a spaceship control panel…

  1. trigger.pl
    The trigger script is a bit tricky to use at first, but once you’ve gotten used to it, it really grows on you. trigger.pl can be set up (from within Irssi of course) to trigger on various events and messages and perform custom Irssi commands. You can use trigger.pl for all sorts of neat tricks. Want to hilight on a specific word, in every channel except for one? Add a hilight, then use trigger.pl to rewrite the word in the specific channel where you don’t want the hilight. Want to automatically kickban anyone sending public away messages to your channel? Use trigger.pl to kick on specific regexps. Want to automatically strip colourcodes from certain nicks? Keep certain nicks from hilighting you? React to certain keywords? trigger.pl will handle all of that for you. You might have guessed it by now, most of these things are something you’d normally write a short Irssi script to handle yourself but with trigger.pl you just have to add a trigger.
    I said it was a bit tricky to use at first — you will find that sometimes your approach to solving a specific problem won’t work and you will have to find another way to do it. You might have to try out a few solutions before you find one that work as intended and without spurious side-effects.
  2. hilightwin.pl
    The purpose of this script is to copy all messages that Irssi hilights for some reason, into their own window. The net effect being that you can create an additional window and keep track of who hilights you and why, without having to switch to the channel where you were hilighted. It’s also nice for keeping a backlog of hilights when you aren’t able to react immediately or when you need to remember stuff. Per default, your privmsgs will also go into that window so you can see them too, without switching between windows all the time. Another advantage is that hilightwin saves you the trouble of scanning back through channel backlogs (the lastlog command can help you with that too, though).
  3. trackbar.pl
    This very simple script adds a little trackbar to every channel window whenever you leave it. A trackbar is just a line of dashes but such a line is very easy to identify when you return to the window and thus makes it easy to find out what happened while you were gone and where you should start reading from. A neat little script.
  4. nickcolor.pl
    Keeping track of a conversation between many people isn’t always easy. nickcolor.pl assigns a colour to each nick and colours that nick for you. It is a lot faster and easier to recognize a colour and identify the nick based on that so you won’t have to read each nickname on each line to know who said what. A word of caution though: nickcolor.pl will rewrite the pubmsg format and add the pubmsg_hilight format. This might clinch with your theme and if that’s the case you will have to modify the script to fit with your theme (it’s not hard though, just edit the two formats in the script to the ones your theme uses).
  5. dccstat.pl
    If you’re using Irssi to send and receive files through DCC you will probably grow tired of having to switch to the statuswindow and type ‘/dcc’ all the time to see how things are going. Use the dccstat script instead. It adds a statusbar item that will show the progress of your dcc sends and gets. The format is highly configurable and so can easily be made to fit with your theme. I have added an additional statusbar in the top of Irssi, that only has the dccstat item in it. It’s incredibly nice and a much easier way to keep track of all that *cough* stuff you download.
  6. adv_windowlist.pl
    Can’t remember which channel has which number? No problem when you have 10 channels, but when that number grows it becomes a pain to remember just which channel is #139 and just where #exherbo went. adv_windowlist is a mess so don’t try to read it or hack a lot on it, but what it does is very neat indeed. It gives you a multiline list of your channels with channel names and whatever else you might want to add. With a lot of channels, that’s obviously going to take a lot of space, so it’s wise to limit it to three lines or something like that and have it only show channels where there has been activity since the last time you visited (just like Irssi’s normal window list). adv_windowlist offers a drop-in replacement and definitely helps those of us who are getting senile.
  7. queryresume.pl
    A very simple script that prints the last few lines of your query with a specific nick whenever you start a new query with that nick. This bit of context is often nice if you have to handle a lot of queries or if your memory just sucks.
  8. len.pl
    Some networks (yes EFNet, I’m looking at you!) imposes some annoyingly short limits on nicklengths, topiclengths, part/kick messages and the like. len.pl will block your action if it includes something that goes beyond those limits. That way, if you ever feel like doing a /nick insanelylongnickname you won’t end up with ‘insanely’ as your nick. A real lifesaver at times.
  9. history_search.pl
    Do you know ctrl-R in bash? The keyboard shortcut that allows you to search through your bash-history as you type? This is an incredibly cool feature and I’ve often missed it in Irssi. Well, not anymore — the history_search script allows you to do just that. Automatically search through your history as you type. Is this awesome? (y/Y)
  10. bitlbee_*
    There are a bunch of different scripts that all helps making bitlbee much nicer in Irssi. To those of you who don’t know, bitlbee is a IM to IRC gateway. bitlbee sets up a simple IRC server you can connect to from your IRC client. From there on, just add your IM accounts and voila — no more need for additional apps to keep track of Jabber, MSN or whatever all the heathens use.
    However, IM isn’t always the same as IRC and so you will face some annoyances with this approach. The bitlbee scripts for Irssi helps alleviate some of that pain by adding tab completion for commands, advanced contact lists, join notices (in your statusbar), proper nick change notifications, typing notices and more. If you use bitlbee a lot, these scripts will save you a lot of time and make the experience less… painful.
    The bitlbee scripts are available from quadpoint.org and the-timing.nl

Of course, there’s a craptic megaton of nice Irssi scripts out there. These are just some of the scripts I’ve found most useful. Feel free to drop a comment about the very best Irssi scripts in your arsenal :-)

Uncle Don’s anime recommendations

July 23rd, 2008

… or something.

I just watched Paprika tonight and it’s FUCKING AWESOME. By all means go watch it. It’s a movie-length animation so you won’t have to spend ages on it and even if you should dislike Paprika (you won’t), you wouldn’t have wasted that much time.
The story, the animation, even the soundtrack is like something of another world. This is definitely the best thing I’ve seen for quite a while.

If you already know your stuff, the names Satoshi Kon, Yasutaka Tsutsui, Seishi Minakami and Susumu Hirasawa should ring a bell. Paranoia Agent, Perfect Blue and The girl who leapt though time. How can it not be good? ;)

Last.fm ramblings

July 19th, 2008

I got hooked on last.fm three years ago. Since then, they’ve had major changes to their website twice. The first time, I was thoroughly impressed with what they did; the improvements were major and allowed for much easier navigation, easier access to relevant content and they somehow managed to pack a lot of information into a small page. I’ve used last.fm as an example of how I want a website to work on a few occasions and generally been very satisfied with it. I’ve even tried to become a subscriber a couple of times but their payment system didn’t work in konqueror or firefox.

I liked how their flashplayer were unobtrusive and just melted in with the rest of the content so it could easily be ignored when I didn’t need it (95% of the time, that is). I liked how the focus seemed to be on user to user interaction with shoutboxes on every user/artist/album/song/event-page, with simple tools for recommending music to other people and simple yet excellent group capabilities.

As such, their new layout which was put up for public testing a few days ago and turned on fully some 24 hours later (unless my sense of time is screwed up which is highly likely) didn’t quite make me feel at home. I decided to give it a few days before I’d start ranting mindlessly about it though and now - a few days later I’ve taken a liking to some of the things while others remain annoyances.

In my opinion, one of the main issues with their new layout is that they’ve moved the shoutbox to the bottom of every page, instead of having it on the right side. I really don’t get why someone thought that was a good idea - the shoutbox is, as far as I can see, one of the major channels of communication used on the site and I fail to understand why it was given such a shabby placement.

Another issue is with their new flashplayer. The former was painted in a shade of grey that made it look like most other content on the site and maybe because of that I never fully realised just how many pages that featured it somewhat needlessly. The new one however, features white text on a totally black background (the important part of it does) which aside from being totally unreadable on my monitor also jumps into your eyes and stabs them with a blunted spoon at every possible occasion. The flashplayer however, is featured prominently where the shoutbox used to be. I wonder why…

So, what else have changed? It seems the dashboard as I knew it is dead and buried. The dashboard showed what your friends were currently listening to (the last two or three tracks), upcoming events your friends had signed up for, a select few music videos last.fm thought I’d like (and it usually guessed right), some recommendations for you, what your neighbors were listening to and a few other useful tidbits of information. In short - the dashboard showed you what was up in your neighborhood. It would seem that the dashboard has been replaced by a new ‘home’ page, that features a list of music recently added to your library (but I already knew that… I listened to it dammit), a few recommendations (four in my case), a link to ‘personalised podcasts’ (aka. free music), a link to recommended videos (why not just show me four videos and let me click on one I want to see, thus saving a whole mouseclick and a whole page request?). If I scroll down there’s also a link to recommended events near me (again, please list a few of them instead).
On the right side there’s a box which lets me listen to last.fm radio. This is one thing I’ve never used on the site since I’m perfectly happy with the last.fm-integration in Amarok. Next up there’s links to my personalised radio stations, yet another thing I listen to from Amarok. Below that I get to see the last song I’ve listened to (y’know, just in case I forgot) and further below, in the bottom right corner is a list of the last song each of my friends have listened to. Why was that list shoved away in favor of stuff I already know (ie. my own music) on the ‘dashboard’ which I take, is there to inform me on what’s going on at the moment?
A few other useful pieces of information have also disappeared from that page. It used to list the last shout someone had made in my shoutbox so I could easily see when people wrote stuff to me. Now it appears I have to go to my user page and scroll down to the bottom and locate the shout-no-longer-a-box-but-an-element-of-a-page amidst the clutter.

There are some other issues but I expect that most of them will be magically resolved as I get a bit more used to the new layout.

Unlike most other negative comments I’ve read I don’t particularly want the old layout back. I’d much rather see some of the greater annoyances (shoutbox + lack of relevant information on home/dashboard) solved within the confines of the new layout - it does after all provide some cool new features such as the music library (just… not on the dashboard thankyouverymuch) and somewhat improved artist/album/song-pages.