I have a mouse with a trackball on it (like this, comfortable for your hand ).
But it means I have no middle mouse button, instead I have two extra buttons on the left and the right.
I want them (or one of them) to have the same sort of effect as the middle mouse button (e.g. in xterm when you want to paste text, you have to use the middle mouse button, and of course in webbrowsers etc. for scrolling).

However I can't find how to do it? System->Preferences->Mouse leads to nothing regarding changing the effect per button.

I found this thread, the thread-starter has the same mouse, however the thing the thread-starter comes up with as a solution is not what I want, and I can't see any general concept behind it.