Changes Introduced in DotImage 11.1

Jump to: navigation, search

Release Notes

The full official release notes for DotImage can be found below:

Release Notes Page

Individual releases

Initial Release (December 2018) - v11.1.0.0

Support has received many requests to make a more "search friendly" version of the release notes.

Your wish is our command: 11.1 Full Release Notes

Breaking Changes

WebDocumentViewer DocumentSave File Extension Preservation

In all versions before 11.0, the DocumentSave (as well as DocumentStreamWritten and AnnotationStreamWritten) save events have provided the e.FileName as the original file name but with the extension stripped off. This led to a good deal of extra code having to be written to determine the proper file type to add an extension back in

In 11.1, this incorrect behavior is corrected. This will present as a BREAKING CHANGE to users who have WDV save events handled with any custom code that needed to compensate for the missing file extension.

example: Original file opened in WDV was "GettysburgAddress.tif" 11.0 and older behavior: DocumentSave event e.FileName in the handler would receive "GettysburgAddress" for the filename.. same with e.Filename in the AnnotationStreamWritten and DocumentStreamWritten events

in 11.1 and newer the e.FileName will be "GettysburgAddress.tif" so that combining the e.SaveFolder and e.FileName will provide the web relative path to the file without having to guess or append .tif

WebDocumentViewer Resource Changes - v11.1.0.0 and newer

WebDocumentViewer resources - updated jQuery and jQueryUI versions

Old File New File
jquery-1.11.0.min.js jquery-3.3.1.min.js
jquery-ui-1.10.4.min.css jquery-ui-1.12.1.min.js
jquery-ui-1.10.4.min.js jquery-ui-1.12.1.min.css
jquery.easing.1.3.js removed

updates to WebDocViewer\Images

11.0 11.1
images\atala-ui-icons-16.png UPDATED
images\atala-ui-spinner.gif UPDATED
NOT PRESENT atala-ui-dragdropfile.png
NOT PRESENT ui-icons_444444_256x240.png
NOT PRESENT ui-icons_555555_256x240.png
NOT PRESENT ui-icons_777620_256x240.png
NOT PRESENT ui-icons_777777_256x240.png
NOT PRESENT ui-icons_cc0000_256x240.png
NOT PRESENT ui-icons_ffffff_256x240.png
images\ui-bg_flat_0_aaaaaa_40x100.png REMOVED
images\ui-bg_flat_75_ffffff_40x100.png REMOVED
images\ui-bg_glass_55_fbf9ee_1x400.png REMOVED
images\ui-bg_glass_65_ffffff_1x400.png REMOVED
images\ui-bg_glass_75_dadada_1x400.png REMOVED
images\ui-bg_glass_75_e6e6e6_1x400.png REMOVED
images\ui-bg_glass_95_fef1ec_1x400.png REMOVED
images\ui-bg_highlight-soft_75_cccccc_1x100.png REMOVED
images\ui-icons_222222_256x240.png REMOVED
images\ui-icons_2e83ff_256x240.png REMOVED
images\ui-icons_454545_256x240.png REMOVED
images\ui-icons_888888_256x240.png REMOVED
images\ui-icons_cd0a0a_256x240.png REMOVED

This means you will need to update your script references from

    <script src="WebDocViewer/jquery-1.11.0.min.js" type="text/javascript"></script>
    <script src="WebDocViewer/jquery.easing.1.3.js" type="text/javascript"></script>
    <script src="WebDocViewer/jquery-ui-1.10.4.min.js" type="text/javascript"></script>
    <script src="WebDocViewer/raphael-min.js" type="text/javascript"></script>
    <script src="WebDocViewer/clipboard.min.js" type="text/javascript"></script>
    <script src="WebDocViewer/atalaWebDocumentViewer.js" type="text/javascript"></script>

    <link href="WebDocViewer/jquery-ui-1.10.4.min.css" rel="Stylesheet" type="text/css" />
    <link href="WebDocViewer/atalaWebDocumentViewer.css" rel="Stylesheet" type="text/css" />


    <!-- Script Includes for Web Viewing -->
    <script src="WebDocViewer/jquery-3.3.1.min.js" type="text/javascript"></script>
    <script src="WebDocViewer/jquery-ui-1.12.1.min.js" type="text/javascript"></script>
    <script src="WebDocViewer/raphael-min.js" type="text/javascript"></script>
    <script src="WebDocViewer/clipboard.min.js" type="text/javascript"></script>
    <script src="WebDocViewer/atalaWebDocumentViewer.js" type="text/javascript"></script>

    <!-- Style for Web Viewing -->
    <link href="WebDocViewer/jquery-ui-1.12.1.min.css" rel="Stylesheet" type="text/css" />
    <link href="WebDocViewer/atalaWebDocumentViewer.css" rel="Stylesheet" type="text/css" />

