Step 1: Some things to do before straighten the image.
Open your image in gimp.
If the rules aren't visible active them by going to View > Show rules.
Place your mouse cursor in the horizontal ruler and drag a guide out of the ruler and place it just slightly above the center of a clear horizontal line.
If you want to move the guide activate the move tool in the toolbox and drag the guide to the right place.
Step 2: Straighten the image
Activate the Rotate tool in the toolbox.
Now you can rotate the image by dragging in the image. The horizontal guide you've made in the first step will help you to see when the image is straight.
Hit the rotate button in the Rotate window.
Step 3: Cut of the transparent parts
Activate the "Rectangle select tool" in the toolbox.
Drag over the image to make a selection.
Fine tune this selection by dragging at the sides/corners of the image.
When the selection is good go to Image > Crop to selection.
And your finished.