Canteen—which several others have already recommended—is a good choice if you can get in. I would also recommend Café Claude, though I find its vintage, zinc-topped bar too narrow to comfortably dine at, and so I would recommend a table.
Across the alleyway from Café Claude is Claudine, a sister restaurant which serves up a more modern take on French cuisine in a casual environment. Claudine has no website, but I'm including the link to Michael Bauer's review in "The Chronicle."
A bit farther away from Union Square (but still walkable) are the dual Italian restaurants of Perbacco and Barbacco. Perbacco is the more formal of the two, while Barbacco, a high energy trattoria, is as close to the Vespa smoke and espresso of urban Italy as you're likely to get this far from Rome or Milan.