I've noticed this behavior in Lion's Terminal.app:
Let's say I have some text selected in a non-active terminal window. Meaning, another window is active – it could be another terminal window, or another app's window. If I click on the window with the selected text without clicking the selection itself, the text remains selected when the window is activated. However, if the click happens to be on the selected text, the text becomes unselected.
Is there a way to prevent the unselect behavior? I have to consciously avoid clicking the selection, otherwise I need to re-select (very annoying because text-selection often requires precise pointer movement).
The behavior is also inconsistent for no apparent reason – why have special behavior if the text is clicked?
This only seems to happen with the Basic profile (I haven't tested all of them though). If I use something like Grass or Homebrew, the selection is retained.