prntscget.app

Lightshot prnt.sc (and prntscr.com) gallery downloader.

Members

Functions

downloadAllImages
void downloadAllImages(Appender!(RemoteImage[]) images, Configuration config)

Downloads all images in the passed images list.

downloadImage
bool downloadImage(string url, string imagePath, Duration requestTimeout)

Downloads an image from the prnt.sc server.

ensureImageDirectory
bool ensureImageDirectory(string targetDirectory)

Ensures the target image directory exists, creating it if it does not and returning false if it fails to.

enumerateImages
uint enumerateImages(Appender!(RemoteImage[]) images, JSONValue listJSON, Configuration config, size_t numImages)

Enumerate images, skipping existing ones.

getImageList
auto getImageList(string cookie)

Fetches the JSON list of images for a passed cookie from the prnt.sc server.

handleGetopt
GetoptResult handleGetopt(string[] args, Configuration config)

Handles getopt arguments passed to the program.

hasValidJPEGEnding
bool hasValidJPEGEnding(ubyte[] fileContents)

Detects whether a passed array of bytes has a valid JPEG ending.

hasValidPNGEnding
bool hasValidPNGEnding(ubyte[] fileContents)

Detects whether a passed array of bytes has a valid PNG ending.

main
int main(string[] args)

Program entry point.

run
int run(string[] args)

Program main logic.

Structs

Configuration
struct Configuration

Aggregate of values supplied at the command line.

RemoteImage
struct RemoteImage

Embodies the notion of an image to be downloaded.

See Also

Meta