NOTE: We've had reports that after upgrading, some toolbar buttons/icons are not behaving as expected. Cached versions of the old images and such. The new WebCapture resources shipped with new icons, so existing demos/apps may need to have their IIS Express cache cleared

SYMPTOM: You've updated a solution that used WDV 11.0 or older to 11.1 and made certain that you removed the old WebDocViewer and WebDocViewer\images folders and replaced them with the new ones and have updated your scripts and css as above... but when you run the solution the toolbar icons are misaligned and/or showing button text incorrectly.


  • Shut down all copies of Visual Studio
  • Run a Visual Studio command prompt
    • Start->All Programs->Visual Studio 2013->Developer Command Prompt for VS2013
cd "C:\Program Files (x86)\IIS Express\"
appcmd.exe list site /xml | appcmd delete site /in
  • This will delete the cached sites
  • Now, re-open the solution, rebuild and run
  • You may still see the cached images.. hold SHIFT and hit F5 to force a refresh
  • The stale icons should update

New Features

WebDocumentViewer / WebDocumentThumbnailer

WebDocumentViewer File Upload

Starting in 11.1 we are proud to provide the much-requested ability to upload files from local machine to server through our WebDocumentViewer.

The File Upload feature can use drag/drop or programmatic calls to initiate.

Enabling/Configuring Upload

You need to add the new upload configuration map to your viewer Config

example allowing uploads to the directory ./upload allowing only .jpg,.raw and tiff files, restricting size to 10MiB, allowing multiple files and enabling drag drop

