Tag: zzz

Get the keyboard layout you want

some-key-stickersI started using computers ages ago in Argentina. We only had US Qwerty keyboards back then and I’ve got used to them. The Spanish keyboards appeared later on and I never switched. I never understood what was the deal with those. I can type almost any character I want with a US Qwerty keyboard, even Spanish ones like á, é, í, ó, ú, ñ, ü. But furthermore, most characters used for programming are much harder to access in a Spanish keyboard.

Years latter I switched to Dvorak, making my problems of layout even worse, but increasing my geek-coolnes. In some keyboards you can move the keys around to convert US Qwerty into Dvorak, but you cannot convert Spanish into Dvorak by moving keys around. That’s because the symbols are not grouped in the same key. While in both US Qwerty and Dvorak you have a key that has “.” (dot) and “>” (greater than) in Spanish you have a key that has “<” (lower than) and “>” (greater than).

So if you want to switch Spanish to Dvorak, like I did, or you want to switch Spanish into US Qwerty or French into German, or whatever, you have to totally re-label the keyboard. There’s a company called Hooleon that makes a Keyboard Replacement Overlay Kit that will allow you to turn any keyboard into US Qwerty, or Dvorak, or anything you can think that uses the US Qwerty set of keys. It’s basically a set of stickers that you put on your keys. They are very durable, more than some keyboards, and they look quite good.

They also make a Qwerty-Dvorak conversion kits, which is the best option to convert US Qwerty into Dvorak (they don’t provide numbers and other keys that stay the same). And if you switch to another language they have many language-changing kits to many languages. If you have a keyboard, you might just swap it for another one, but if you have a laptop, this solution is excellent. I’m really grateful there’s a company providing this product because it’s served me well for ages until I got a really good keyboard.

Now I have a MacBook Pro with beautiful back-light keys. I’m not going to put stickers on them, I have to remove them and re-place them. That’s not trivial in a laptop keyboard, so I’m still building up courage.
key-stickers

Disclaimer: I’m in no way affiliated with Hooleon, I just love their products.

Reviewed by Daniel Magliola. Thank you!

Printing the class-path in Clojure

Let’s compare how we print the class-path in Clojure and how we do it on Java.

In Clojure:

(println (seq (.getURLs (java.lang.ClassLoader/getSystemClassLoader))))

In Java:

import java.net.URL;
import java.net.URLClassLoader;

public class PrintClasspath {
    public static void main(String[] args) {
        //Get the System Classloader
        ClassLoader sysClassLoader = ClassLoader.getSystemClassLoader();

        //Get the URLs
        URL[] urls = ((URLClassLoader)sysClassLoader).getURLs();

        for(int i=0; i&lt; urls.length; i++)
        {
            System.out.println(urls[i].getFile());
        }
    }
}

To be fair, the output is not the same, but the effect is.