So far I was able to copy a white region in the background layer and drag it to the place where I need it on the text layer, but that seems klutzy to me.
That's probably as accurate as you'll get with PS and text.
Another option would be to play around with the Outer Glow effect which might give you something close to what you desire.
If I am overlaying text across a multicoloured BG and need something to contrast against, I use a semi transparent tone that lets some of the BG show through. It just looks more professional than a stroked outline or block of solid colour. This would be more in a page layout application like inDesign or Publisher though. This could be in a filled text box, but shapes work better because you can use rounded corners etc.
If you want to use Photoshop though, having laid down the text layer, you can control click its layer thumbnail to load its selection, which opens up all sorts of posibilities, like filling that selection with a picture on a different layer. Layer styles are definitely the most convenient route to take, but you can be more creative taking a different route.
Thanks Noel again. You are great in this work.
Thanks for all the great ideas. I was experimenting with the blending options and had another idea.
I inserted a white filled rectangle so it appeared behind the text. Then I selected blending options for that layer, and gave the rectangle an outer glow, blend mode: normal, 100% opacity, white, technique: softer, 25% spread, size: 5 px.
The only problem was that I could not get rid of the thin black border on the rectangle. It only appears when I click on the rectangle's layer. How do I change the color of the rectangle's border?
Sounds like the path is becoming visible... Do you see little handles at the corners? Those handles appear to allow you to alter the path that defines the shape (e.g., rectangle).
They won't appear in your work product.
You can hide them by making the PATHS panel visible and clicking somewhere on it other than on the path that's selected.
That’s the shape layer surround. It will only appear if you select the shape layer. It doesn't print so don't worry about it.