upload: {
    uploadpath: 'upload',
    allowedfiletypes: '.jpg,.raw,image/tiff',
    allowedmaxfilesize: 10 * 1024 * 1024, // 10MB
    allowmultiplefiles: true,
    allowdragdrop: true

Upload via Drag/Drop

If the allowdragdrop config is true, then users can just drag/drop appropriate files onto the viewer to initiate upload

Programmatic upload

Whether allowdragdrop is true or not upload (if configured) can be initiated programmatically

Call file upload directly using new method :

_viewer.uploadFiles(files, uploadpath, callback);

PLEASE SEE our WebViewingDemo for a fully functional sample solution for the new upload feature

Also, please see Tutorial: Upload Files with Web Document Viewer


 <input type="file" name="fileUpload"/>
 <button type="button" onclick="uploadFile(); return false;">Upload!</button>
function uploadFile() {
    var files = [];

    for (var i = 0; i < document.getElementsByName('fileUpload')[0].files.length; i++) {
    _viewer.uploadFiles(files, guid());
    return false;

File Upload Events

Several events provided:
event, is fired when file is added to the list of files to upload

event, is fired when upload operation is started.

event, is fired when upload operation is finished.

event, is fired when file upload is started.

event, is fired during file upload process. Can be used to track upload progress

event, is fired when file upload has failed

event, is fired when file upload is finished


uploadfinished: function (eventObj) {
    if (confirm('Your files were uploaded. Do you want to view it?')) {

File Upload Error Handling


   None – file is not rejected from upload.
   Size – file size is bigger than allowed.
   Type – file type or extension is not allowed for upload.
   Name – file with the same name is already added to upload queue

WebDocumentViewer Document Saved Event Updates

documentsaved – save operation updated to pass back the file name of the document that was saved. Allows developer to have a reference to the file for subsequent operations

_viewer.bind('documentsaved', function (eventObj) {
    if (eventObj.success) {
        lastSavedFile = eventObj.fileName;
        alert('The file ' + lastSavedFile + ' was saved');

WebDocumentViewer Customize Server Responses

In WebDocumentRequest handler customize responses back to the client via the existing events

Clientside WebDocumentRequestHandler (server side)
documentinfochanged DocumentInfoRequestResponseSend
annotationloaded AnnotationsDataResponseSend
formsloaded FormsDataResponseSend
pagetextloaded PageTextRequestResponseSend
documentsaved DocumentSaveResponseSend

example for documentsaved


public WebDocViewerHandler()
   RegisteredDecoders.Decoders.Add(new PdfDecoder() { Resolution = 200 });
   this.DocumentSaveResponseSend += MyWdv_DocumentSaveResponseSending;

private void MyWdv_DocumentSaveResponseSending(object sender, ResponseSendEventArgs e)
    e.CustomResponseData.Add("MyMessage", "Hello World!");


Clientside response example for the previous

_viewer.bind('documentsaved', function (eventObj) {
 if (eventObj.success) {
  myCustomMessage = eventObj.customData.MyMessage;
  alert('My custom message to you is ' + myCustomMessage);

Improved Text Search - Search on Page

Ability to limit text searches to specific pages

For reference, prior to 11.1, the search method is

search(text, startPage, callback)

(search text empty clears results)

New Method is

searchOnPages(text, startPage, endPage, activepage, callback)

set ActivePate to the startPage (it's there for backward compatibility)

Example form

<form name="searchform" id="searchform">
    Search String -  <input type="text" name = "searchstring" id="searchstring"  />
    Starting Page - <input type="text" size="4" name = "startingpage" id="startingpage" value="0" />
    Ending Page <input type="text" size="4" name = "endingpage" id="endingpage" value="100" />
    <button type="button" onclick="search(); return false'">Search</button>

<script type="text/javascript" language="javascript">
function search() {
 var searchstring = document.getElementById('searchstring').value;
 var startingpage = document.getElementById('startingpage').value;
 var endingpage = document.getElementById('endingpage').value;
 _viewer.text.searchOnPages(searchstring, startingpage,endingpage,startingpage, function (it, match) {
     if (it.isValid()) {
         _viewer.text.selectPageText(, match.region, match.line, match.word);

WebDocumentViewer Error Handling for Missing Dependencies

Console messages are now provided if there are missing dependencies or dependencies with incorrect versions

for example, commenting out this reference

<!-- <script src="WebDocViewer/jquery-ui-1.12.1.min.js" type="text/javascript"></script> -->

Would show an error in the console of

The dependency verification for jQuery UI has failed. Dependency is not loaded or not found. The minimal required version is 1.12.1

WebDocumentViewer New annotations.scrollTo

Allows user to quickly scroll through all the annotations in a document

function scrollTo(annotation)

where annotation is an annotation object from the document

usage overview

  1. Iterate over the pages of a document
  2. Populate an array of annotations on a page
  3. var annos = viewer.getAnnotationsFromPage(I);
  4. Scroll to the annotations viewer.annotations.scrollTo(annos[j]);

WebDocumentViewer Preserve File Extension

See note in Breaking Changes above as well

Prior to 11.1, the server-side DocumentSave event (DocumentSaveEventArgs) did not include the file extension

in 11.1, the file extension is included in the file name property

NOTE: if you have created your own workaround to persist or add file extension prior to 11.1, you may need to disable/back out of it for 11.1 and test thoroughly

WebDocumentViewer Modifying Default Saving Behavior

Behavior in 11.0

Behavior in 11.1

11.1 has a new flag that can control the new behavior - ReplaceFileExtensionsOnSave

ReplaceFileExtension.None Preserves the original extension or lack thereof, in all cases. This applies even if there is a safefileformat or saveformat value

if no savefileformat / saveformat is set

  • files without extensions have extension added based on image type
  • all others preserve original extension

if safefileformat / saveformat is set

  • Files with no extension are saved with extension matching the savefileformat value
  • other files preserve their original extension though they are still saved as the file type specified in savefileformat

if no savefileformat / saveformat is set

  • saving a file that has no extension appends an extension based on the image type
  • saving a file with an extension preserves the original extension

if a savefileformat / saveformat is set

  • file is saved with an extension matching the savefileformat value


MacOS Scanning for WingScan

Instead of a local windows service, MacOS scanning will be installed via a .pkg


   Supported OS Versions
       10.12 (Sierra)
       10.13 (High Sierra)
       10.14 (Mojave)
   The MacOS module will be installed by Kofax.WebCapture.macOS.pkg
   One single license works for Windows and Mac (no clientside licenseing needed)
   JavaScript API remains unchanged
   EVRS (with VRS addon license for WingScan) available
   UI is similar.. a small Kofax icon will sit in the status menu (MacOS) when active instead of system tray (windows)

MacOS: Scanning

MacOS scanning will use Apple Capture instead of TWAIN

There are some limitations because of this:

   No Scanner UI will show (no Config dialog of progress indicator)
   maxPages will not stop the page feed
   Imprinters are not supported

List of supported Scanners:

MacOS: Barcode Reading

We are using the AtalaBar engine instead of the Honeywell engine (used in the windows version)

This means the MacOS version has no support for the following in our MacOS scanning

   Micro Pdf417
   Micro QR

Logging and Troubleshooting

Use the built in console


Log files will bewritten to


Imprinting Support (windows WingScan)

WingScan in 11.1 adds support for Imprinters on scanners which support it.

Due to variations in TWAIN scanner driver support for Imprinting, there may be variations

Added imprinter settings

  • Rotation (deg)
  • Vert offset
  • Vert offset units
  • Font size (bit flags)
    • Normal 1
    • Bold 2
    • Italic 4
    • Large 8
    • Small 16

Font sizes have lots of variation - some scanners honor Bold, others consider bold to be a combo of Normal + large and extra bolt to be bold + large

PDF/A support

DotImage 11.1 added a lot of additional PDFA support

PDF/A in PdfDocument

For PdfDocument class, we added support for handling PDF/A documents. NOTE that you can not use PdfDocument to convert non-PDF/A documents to PDF/A.. but what this does for you is allows you to safely open/save PDF/A documents without stripping their PDF/A compliance

Added support for the Following PDF/A Specs

  • PDf/A-1 (a, b)
  • PDF/A-2 (a, b, u)
  • PDF/A-3 (a, b, u) without portfolio

Criteria needed to get PDF/A documents:

  • All source documents need to be PDF/A (this does NOT convert non-PDF/A to PDF/A
  • Color Profiles should have the same color spaces for all documents

This means you can not combine non-PDF/A documents with PDF/A documents and get a PDF/A out.. and all source PDF/A documents being combined must be of matching color profile PdfDocument Save Behavior

PdfASavigBehavior values:

  • PreserveOriginalPdfType (default)
  • SavePdfA
  • SavePdf

Save() method behavior

PdfASavingBehavior Regular PDFs Mixed PDF/A Documents
PreserveOriginalPdfType Regular PDF Regular PDF PDF/A or PdfAException
SavePdfA PdfAException PdfAException PDF/A or PdfAException
SavePdf Regular PDF Regular PDF Regular PDF

Combining Multiple Files

PDF/A Compatibility Verification

IsPdfACompatible property

  • verifies metadata
  • verifies main color profiles
  • Does not verify document for PDF/A compliance
var firstDoc = new PdfDocument("first.pdf");
var secondDoc = new PdfDocument("second.pdf");
var options = new PdfSaveOptions
    PdfASavingBehavior = firstDoc.IsPdfACompatible()
                    ? PdfASavingBehavior.SavePdfA
                    : PdfASavingBehavior.SavePdf
firstDoc.Save("output.pdf", options);

PDF/A in PdfGeneratedDocument

PdfArenderer Produces PDF/A

Supports PDF/A-1b only

using (var file = File.OpenRead("doc.pdf"))
using (var document = new PdfGeneratedDocument(file))
using (var cmykProfile = new PdfIccColorSpaceResource(File.OpenRead("CMYK.icm"), true))
using (var result = File.Create("result.pdf"))
   PdfARenderer renderer = new PdfARenderer(result)
      CmykColorSpace = cmykProfile,
      ImageExtractor = new AtalaImageExtractor(),
      IgnoreUnsupportedAnnotsAndActions = true,
      ConvertIncompatiblePagesToImages = true
   renderer.StreamlessFontFound += (o, arg) => arg.AlternativeFontPath = GetTTFont(arg.FontResource);

Note that GetTTFont is not part of our SDK - you would need to provide a method to pass in the font resources and use the info to return the path to the requested font

Here is a rough example (provided as-is) it is your responsibility to make your own GetTTFont that meets your needs

public string GetTTFont(FontEventArgs args)
    const string localFontFolder = "%folder with fonts%";

    // means that internal mechanism found alternate font in system fonts.
    if (args.AlternativeFontPath != null)
        return args.AlternativeFontPath;

    // replace specific font
    if (args.FontResource.FontFamily == "MinionPro-Regular")
        return Path.Combine(localFontFolder, "arial.ttf");

    // try to find font in the local font folder
    var fontPath = Path.Combine(localFontFolder, $"{args.FontResource.FontFamily}.ttf");
    if (File.Exists(fontPath))
        return fontPath;
    // use default font
    return Path.Combine(localFontFolder, "arial.ttf");
    // or throw exception
    // throw new Exception("font does not found");

PdfARenderer Configuration

PdfARenderer Properties

   ConvertIncompatiblePagesToImages to convert incompatible pages to images
   Color spaces related properties
   ImageExtractor for converting PDF pages to images
           Defined in Atalasoft.dotImage.PdfDoc.Bridge.dll
   StreamlessFontFound event

has ConvertIncompatiblePatesToImages as part of the PdfARenderer

PdfARenderer renderer = new PdfARenderer(result)
    RgbColorspage = rgbProfile,
    CmykCOlorSpace = ckykProfile,
    ImageExtractor = new AtalaImageExtractor(),
    IgnoreUnsupportedAnnotsAndActions = true,
    ConvertIncompatiblePaesToImages = true

AtalaImageExtractor is in the Atalasoft.dotImage.PdfDocBridge.dll

If ignore unsupported is set to false then it will throw exception on fail

StreamlessFontFound event

  • All fonts used in PDF must be embedded in PDF/A
  • if it is unable to find font it ires StreamlessFontFound event where you can provide

PDF/A in PdfEncoder

Added PDF/a-2b support

DocumentType can now be set to PdfDocumentType.PdfA2b

PDFA/2b allows the user of UseAdvancteedImageCompression = true

this allows Jpeg2000 / Jbig2 compression to be used in PdfEncoder and produce PDF/A-2b compatible output

using (FileSystemImageSource fs = new FileSystemImageSource(imagePath, true))
   PdfEncoder encoder = new PdfEncoder
      DocumentType = PdfDocumentType.PdfA2b,
      UseAdvancedImageCompression = true
   using (var outfs = File.Open("output.pdf", FileMode.Create, FileAccess.ReadWrite))
      encoder.Save(outfs, fs, null);

PDF/A in PdfTranslator

Added PDF/A-2b support

Can be enabled with PdfDocumentType.PdfA2b

Compression selector can support Jpeg2k and Jbig2

this allows Jpeg2000 / Jbig2 compression to be used in PdfTranslator and produce PDF/A-2b compatible output

PdfTranslator trans = new PdfTranslator(PdfDocumentType.PdfA2b);
trans.CompressionSelector =
                new PdfCompressionSelector(format => PdfImageCompressionType.Jpeg2000);
var src = new FileSystemImageSource(imagePath, true);
using (var stream = File.Create("outputTransl.pdf"))
   ocrEngine.Translate(src, "application/pdf", stream);

XRef Streams Compression in PdfDocument and PdfGeneratedDocument

Applicable to following objects

  • fonts
  • images
  • colorspaces
  • UseCompressedObjectStreams

Set UsecompressedObjectStreams = true

NOTE: compression will make saves take longer

PdfEncoder example:

PdfEncoder encoder = new PdfEncoder()
   UseCompressedObjectStreams = true

PdfTranslator Example:

PdfTranslator trans = new PdfTranslator()
   UseCompressedObjectStreams = true

PdfAnnotations Appearance in PdfDecoder

Our old PdfDecoder (pre-11.0) could not render several native type PDF annotations when PdfAnnotionRendering was enabled. Our 11.1 PdfIum engine can render these correctly (as part of the rasterized image.. this is NOT full support for these annotation types in our Annotation tools)

Applicable for PDF documents without appearance

  • Polygons and polylines
  • "Cloud" annotations
  • Underline and Strikethrough
  • Textbox
  • Callout
  • Measure lines

OCR Multilanguage recognition support

We have added support for multiple languages to our OCR engine classes for those engines which can support it

Engines that currently support Multiple Languages (at once)

Abbyy and Tesseract3

The Atalasoft OcrEngine class added the SupportedMultiCultureResognition property. Read this to check if your specific engine supports multiple culture recognition

If it's supported in your engine, then instead of setting

engine.RecognitionCulture = SomeRecognitionCulture;

you can pass in a List<RecognitionCulture> to

engine.RecognitionCulturesList = listOfCultures;

This will instruct the engine to be able to handle documents with mixed multiple languages such as documents continaing both English and Hebrew or English and Chinese, etc...

MobileImage Demos/Samples

Android Samples have been updated

  • Capture Demo
  • Barcode Demo

Sources are on Github

Apps are available in Google Play

iOS Samples updated

  • now use Swift 4

External Libraries update


  • Foxit (in
  • Tesseract2
  • RecoStar


  • PdfIum
  • EVRS
  • Tesseract (v3.05.02)
  • Perceptive Document Filters
  • Luratech codecs (staring in
    • Jbig2
    • Jpeg2000

SDK Updates


  • Silverlight
  • SharePoint


  • IE < 11
  • Visual Studio 2008

Original Source KB Article

Q10471 - INFO: Changes Introduced in DotImage 11.1