In the world of comics, one of the most universally recognized methods for showing speech is the speech bubble. The basic bubble is an oval or rounded oblong where the background of the picture is obscured. The bubble contains the text being spoken, and usually has a curved pointed section which aims towards the mouth of the speaker.
In the above example, we can see that the guy on the left is greeting the guy on the right - who is clearly happy to see him.
The speech bubble replaces the caption as seen on older comics and cartoons - the picture would appear alone, and below it would be a dialogue or other form of text. A cartoon frame can contain more than one speech bubble, which can help to make the dialogue - especially the problem of who is speaking which line - more clear.
There are many variants possible, the pointer can become a simple line; the surrounding box can be totally omitted, or changed in shape to emphasise an emotion. A jagged box, for example, will often denote shouting. It is also commonly used to show electronic communication - a TV, telephone or intercom speaker will usually have a jagged bubble, or jagged pointer.
A thought bubble is very similar, but usually has 'cloud'-shaped sides, and instead of a pointer, a few circles of decreasing diameter aim towards the thinker. An example:
.oO(Where did I leave my keys?)
Thanks to mfk for the note about electronic communication.