Articles by Alan Briolat

  1. Batch Re-tabbing Files with Vim

    So you have your favourite tabbing convention, but you've ended up with some files in some other convention, for example tabs instead of 4 spaces. If you use Vim and already have it set up to your liking, the :retab command will replace indents in the current buffer with ...

    Read more...
  2. C is not MATLAB

    Refactoring some code at work today, I came across a classic example of somebody attempting to use one language like another. The project in question is a port from MATLAB to C, and the purpose of the function is to see if a square matrix is symmetrical within a certain ...

    Read more...
  3. C linked list macro

    Here's a simple macro I came up with a few weeks ago for easily defining linked list types in C:

    #define LINKED_LIST(type, name)     \
        struct name ## _ {              \
            struct name ## _ * next;    \
            type data;                  \
        };                              \
        typedef struct name ## _ name;
    

    Usage is simple:

    LINKED_LIST(int, int_ll);
    

    gives the same type as ...

    Read more...
  4. Fixing ugly Qt fonts in GNOME

    So far every time I've used Qt applications under GNOME, especially VirtualBox, I've found the Qt font rendering to be appalling. See this screenshot of VirtualBox alongside the GNOME appearance dialog:

    |filename|/images/virtualbox_fonts_1.png

    As you can see, most of my font settings are at the default "Sans" font. The "Sans ...

    Read more...
  5. Mouse Button Remapping with HAL

    I've had a Logitech MX1000 mouse for a few years now, and the two most important features for me have been the ergonomic build and the few extra buttons. Something I've always found with many-buttoned mice is that the side button closest to the thumb is a much ...

    Read more...

Page 1 / 3 »