mirror of
https://github.com/cyanfish/naps2.git
synced 2024-10-05 20:07:42 +03:00
5
3. Project Structure
Ben Olden-Cooligan edited this page 2023-03-10 22:20:39 -08:00
The NAPS2 solution has a number of projects:
NAPS2.Sdk
is available as a Nuget package and is designed to be reusable. See the doc and samples. Sdk projects are provided under a less restrictive license (LGPL).NAPS2.Images
projects provide an abstraction used by NAPS2.Sdk to work with native image types on each platform (Gdi: System.Drawing, Mac: NSImage, Gtk: PixBuf).NAPS2.Lib
projects are specific to the NAPS2 desktop application. The main Lib project has most of the NAPS2 desktop code while subprojects (WinForms, Mac, Gtk) have platform-specific code.- The
NAPS2.EtoForms
namespace contains the GUI code. SpecificallyNAPS2.EtoForms.Ui
contains the form classes.
- The
NAPS2.Internals
includes shared code used by both NAPS2.Sdk and NAPS2.Images.NAPS2.App
projects generate actual executables for NAPS2 applications. Note that Mac and Gtk executables are multi-purpose (i.e. they can operate in desktop, console, or worker mode) while WinForms has separate .Console and .Worker executables.NAPS2.Setup
contains installer configuration files and other files that don't have anywhere else to go.NAPS2.Tools
provides a command-line tool "n2" for various development tasks (e.g. packaging) and isn't otherwise distributed. See doc.
And test projects:
NAPS2.Sdk.Tests
- General tests for NAPS2.Sdk, NAPS2.Images, and the NAPS2.Images.* project corresponding to the current platform.NAPS2.Sdk.ScannerTests
- Tests that can be manually run to verify functionality with a real scanner. See HowToRunScannerTests.cs.NAPS2.Lib.Tests
- General tests for NAPS2.Lib.NAPS2.App.Tests
- Tests that run against real executables and packages, including GUI automation tests. Some tests are designed to run with "n2 verify".
Also see related repositories:
- naps2-wia - Windows Image Acquisition (WIA) wrapper, used by NAPS2.Sdk on Windows.
- naps2-escl - Implementation of eSCL/AirScan network scanning, used by NAPS2.Sdk on all platforms.
- naps2-sane - Prebuilt binaries for Scanner Access Now Easy (SANE), used by NAPS2.Sdk on macOS.
- naps2-tesseract - Prebuilt binaries for Tesseract-OCR, used by NAPS2.Sdk on all platforms.
- naps2-pdfium - Prebuilt binaries for Pdfium, used by NAPS2.Sdk on all platforms.
- naps2-pdfsharp - Fork of PdfSharpCore without ImageSharp as a dependency, used by NAPS2.Sdk on all platforms.
- naps2-components - Github project used to serve OCR language downloads.