I fenced my veggie garden with 6' chicken wire; keeps my free ranging birds out. Unless your coop is really huge, I doubt locking them up would work out after they have free ranged. I'd be afraid they would just peck and feather pick, or worse, the little cannibals....
I have mostly shrubbery; they don't bother most of them, but have scratched around a couple types so badly they died. Only flowers I grew last year were zinnias and they did not bother them.
Only thing I can figure out is a large chicken yard made of chicken wire. Since it would only be to keep them in, it would not be expensive; a 150' roll of 6' chicken wire is only about $40 around here, and two of them makes a really nice sized yard. If there is a fence around the pasture you could add chicken wire to it, or at least a section of it, for not too much money or labor, if the coop is in or adjacent to the pasture.
You could try the picket fence but it is not cheap and I don't see why they wouldn't jump into the flowers from it.
I dunno. Chickens and gardens don't go together very well, except off season.