Menu

[Solved]-1 Goals 1 Build Application Uses Mouse Keyboard Events Use Buttons 2 Build Simple Picture Q37214594

1 Goals. 1. To build an application that uses mouse and keyboardevents. Do not use buttons at all. 2. To build a very simplepicture using the Java FX graphics facility. 2 Building a SnowmanThe goal is to make a picture of a very simple snowman by using thekeyboard and mouse. Make your application accept inputs and takeactions in the following order: Instructions for Program 7. 1.Create a stage that is square or taller than it is wide. Make itbig enough for a snowman. You need only one Scene and one Pane. 2.Display (somewhere in the scene) a list of at LEAST 3 possiblecolors, and the letters to type to select one of them. Create twoof these colors yourself and use one color from the fx Color class.Please choose a color: Y = Yellow P = Pink … 3. Wait for the userto type one of the color codes. Then change the background of thepane to that color. 4. Then remove the color menu and replace it bythe first prompt, below. 5. Prompt the user to click the mouse nearthe top of the window. 6. Display a black circle filled with whitecolor whose center is on the click-point. Choose the radiusyourself to be approximately 15% of the height of your window. Usethe x-coordinate of this first click as the x-coordinate for thenext two circles. 7. Prompt the user to click again, below the firstclick. Calculate the radius of circle 2: radius2 =(point2.y−point1.y−radius1) Display another circle with point1.x,point2.y, and radius2. 8. Prompt the user to click a third time,below the second click. Calculate the radius of circle 3: radius3 =(point3.y−point2.y−radius2) Display another circle with point1.x,point3.y, and radius3. 9. Prompt for two clicks to show where theeyes should be. Put a little circle at each click-point, withradius just big enough to see white in the middle of the circle.10. Prompt for 3 or 4 or 5 clicks to show where the mouth shouldbe. Put tiny circles at each click-point. 11. Prompt for two clicksto show where the two coat-buttons should be. Put a little circleat each click-point. Program 7: Mouse and Keyboard Events CS 617Spring 2015 2 12. Prompt the user to click where the arm shouldattach to the body, then drag the mouse to the place where the handshould be. 13. Prompt the user to do it again for the second arm.Take two screen shots: one when the application first starts, and asecond that shows your completed snowman. Submit the two screenshots with your code. The code should be one java file.

Expert Answer


Answer to 1 Goals. 1. To build an application that uses mouse and keyboard events. Do not use buttons at all. 2. To build a very s… . . .

OR


Leave a Reply

Your email address will not be published. Required fields are marked *