Sunday, October 4, 2009

Reduce image file size with GIMP

This is an easy way to reduce image file size. What you have to do is to convert the image mode from RGB to Indexed colours.

In GIMP, click on Image > Mode > Indexed.

Finally, change the "Maximum number of colors" property value from 256 to 16 or 32 as shown in Figure 1.

Figure 1: Indexed Color Conversion

Saturday, October 3, 2009

How to upgrade Ubuntu 9.04 to 9.10

To upgrade Ubuntu 9.04 to 9.10 is easy.

First, press Alt+F2 to get the "Run Application" (Figure 1). Type in
update-manager -d

and, click Run. 
Figure 1: Run Application
Finally, click Upgrade on "Update Manager" (Figure 2).
Figure 2: Update Manager


Kursus blog untuk pensyarah

Kursus blog untuk pensyarah by rizauddin

Friday, October 2, 2009

My VIM .vimrc file for working with Python

Here is the VIM .vimrc file that I use to work with Python.
syntax on
set nu
set ts=4
set sw=4
set sts=4
set autoindent
set smartindent
set expandtab
set smarttab
It will

  1. Display the line number.

  2. Set tab stop to 4.

  3. Enable you to use < and > to indent or unindent a block in visual mode.

  4. Insert spaces instead of tab, when pressing the tab button.

Wednesday, September 30, 2009

Multiple column layout in LaTeX

To create a multiple column layout in LaTeX is easy. What you need is the multicol package.
\usepackage{multicol}


For example, to create a two column layout.
\begin{multicols}{2}
put the contents here
\end{multicols}


To manually break the column, use the \columnbreak command.
\begin{multicols}{2}
Column 1 \columnbreak Column 2
\end{multicols}


If you are using standard LaTeX class, such as "article", you can simple create a two column layout using the code below:
\documentclass[twocolumn]{article}

How to change Shiretoko codename to Firefox

Shiretoko is the development codename for Firefox 3.5.x.

To change the User-Agent identification to Firefox,

  1. Enter about:config in the address bar.

  2. Enter general.useragent.extra.firefox in the field at the top.

  3. Change its value from Shiretoko/3.5.4pre to Firefox.