quephird / happiNESs

An attempt at an NES emulator written in Swift
5 stars 0 forks source link

Allow user to set scale of emulator #53

Closed quephird closed 1 month ago

quephird commented 1 month ago

This PR exposes a new picker from within a new menu item in the app to select the scale for the emulator, from one of 1x, 2x, or 3x. Both the image and the surrounding window are resized accordingly.

Console has a new scale property that the .frame() modifiers for both ContentView and Screen respond to. ContentView also has the .fixedSize() modifier and in conjunction with the .windowResizability(.contentSize) modifier for the top Window component ensure that that the window and its content resize upon changing the value from the menu picker.