`is a very lightweight yet powerful, for everyone who wants screencapture on desktop.
You could customize almost everything such as:
- the logo (tray)
- the location (saving path)
- the format of image
- the cleanup (cache)
- the copy-to-clipboard (automatically)
And yes please take note....
Requirement | Details | Stability |
---|---|---|
JDK | 1.8 | ✔️ |
OS | Windows | ✔️ |
Size | 52 kb | ❣️ |
We made this for java anthusiast... so use it accordingly! But if you need more customization, feel free to post into the discussion issues sections!
-
Grab the last release jar
-
Run the following code:
import fgroupindonesia.printscreen.engine.*;
PrintScreen psEngine = new PrintScreen();
// 1st if you need to screencapture with snipping
psEngine.takeCapture();
// or 2nd if you need to screencapture without snipping
psEngine.setSnippingMode(false);
psEngine.takeCapture();
Incase you need some other functions, try each of these cases :
to enable the tray we have the default logo, but if you need yours here you could customize:
// here if you want to customize the icon
psEngine.setLogo(new File("somefile.png"));
// but also if you dont want to show the icon on tray
psEngine.setLogoVisibility(false);
to help the printscreen save to some other directory you could use these steps:
// this will automatically save to that path
psEngine.setDirectoryPath("D:\\somedir");
// or you could also make asking-directory-mode for saving
// as default is false
psEngine.setAlwaysAskDirectory(true);
Why should we use alwaysAskDirectory? Because some users love to save it into different directory each time printscreen's taken. But where is the default path if nobody change the path? Here it goes...
C://users/AppData/Roaming/fgroupindonesia/printscreen/
Some cases need to switch between JPG or PNG or even grayscale for better purposes here we are :
// you could use :
// PSImageFormat.PNG or
// PSImageFormat.GREYSCALE or
// PSImageFormat.JPG
psEngine.setImageFormat(PSImageFormat.JPG);
as FYI the default is the PNG format.
As default the snipping mode is always to be true. Otherwise, you could switch it to take entire screen for every printscreen's task .
// this will make the app work for taking screenshot entire screen instead of snipping
psEngine.setSnippingMode(false);
you could trace the snipping history everytime screenshot was made. As default the cache is never cleaned, thus to see the details right click the tray and choose history... And the location is located at...
C://users/AppData/Roaming/fgroupindonesia/printscreen/
to clean up those files, you could easily...
psEngine.setAutoCleanup(true);
as we all know, this feature is True by default. Incase you want to turn it off just use :
psEngine.setCopyToClipboard(false);
Okay, you may try Pressing (CTRL + V) after taking screenshot to see the picture!
FYI, this feature is True by default. Incase you want to turn it off just use :
psEngine.setOpenSavedDirectoryFeature(false);
Sure here we go:
- Example 1 : run the default quick run!
- Example 2 : run the entirescreen screenshot taking & copy-paste from clipboard
- Example 3 : run the snipping screenshot taking & ask the user where to save
- Example 4 : run the snipping screenshot taking & save to custom path (programatically)
- Example 5 : run the tray only until the user clicking the menu for screenshot
That's it...! Feel free to use this into your projects.... and if you want to integrate other similar functions for your Software, grab our Leading Experts on social medias for better future with the best technology:
If you want to contribute in different languages / platform. Please fork it out and let me know for it...
Thanks everyone! 🙋♂️
© 2023 - FGroupIndonesia.