Preheat oven to 350°F.
Grease a 9x13" baking dish and set aside.
In a large skillet over medium heat, melt butter and add the onion. Cook onion until onion tender.
Add garlic, thyme, rosemary, flour, stir and cook for 1-2 minutes.
Reduce heat to low and add milk a little at a time whisking very well between each addition.
Next, stir in the cream and chicken broth, into the mixture. Add paprika, salt, and pepper and bring to a boil, boil for 1 minute. Remove from heat.
Arrange ⅓ of the potatoes into the prepared baking dish. Topped with ⅓ of the ham, distributing evenly, next, and ⅓ of the sauce. Repeat the layers.
Top with cheese. Cover with aluminum foil.
Bake covered for 45 minutes. Uncover and bake for 20-30 more minutes, or until potatoes are tender.
Cool for at least 15 minutes before serving.
Garnish with parsley and serve.