FMUtils.Screenshot
文件大小: unknow
源码售价: 5 个金币 积分规则     积分充值
资源说明:A screenshot library used by ProSnap
    _________  ____   _ _   _ _       _____                              _           _   
    |  ___|  \/  | | | | | (_) |     /  ___|                            | |         | |  
    | |_  | .  . | | | | |_ _| |___  \ `--.  ___ _ __ ___  ___ _ __  ___| |__   ___ | |_ 
    |  _| | |\/| | | | | __| | / __|  `--. \/ __| '__/ _ \/ _ \ '_ \/ __| '_ \ / _ \| __|
    | |   | |  | | |_| | |_| | \__ \_/\__/ / (__| | |  __/  __/ | | \__ \ | | | (_) | |_ 
    \_|   \_|  |_/\___/ \__|_|_|___(_)____/ \___|_|  \___|\___|_| |_|___/_| |_|\___/ \__|


### A screenshot library for ProSnap
(but you can use it for whatever - see _license.txt_)


### Nuget
    Install-Package FMUtils.Screenshot


### State of the Code
- Mostly operational


### Usage
Create a screenshot by creating a new `ComposedScreenshot` object.
Strictly speaking, the only decision you need to make is whether to pass a Rectangle or window handle.

    new ComposedScreenshot(this.Handle).ComposedScreenshotImage.Save("example-screenshot.png", ImageFormat.Png);

or

    new ComposedScreenshot(new Rectangle(0,0,100,100)).ComposedScreenshotImage.Save("example-screenshot.png", ImageFormat.Png);

`ComposedScreenshot` is the main control object.
This itself subclasses the lower level `Screenshot` object, and builds it out with additional useful functionality, such as a composition stack, rounding corners, and shadow effect functionality.
You get the image out with the `ComposedScreenshot.ComposedScreenshotImage` property.


See **[ProSnap](https://github.com/factormystic/ProSnap)** for an example of how I built an end-user application out of it.


### Where you can help
**FMUtils.Screenshot** can create screenshots either by copying the raw screen image, or by creating a backing form, registering a 1:1 sized DWM thumbnail, and copying that.
The latter method has the pleasant side effect of making Aero-glass effects opaque.

Other screenshot applications use slightly more advanced methods, such as taking two screenshots with the backing form alternately black then white, the combination of which can be used to determine per-pixel opacity.
That would be a great feature for this library as well, so it's an open task for anywho who wants to take a crack.

本源码包内暂不包含可直接显示的源代码文件,请下载源码包。