Testing the application's behavior

Now, let's test our screenshot tool:

  1. Run the Electron application and drag the window around to select a portion of the screen. In this case, we are using the Visual Studio Code window as the source:

  1. When you are ready, click the Snip button. Notice how the window disappears for a moment, and then you get the default system viewer showing an image:

  1. Users can then use the default Save As functionality of the preview tool to save the file.

Congratulations on getting your first screenshot tool up and running! Now, let's improve it by adding support for the system tray and keyboard shortcuts.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.12.161.77