Preheat broiler.
Cut bell peppers in half lengthwise; discard seeds and membranes. Place pepper halves, skin sides up, on a foil-lined baking sheet; flatten with hand. Place onion halves, cut sides up, on baking sheet. Broil 15 minutes or until peppers are blackened. Place peppers in a zip-top plastic bag; seal. Let stand 15 minutes; peel. Cut onion into slivers, and set aside.
Preheat oven to 400°.
Cut 4 pepper halves into strips; set aside. Chop remaining pepper halves. Combine chopped peppers, onion, potato, rosemary, salt, and garlic in a bowl; toss well.
Arrange potato mixture in a 13 x 9-inch baking dish coated with cooking spray. Combine milk, black pepper, and eggs; stir well. Pour milk mixture over potato mixture. Sprinkle with cheese. Cover and bake at 400° for 1 hour and 15 minutes. Uncover and arrange pepper strips on top in a lattice pattern. Bake an additional 30 minutes.