Add enums for PDF/A-3 a and PDF/A-3 b compliance

This commit is contained in:
DGdev91
2023-02-16 15:09:26 +01:00
parent 88aaddcf26
commit 3d6a14bea6
4 changed files with 24 additions and 1 deletions

View File

@@ -636,6 +636,8 @@
[InlineData(PdfAStandard.A1A)] [InlineData(PdfAStandard.A1A)]
[InlineData(PdfAStandard.A2B)] [InlineData(PdfAStandard.A2B)]
[InlineData(PdfAStandard.A2A)] [InlineData(PdfAStandard.A2A)]
[InlineData(PdfAStandard.A3B)]
[InlineData(PdfAStandard.A3A)]
public void CanGeneratePdfAFile(PdfAStandard standard) public void CanGeneratePdfAFile(PdfAStandard standard)
{ {
var builder = new PdfDocumentBuilder var builder = new PdfDocumentBuilder

View File

@@ -24,6 +24,14 @@
/// <summary> /// <summary>
/// Compliance with PDF/A2-A. Level A (accessible) conformance are PDF/A2-B standards in addition to features intended to improve a document's accessibility. /// Compliance with PDF/A2-A. Level A (accessible) conformance are PDF/A2-B standards in addition to features intended to improve a document's accessibility.
/// </summary> /// </summary>
A2A = 4 A2A = 4,
/// <summary>
/// Compliance with PDF/A3-B. Level B (basic) conformance are PDF/A2-B standards in addition to support for embedded files
/// </summary>
A3B = 5,
/// <summary>
/// Compliance with PDF/A3-A. Level A (accessible) conformance are PDF/A3-B standards in addition to features intended to improve a document's accessibility.
/// </summary>
A3A = 6
} }
} }

View File

@@ -640,6 +640,11 @@ namespace UglyToad.PdfPig.Writer
case PdfAStandard.A2A: case PdfAStandard.A2A:
PdfA1ARuleBuilder.Obey(catalogDictionary); PdfA1ARuleBuilder.Obey(catalogDictionary);
break; break;
case PdfAStandard.A3B:
break;
case PdfAStandard.A3A:
PdfA1ARuleBuilder.Obey(catalogDictionary);
break;
} }
} }

View File

@@ -147,6 +147,14 @@ namespace UglyToad.PdfPig.Writer.Xmp
part = 2; part = 2;
conformance = "A"; conformance = "A";
break; break;
case PdfAStandard.A3A:
part = 3;
conformance = "A";
break;
case PdfAStandard.A3B:
part = 3;
conformance = "B";
break;
default: default:
throw new ArgumentOutOfRangeException(nameof(standard), standard, null); throw new ArgumentOutOfRangeException(nameof(standard), standard, null);
} }