In a stand mixer with the dough hook attachment, combine warm water, yeast, sugar, and salt. Let the mixture sit for about 10 minutes until it becomes foamy. Incorporate the flour, butter, and chopped rosemary, and knead on medium speed for 12 minutes. Cover the dough with a damp, warm cloth and leave it in a warm spot to rise for 1 hour or until it doubles in size.