Templater change log

2024-09-25 v8.1.0

Templater Editor improvements

  • Performance improvements in Excel. Improve handling of cells and interop for some performance improvements
  • Report empty rows in Excel as warning. When doing analysis suggest to remove empty rows after the tags as that speeds up the processing
  • Detect tags in fields in Word. This was supported by library, but not previously detected by Templater Editor
  • Warnings when images are used in fields. While image will be added after the field, its still not where such tags should be used
  • Fix missing icons for some types (image, xml and svg)

Improvements

  • Excel Data Validation support. Templater will now recognize and adjust Data validations when resized or moved around
  • HTML file will now try to be placed at tag location instead in the next paragraph when possible in Word. This significanly improves embedding of HTML as HTML can be inserted into table cells and other similar locations
  • PowerPoint row/column identity support. If row or column identity is assigned in PowerPoint, Templater will now adjust it accordingly, so that editing of cells after processing works as expected
  • Excel drawing stretching. If drawing is placed within a merge cell which is extended, drawing will be adjusted too. If this is not desirable behavior, previous behavior can be obtained by checking the Lock aspect ratio checkbox on the shape properties

Bugfixes

  • Multiline replacement will now preserve order of tags after the replaced tag. When text with newlines (\n) is used, a special replacement is performed which was not behaving as expected. Now tags which are pushed down will still work as expected
  • Cope with images at unsupported location. Previously when image replacement was attempted when its not supported, an error would occurr. Now image will be added after the tag location whenever possible
  • Fix bug with XML duplication when part of XML being duplicated did not contain tags. It was not correctly duplicated until some tag was added into the element
  • Fix bug with XML removal when part of XML being removed did not contain tags. It would throw error instead of removing that part of the XML
  • Excel formula array duplication fix. In some cases when cell would contain array during duplication it would not adjust XML accordingly which would result in “corrupted document”

2024-01-24 v8.0.0

Templater Editor improvements

  • New installer. To resolve some installation problems, host installation dependencies Microsoft no longer provides

Breaking changes

  • (.NET standard only) Low level plugins are disabled by default. To keep up with recent .NET deprecation of cross platform Image support, disable Image detection by default on Templater version for .NET standard. On legacy .NET this plugins are still activated by default. To get previous behavior .BuiltInLowLevelPlugins(true) must be set-up during factory configuration
  • (.NET only) Deprecated IDocumentFactory.Open(Stream,string) API was removed. Use Open(Stream,string,Stream) to retain previous behavior (and pass same instance into input and output stream arguments
  • Deprecated navigateSeparator(char) API was removed. Use navigateSeparator(char, null) to get the previous behavior

API changes

  • XmlCombine API is extended with two new arguments. Old API is retained for compatibility purposes, but will be removed in future versions. New XML combine introduces additional arguments to support many more low level XML cases
  • Handled now has new enumeration: CurrentContext. This is required to support improved resize(tag, 0) behavior as when returned, tags in same context are also handled by the plugin

Spreadsheet improvements

  • Controls are now recognized and supported. Duplication, population and other Templater features work on them now
  • Native boolean type. Templater will now mark boolean value with special flag so Excel treats it as boolean value. This allow its usage in Checkbox controls and similar cases
  • XML replace now works in Spreadsheet the same way as in other formats (docx and pptx). If there is other text within the cell, this text will no longer be lost on tag replacement
  • Correct shape numbering. When there are many shapes Templater will now follow the correct numbering of such shapes to match expected Excel format. Previously, with many shapes or during sheet duplication, shape numbers would remain the same and Excel might not parse the document correctly

Improvements and bugfixes

  • XML and Text format context improvement with collections. If same tag is repeated multiple times and is part of collection elements, now it will be considered during analysis. Previously only the first tag was considered and expected behavior was possible with additional tags, often with :hide metadata to increase the context range across all relevant tags
  • Dictionary navigation fix. When navigation was used multiple times on dictionary types, Templater would incorrectly process first navigation multiple times, instead of respect each navigation separatelly
  • (.NET only) Slide removal fix. When slide was deleted, Templater would sometime leave the relationship to non-existing slide which would result in corrupted document
  • Improved context behavior with removal. Templater will now be smarter about cases when resize(tag, 0) is called to check if some tags should be skipped. This makes expected behavior work out-of-the-box in more cases, as in some edge cases document layout would result in wrong tag (out of order) being processed
  • Hyperlink detection in Word. Templater will now detect hyperlinks in simple fields. Some editors define hyperlinks via simple fields, which Templater will now analyze and support
  • PowerPoint XML replace improvements. Templater will now allow replacing XML near the body element, which allows replacement of the entire slide. Previously only higher level components were allowed

2023-04-07 v7.3.0

Templater Editor improvements

  • New code signing certificate
  • Support for nested tables. Tags will now be detected in nested tables too
  • Issue listing improvement. Only list repeated tags which exist multiple times. Dont repeat malformed tag

XML improvements

  • New XML combine plugin. To support more advanced scenarios for XML merging/combining new user defined plugins can be registered for fine grained control over OOXML in Office formats
  • merge-xml now supports merging of XML with multiple child elements of a same name
  • XML type can now be used image attributes. Combined with new XML plugin this can be leveraged to inspect current XML of an image and adjust it to a new one
  • provided XML will no longer be changed
  • (Java only) Cope with nested namespaces provided directly on the child XML node during XML operations
  • (Java only) Cope with rare cases of out of order namespace definition

Improvements and bugfixes

  • Improved Presentation tag sharing. Repeated tags across slides should now behave same as Spreadsheets/Documents
  • Improved Schema analysis. Expand more objects of unknown/runtime types
  • Alternative Document hyperlink support. Detect tags in non standard hyperlink format used by non MS Office tools
  • Cope with ResultSet/IDataReader ending with a DOT (.). Templater would reorder tags and set values in wrong tags
  • (.NET standard 2.0 only) Fix Templater Editor integration. Since v7.1 Templater Editor did not work as expected in some cases
  • Conditional formatting performance improvements. Only formulas referencing cells, tables or named ranges will be considered for per row duplication/adjustment

2023-01-16 v7.2.1

Templater Editor improvements

  • Improved debugger search and action listing

Improvements and bugfixes

  • Word resize improvement. Start of the document will be considered as section range. Previously entire document would be considered for resize instead of only duplicated regions
  • Tag sharing regression fix. In v7.1 bug with tags sharing was introduced when tags are removed. Now Templater will process the correct tags and skip over the removed ones
  • Excel rows without cells improvement. In rare cases Templater would previously fail during duplication of rows which don’t have any cell

2022-11-28 v7.2.0

Templater Editor improvements

  • ODBC connection management. SQL now comes with connection management for easy selection of existing connections

Improvements and bugfixes

  • PowerPoint relationship improvements. Cope with non MS documents (such as Google docs) saving relationship in a non-standardized way
  • Schema analysis improvements. Deeper analysis of dictionary objects. Better analysis of iterator collections (without consuming them)
  • Performance and memory improvements. Templater will now use less memory for large collections which perform streaming
  • Fix inline string support. Correctly manage tags defined in a cell with type=inlineStr which stores text values directly in the cell instead of separate shared strings part
  • (JVM only) Improved support for custom namespaces. Some custom libraries use non-standard namespace when saving XML. This was already working for .NET
  • Cancellation improvements for text format. Check for interrupts much more often as it can consume significant amount of memory very fast
  • (JVM only) Fix bug with multiline strings in PowerPoint. Only last part was displayed
  • (.NET only) Improve reuse of images. Try to reuse streams passed for images. If streem is seekable read it from the start if its at the end
  • Excel support for hyperlinks in merge cells. Templater did not recognize such hyperlinks previously

2022-07-12 v7.1.0

Templater Editor improvements

  • Nested collection detection. Templater Editor with now report errors and warnings for collections nested within collections. If there is more then one such collections this will be reported as error, while single collection will be reported as warning

Improvements and bugfixes

  • New Excel configuration API. Excel can now be configured to ignore numbers as text warnings
  • Major Word performance improvement with tag sharing. Templater will now use optimized method of replacement when tag sharing is involved
  • Powerpoint support non relaxed relationship information, which is the way some alternative applications (non MS) are saving notes information
  • Support for expressions in conditional formatting. They will now be recognized and adjusted like other formulas
  • Improved support for column limit in Excel. XFD will now be respected as maximum limit
  • Tag order with sharing in Powerpoint bugfix. In some cases tags were not ordered correctly which resulted in unexpected replacement/output
  • Cope with nulls for padLeft/padRight. Treat them as empty strings
  • Horizontal resize improvements. Calculated formulas will now be copied and adjusted. Header does not need to be at the last column in the table anymore. Duplicate column check after such resize was improved
  • Word binding support for built-in files. Templater will now recognize bound tags to author name and similar information in Word core.xml file
  • Excel column width adjustment on horizontal resize. In certain cases, columns were not adjusted when right of the horizontal resize tag. Now they should be adjusted/moved to the right
  • Excel formula adjustment in more cases. Templater was not adjusting formulas if there was nothing bellow resized range

2022-04-26 v7.0.0

Templater Editor improvements

  • Custom plugins support. Customers can now setup Templater Editor with their own plugins. For this to work, customers must provide Templater support (info@templater.info) with link to zip location of the configuration dll which will be used to initialize Templater. Setup looks almost the same as ordinary Templater configuration
  • Debugging will now list all resize operations, even removals (resize = 0)
  • Improved support for SSL connections. Templater requires valid certificate to establish SSL connection (when using remote data inputs) but will now work with modern protocols across all features (http request, Javascript evaluation, plugin download)
  • Show tooltips in Windows 10+ in all cases. When inspecting issues, tooltips were not behaving as expected on all Windows versions
  • Tag detection in Word merge cells. This was not working as expected
  • Allow entry name for tag prefix. New toggle is available on entries in Run Templater
  • Support for Object.assign in Javascript
  • Improved analysis of collections. Detect different collections in same table in more scenarios

Major changes

  • Templater v7 requires a new license key. License key from prior versions will not work on v7 of the Templater.
  • XML handling has been fully refactored and now Templater uses less memory and works faster
  • Memory will be flushed to zip when possible for large XML files. This results in less memory usage when processing large Excel/Word files (100MB+ xml files)
  • Native support for XML. XML is now a recognized extension which will use native XML processing. When unlicensed version of the Templater is used a comment will be added at the top of the document
  • Streaming support for XML. XML can be flushed during processing in same manner as CSV files, which allows for streaming with constant memory usage

Breaking change (Java only)

  • Removed I prefix from all interfaces to match standard Java naming. This will require code adjustments to compile again, eg ITemplater -> Templater, ITemplateDocument -> TemplateDocument
  • hr.ngs.templater is now sealed. If you used this namespace for some plugins, move them to a different namespace, as there should be no need to use this namespace

Improvements and bugfixes

  • Various performance optimizations. Templater will now run faster in several scenarios (tag removal in Word, tag sharing, general processing, …)
  • Special print named range behavior in Excel. If named range is hidden, it will not influence Templater the same way as ordinary named range. Print named range (_xmlns.Print) will now behave the same. This changes the behavior of Templater using this outer named range as range to resize, but rather resizes best context on other surrounding elements
  • Invalid XML detection in Excel. Previously invalid XML detection was added to Templater, but it only worked as expected in Word and PowerPoint. Now it will behave the same in Excel
  • Merge cell usage changes. Merge cells will now influence Templater in more cases. Previously Templater would mostly ignore them in Word and PowerPoint. Now merge cells will be stretched the same across all Office formats. If tag context spans across merge cell, it will be extended to include merge cell for resize operations
  • (.NET only) Keep whitespace in XML. This fixes the problem of tabs in PowerPoint which were stripped on save
  • Tab support in Word. Special character will now be inserted in Word \t character, similarly how special character is inserted for \n characters
  • OOXML files casing bugfix. Files inside zip will be compared in case insensitive way which resolves the problem of Templater using same name as already existing image in the document
  • Navigation plugin support on DataTable, ResultSet and IDataReader types. Similarly to objects and dictionaries, plugins are now supported on “table” types
  • Context improvements with tag sharing and removal. In some cases when tags are removed from current context, Templater would use tag from the next context for current resize operation. This would result in an unexpected behavior with values not ending up on correct location. Templater will now perform additional checks and cope with such scenario
  • Improve replace behavior when handlers are used. Make Templater behave the same for root tags and tags inside collections. Previously when collapse handler was used on the first tag, second tag would not get processed. Now it too will get processed, like it was getting processed inside collections
  • Templater Editor integration will now save additional parameters (navigation settings and tag regexes) so that Templater Editor is aware of the expected behavior

XML type improvements in OOXML

  • XML metadata options via attributes. Instead of specifying remove-old-xml, merge-xml and replace-xml via metadata in tags, this can now be passed as attributes in XML via templater-xml=value attribute. This attribute will be removed, not to corrupt OOXML file
  • Specifying cell style in Excel via another cell. While background cannot be set by providing XML, style can be changed. If template has several cells predefined with expected styles, they can be referenced via templater-style-cell=CELL in which case Templater will lookup specified CELL and copy its style to the current cell
  • Specifying row style in Excel via another row. To copy style from another row via XML, provided XML can have attribute templater-row-style=index in which case Templater will lookup specified row and copy its style to the current row
  • Excel row attributes can be set via templater XML attributes: templater-row-height, templater-row-custom-height, templater-row-collapsed, templater-row-custom-format, templater-row-hidden, templater-row-thick-bottom and templater-row-thick-top
  • Embedded XML is supported the same way as embedded TXT and embedded DOCX
  • Improve merge-xml behavior to also merge text, not just nodes

2021-12-28 v6.2.0

Templater Editor improvements

  • Show details of input values in debug log. Specific types will show specialized windows/actions (image will open window showing the image, URL/File will show the link for opening it, Dynamic Resize input will show the values inside the grid, multilines and long strings will be shown inside popup window)
  • Allow changing aliases and configuration with tag management disabled. Tag management should mostly mean that new tags can’t be added, or old ones removed
  • Tag detection improvement inside Word Content control

Breaking change

  • Navigation expression is now configured with two parameters. Default behavior for detecting end of expression has changed (previously it would end with a navigation character - DOT or specified navigation separator; now it will require parenthesis before). Previous behavior can be obtained by providing custom function for finding navigation metadata ending. Old method is available for backward compatibility, but the behavior is changed
  • (Java only) Configuration API renames to make it more Java standardized (IFormatter is now Formatter, etc..). Old signatures are available for backward compatibility with @Deprecated annotation, but will be removed in the future.

Improvements and bugfixes

  • (Java only) Java 17 support improvements. Reflection will now prefer public signatures when possible. Non public will still be selected if typeVisibility(false) is not specified
  • UUID/Guid will now be recognized as “primitive” type during schema analysis. This will prevent listing of its methods inside Templater Editor
  • Encode filename inside log during debugging. Only filename will be saved, without path
  • (.NET only) Fix saving images in debug log when image content was not a MemoryStream
  • Multi-range chart support. Previously Templater only supported a single range inside chart region definition. Now it will cope (in many cases) with multiple ranges
  • Detection of shape links to cells. Templater will now recognize them and ignore them, since they are populated based on the value of the linked cell. This will fix wrong context detection which was considering such tags for resize operations
  • SOLO license check. When license file was referenced, cope with BOM issues inside file which was preventing correct license check on v6 (specifying license information directly was working correctly)
  • (Java only) XML sorting fix. Fix some internal sorting operations to be stable and thus avoid the: Comparison method violates its general contract!

2021-09-09 v6.1.0

Templater Editor improvements

  • Save analysis result into XML. This can be used to programatically check if document was validated and how many issues were in the document
  • Embedded CSV management (allow importing/changing/removing embedded CSV files)
  • Save Templater Editor version into XML
  • Minor bugfixes

Word improvements

  • Support for AltChunk. This allows detection of tags in embedded documents (txt, html, xml, docx and docm). Embedded documents work transparently with context detection, so all features will continue to work as expected
  • FileInfo (.NET) and File (JVM) support. They will be added as AltChunk (embedded into the zip file). This allows easy HTML import or nesting multiple documents within a parent Word document
  • (.NET only) Embedded documents will work even on new .NET due to custom package management implementation. System.IO.Packaging on new .NET versions has various issues
  • Recognize Repeating Section Content Control as resizable region (in similar manner as sections). Previously Templater only allowed removal of content controls, but now it will also allow resize on Repeating Sections (Repeating Section Content Control does not exist on old Word versions)
  • Support for list-alike Content Controls (DropDown and ComboBox). They are recognized as resiable objects
  • Performance optimizations on tag removal (during resize(tags, 0) operation)

Chart improvements

  • Microsoft specific charts will now be recognized and managed (histogram, sunburst, …)
  • Dynamic resize and :horizontal-resize support for chart management (this allows charts with dynamic number of columns/series)

Excel improvements

  • Improved Dynamic resize behavior inside table/named range. Templater will respect tag position and will adjust table/named range accordingly (both horizontally and vertically)
  • Cope with “non-standard” shapes in Excel. Templater will now work in cases when shapes are not saved in expected order
  • Bugfix with formula detection across different sheets. When referencing later sheet Templater would sometimes parse formula incorrectly
  • Improved ignoreErrors configuration behavior. Templater was importing this configuration into Excel files on “invalid” locations. Now they will be added in the expected location
  • Dynamic resize will respect fixed both vertically and horizontally. Previously it was respected only vertically. If previous behavior is required, whole-column can be used which will instruct Templater to still do push to the right before cloning region horizontally

Other improvements and bugfixes

  • Configuration for class visibility consideration. Currently Templater will scan (and try to use) public properties even on non public classes (when passed into processing or referenced through relationships). This raises warning on new Java versions due to planned restrictions in reflection behavior on future Java version. It also introduces performance overhead for Templater processing. For now the configuration defaults to allowing non public class usage, but this might be changed in the future
  • Bugfix for navigation plugin on dictionaries/maps. Previously only 1 metadata could be used, now they can be chained. This already worked as expected when processing objects
  • Allow blacklisting on primitive types (string, DateTime, number, etc…)
  • (JVM only) Java beans support on primitive types
  • Improved :unprocessed behavior during dictionary processing. When tags are shared, only tags from the same context will be removed. This will reduce problems when tags from different context were replaced

2021-08-03 v6.0.0

Templater Editor improvements

  • Configuration options (custom regex, navigation, separator char,…)
  • Recently used file list (per product) for easier selection of file
  • Tooltips for issues are now displayed in multiline fashion
  • Allow double-clicking on tags for easier pasting - will position it to next cell when inside a table or spreadsheet
  • New suggestions and warnings (invalid collapse, tag sharing, collections across sheets, various others…)
  • Support for Length member on direct JSON import
  • Support for large JSON drag/drop. Such JSON will not be displayed in the preview text box, which supports up to 32k characters
  • Tags will be sorted alphabetically for easier navigation
  • When specifying password for entry, allow show/hide on password
  • Allow drag/drop JSON directly on tag management window
  • Various performance optimizations
  • Various other minor improvements and bugfixes

Major breaking changes

  • Minimal Java version is now Java 8. Previously it was Java 6. Scala 2.11 is no longer supported
  • Java version now supports try-with-resource pattern and thus replaces flush() method with close(). This brings it on the same level as .NET version
  • CancellationToken can now be passed into processing. This allows processing cancellation (e.g. in case of too long processing or resource constraints)
  • .NET factory.Open API now matches Java version with argument order (input stream, extension, output stream + additional new cancellation token)
  • Old Open methods are marked as obsolete and available for easier conversion purposes. They will be removed in next major version
  • Java replaces cancellation pattern from Thread.interrupt() to CancellationToken. There is a forThread(Thread) method on CancellationToken to replicate previous behavior. In case of cancellation java.util.concurrent.CancellationException will be thrown instead of previous InterruptedException
  • SOLO license from previous versions will not work on this version. Reporting and Enterprise license will continue to work without any changes

Major spreadsheet performance and memory improvements

  • Templater can now create much larger spreadsheet documents due to various memory optimizations
  • Processing complex spreadsheets is now significantly faster, due to major refactoring

Bugfixes and improvements

  • Spreadsheet configuration options. Templater can now restrict how many new sheets can be created during processing and supports ignoring warning for inconsistent formulas. This can be accessed through ConfigureSpreadsheet() options in configuration builder
  • Support for multiple tags in spreadsheet hyperlinks
  • List detection changes in presentations. Templater will now consider element as part of a list more often. This will result in list resize instead of whole slide resize
  • Context detection improvements. Some edge cases with tags not part of a collection, but resized with the whole document will not be replaced correctly
  • Preformance improvements with tag sharing
  • Memory and performance improvements when saving OOXML files
  • Improved schema type detection. List more tags not used as entries for reference processing
  • (.NET only) Support for IEnumerator type as streaming collection
  • Bugfix with Word table columns with when performing Dynamic Resize
  • (JVM only) Support for Optional types. Support for common java.time types
  • Bugfix for Spreadsheet chart cloning. When non standard (Microsoft specific) charts were duplicated, not all information was retained and on Java it could sometimes result in a corrupted document.
  • Early invalid XML detection. Previously Templater would save all characters into XML, unless they were “fixed” with low-level plugin. Now an exception will be thrown on such inputs.

2021-03-01 v5.2.0

Templater Editor improvements

  • Run Templater action now supports custom entries
  • New entry type: Javascript with support for XMLHttpRequests
  • Entries can be saved along the document and password protected

Digital signature

  • Documents/presentations/spreadsheets can now be digitally signed via certificate and a private key
  • Builder API has new Sign(certificate) method which will apply digital signature at the end of processing
  • To avoid signature invalidation, Excel will be put into Manual formula recalculation mode, which will prevent formula updates

Bugfixes and improvement

  • Schema analysis improvements. More types will be analyzed even if they were not used in processing. This will resolve problem of some tags missing
  • Schema collection analysis improvements. Use first element of a collection for better tag detection
  • Better formula parsing exception. Templater does not support formulas which reference other documents, in which case parsing will fail. Now cell and sheet will be mentioned in the error message
  • Shared formula fixes. Templater often left shared formulas as-is, which caused problems on duplication, as the formulas were not modified in the expected manner on resize and horizontal resize. Now all shared formulas will be converted into regulard formulas and thus formula rewrite will behave as expected
  • Word tag binding improvement. If Word binding is used with tag in incorrect way, avoid Exception during processing, but rather just replace tag with the provided value

2020-12-21 v5.1.1

Debugger integration bugfixes

  • Recorded actions were not correct for embedded files (CSV and charts). Now only relevant actions will be listed
  • (JVM only) Schema and log information would not be saved correctly sometimes.

2020-12-16 v5.1.0

Debugger integration with Templater Editor

  • Templater can now log all actions which can be replayed in the Templater Editor. This can be used for learning, to better understanding what is going on, or for debugging purposes when some plugin is misbehaving.
  • Debugging can be enabled via debugLog(capture) in the IEditorConfigurationBuilder
  • Templater Editor can enable debugging directly from the UI before running Templater

Low-Level API improvements and breaking changes

  • Handler API now returns an enum instead of boolean flag. This allows for more fine grained behavior and some new use-cases out-of-the-box. Previous values are mapped as: false -> Nothing, true -> NestedTags
  • ThisTag return value can be used to indicate processing of only relevant tag, but let Templater process nested tags, which can be useful for resizing/collapsing.
  • WholeObject return value can be used to short circuit further processing of this object, through indicating that all tags from this object have been manually handled

Bugfixes and improvement

  • (.NET only) C# spreadsheet bugfix with table pushdown. Table would get corrupted in some scenarios when duplication and pushdown was applied to the same table.
  • Word table nesting improvements. Templater did not behave correctly when there was multiple nested tables on different rows which should be handled in a single resize operation.
  • Empty collection processing change. Try to process collection level tags for empty collections. This is not fully consistent as when collection is non-empty tag could be used for different purpose, but its expected behavior.
  • Excel sheet tag copying improvement. Improve handling of same tags on different sheets which were not shared. They should be initially setup the same way as if they were shared.
  • TableOfContent can now be removed. While Templater still takes special care of TOC Word field, it can now be removed when part of section which is removed.
  • Extra whitespace bugfix. Whitespace fix introduced in 2.9.3 was reverted as it was creating extra whitespace. Old Word versions do not display whitespaces as expected after unicode characters, while new Word versions behave correctly.

2020-10-27 v5.0.1

Templater Editor integration bugfixes

  • Keep name editor interface in JVM. Previously name was obfuscated.
  • During schema embeding in .NET for Word, read stream correctly to avoid exception during file loading

Bugfixes and improvement

  • Improved support for Content Controls. Nested content controls are supported now
  • Full row/column named range improvements. Templater will take special care of full row named range during pushdown
  • Performance improvements for formula duplication. In special cases with many cells, formulas will now be duplicated faster
  • Bookmark improvements. Respect out-of-order bookmarks

2020-10-22 v5.0.0

Templater Editor improvements

  • PowerPoint Templater Editor is now available with support for common operations

Templater Editor schema integration

  • Builder API now allows configuring Templater Editor integration for schema building (this is not available in the SOLO version of the library)
  • When schema building is enabled, after processing finishes, template will remain as before, but additional metadata will be embedded in the document, such as listing of all available tags, for better and easier template management
  • Alias definitions can be specified through the builder API, which allows for more friendly tag usage, especially when combined with navigation customizations

Navigation customization

  • Templater now allows user defined expression during navigation. To enable this feature, navigation separator must be defined, e.g. ‘:’. Then built-in or user defined plugins can be invoked, e.g.: [[items:at(0).name]] will process only the first element of the collection instead of the entire collection. This vastly expands customization options, e.g.: custom sorting can be applied during navigation [[object.collection:sort(property).description]] where user defined plugin which will take care of sort(property) argument.
  • Navigation character can be changed. Default navigation character is . (DOT), but some else can be used, e.g.: / (SLASH)
  • Default TAG regex was changed to include new common characters: :, (, ) and |

Low-Level API improvements and breaking changes

  • End of life for .NET 3.5 version
  • Resize now supports specifying exact tags which should be used. New API has been added for this purpose Resize(TagPosition[], int). The old resize API uses various heuristics to process tags, while this new API does exactly what it was asked (when possible)
  • Handler API change. To support the new Resize API, handler accepts a new int position argument. Argument will be -1 for most cases, but when there is tag sharing involved, it will specify index of the shared tag
  • collapse-nested and collapse-to handlers only work in non-sharing mode (when position == -1)

Bugfixes and improvement

  • When replacing image via Alt Text, Templater will now always inject new image resource, instead of trying to replace it in some cases. This was causing problems where images were copy pasted around the document, which would point to same underlying resource
  • Missing tags processing improvements. In some cases when processing dictionary when nested tags were partially missing, Templater would not call OnUnprocessed
  • Table of Content Word improvements. Fix some regressions in range detection with TOC. Templater will now search for next entry or section/page break after TOC as border for duplication
  • License detection improvements. License watermark will now be different if specific common error happens (e.g.: old license from v2 is used)
  • Special object removal in Word. If resize(tag, 0) is called on a special object like an image, text box or WordArt (any other drawing object) Templater will remove only that object instead of looking for best context surounding that object
  • List resize bugfix. When resizing multilevel lists multiple times, Templater would sometimes incorrectly decide to resize region of the document, instead of only list

2020-08-24 v4.6.0

Templater Editor alias integration

  • Templater Editor now allows alias definition in the Manage tags screen. Aliases allow for shorter tags, which helps in Word tables to prevent cell stretching. Aliases are matched against tag prefix

Bugfixes and improvement

  • Nested table/result set processing bugfix. When DataTable is used as a property in another DataTable and some tags are missing in the input tags would be processed incorrectly due to usage of :unprocessed on wrong tags. Now only relevant tags will be marked with :unprocessed metadata
  • OOXML processing will now recognized aliases defined via Templater Editor
  • Tags repeated in lists will not similarly to tags repeated in tables. If tags are only defined within a lists, only relevant lists will be resized instead of entire document
  • Dynamic resize improvements in PowerPoint. Previously only a single Dynamic resize was supported in familiar way within PP table. Now multiple such types can be used which will behave similarly to Word/Excel (eg jagged array for each row)
  • Table of Content Word improvement. Templater will now respect the page break configuration after TOC.

2020-07-02 v4.5.0

Templater Editor for Microsoft Office 2007+ on Microsoft Windows

  • Templater Editor is Microsoft Office Add-In available to Reporting Team and Enterprise licenses. It provides improved user experience for managing Templater templates. Currently only available for Word and Excel
  • Tag management via schema import
  • Tag analysis with issue detection
  • Tag listing from defined schema
  • Running Templater processing from within Word/Excel UI for easy testing/REPL

Existing image replacement

  • Support replacing existing images when tag is added to their Alt Text. This finally allows the use of images in PowerPoint and expands the use cases since image can now be preconfigured in much more detail

Improvements and bugfixes

  • Word header/footer tag handling improvements. In some cases Templater would process tag only once, instead every time if tag was located in header/footer
  • Word 2016 chart coloring improvements. Charts created in new Word 2016 would reuse the same color for different points, instead of following the predefined coloring scheme
  • Word header/footer duplication improvements. For some documents with multiple headers/footers tags were replaced in incorrect order
  • Use System error console for logging unexpected problems with license check
  • Excel pushdown bugfix. In some cases Templater would push only a subset of cells down, instead of using wider range due to other elements (named ranges, etc..) present in the document
  • Detect PowerPoint lists in more cases. While custom bullet format was already detected in notes, now it will also be detected in slides

2020-05-26 v4.4.0

Breaking change

  • Low level replace API now accepts two additional arguments: tag (string) and metadata (string array). Existing configuration for that API needs to be adjusted on latest version.

Improvements and bugfixes

  • Support for CSV embedded within Excel. While such CSV could be processed by openning up xlsx zip, this way no special code changes are required for this scenario. Multiple CSV can be embedded. Tags can be repeated in worksheets and in CSV, although they might require special care
  • :unprocessed support in DataTable, IDataReader and ResultSet. Previously this data types would just leave tag as is. Now they will invoke OnUnprocessed handler on them
  • Renumbering of Word round shapes - previously Templater would not renumber this shapes which resulted in “corrupt” document
  • Performance improvements for Excel formula processing
  • PowerPoint fix for collection tag repeated on slides. Correctly sort tags on analysis for expected resize behavior
  • Word nested table/list renumbering. When resize affects more than a single table (nested tables) renumber lists in the process. This resolves problem of list numbering continuing across different tables

2020-02-04 v4.3.0

Excel resize(tags, 0) improvements

  • Templater will now hide rows or columns when they are fully affected by resize operation. Previously they would be left as-is
  • Sheets can now be “removed” with resize operation. Sheets will actually be set to very hidden, so they are not listed in the list of hidden sheets

Excel bugfixes and other improvements

  • Fix for whole row/column pattern duplication. If another sheet is referenced, after duplication formula will still be referencing other sheet (instead of loosing sheet reference)
  • Cope with formulas which reference table header using a tag. Previously this worked only if header is first processed and then formulas are duplicated. Now Templater will fix formulas at a later point if necessary. It is still recomended to first rename the header and then duplicate the formulas if possible. If possible it is recommended to avoid the use of tags in table headers when they are referenced by formulas.
  • Improve thread interrupt checking. Thread interrupt was missing on few critical places after resize operation.
  • Various performance improvements. Templater will now process sheets with merge cells much faster. Some allocations were removed
  • Basic support for array formula

2019-12-23 v4.2.0

Scalable Vector Graphic (SVG) support

  • Microsoft Office 2016 has native support for SVG. SVG can be passed as XDocument/Document data type.
  • SVG converter builder API. To optionally support older MS Office tools, SVG document can be converted into image which will be displayed on older Word/Excel versions.

Excel range improvements

  • Whole row/column patterns are now supported (eg: A:B, 5:5, $A:$A, …)

Horizontal resize regression fix from v4.1.0

  • In some cases cell left of the resize range would be incorrectly moved to the right. Now cells left of the horizontal resize range will stay on the left.

2019-12-02 v4.1.0

Image improvements (.NET only)

  • .NET now has Templater specific ImageInfo type like Java. Since System.Drawing is not available in some environments (like Azure Functions) features can be replicated by using Templater specific ImageInfo directly. Previous System.Drawing.Image and Icon are still supported out-of-the-box via builtin plugins. Another managed only library can be used in such scenarios.

XML improvements (JVM only)

  • Stable XML setup. Previously Templater would use default factory instance for XML parser and transformer. If there were dependencies with META-INF services they could change the used parser. Templater will now check for new Java 11 API, if that does not exists will try to use Java version of Xalan (default XML parser) and if that is not available default to previous behavior of using default factory instance.
  • XML factory setup is now available via configuration instead of System.getProperties. Previous method of customizing XML is no longer supported.

Method blacklisting

  • Method/member blacklisting can be done via blacklist configuration API. This is useful to prevent access to some sensitive information.

Bugfixes and improvements

  • Dynamic Resize on lists and arrays will now check for header metadata. While previously only ResultSet/DataTable would rename columns in Excel table, this can now be done with lists/arrays as long as header metadata exists.
  • Dynamic Resize duplicate column name will now be localized only to that column. Previously if there was duplicate names in ResultSet all columns would be named via ColumnX pattern instead of provided names. Now unique names will remain, while only duplicate or empty ones will use ColumnX pattern.
  • Word header/footer duplication bugfix. In some documents header/footer naming would create file with already existing part. Templater will now check that header/footer file names are really unique.
  • Horizontal resize did not work is some cases when there was more than one column involved in the resize. Column styles were not copied correctly and formulas within the context could cause NPE.
  • Merge cell handling fixes on horizontal resize. Depending on the setup Templater could create “corrupted” document during stretching/copying of merge cells. Now it will handle them differently to avoid creating such problems.
  • Dynamic Resize on ResultSet/DataTable with only a single column did not rename column names previosly. Now Templater will set the column name even when there is only a single column and even no rows.
  • Fix formula references to named ranges in local sheet. Previously Templater assumed that named ranges have unique names when referenced in formulas. Now it will guard for cases when there are several named ranges with same name on different sheets.
  • Outline level (grouping) will now be respected during resize. On horizontal resize whole-column metadata was required to duplicate the entire column. Now this will be done also when there is outline level defined.
  • Shared formula will not be rewritten anymore on horizontal resize. Previously it was changed into a non-shared expression.
  • Thread interrupt check was missing in fast path Excel resize. Now thread interrupt will be respected even there, which resolves the issue of huge documents used on fast path.
  • Fix tag detection in documents with both TableOfContent and headers/footers. Previously Templater could throw XML exception on such documents.
  • Minor Excel performance optimizations and memory usage reductions.
  • Part naming improvements. Many embedded files will now follow stable pattern when created. Previously they were often using random names to remain unique.

Breaking changes

  • (JVM only) ImageInfo DPI renames. ImageInfo now matches .NET naming and data types.
  • GetMetadata(tag, bool) now returns only user defined metadata. Internal metadata is only available via GetMetadata(tag, index) API. This makes the API behavior consistent with the documentation.

2019-10-19 v4.0.1

Image improvements (.NET only)

  • Images will be saved in original format (when possible). Previously images were always saved as PNG.

Bugfixes and improvements

  • Cope with pivot tag. Previously if Pivot dimension was a tag, it would get lost after conversion.
  • Performance improvements with parsing formulas in Excel.

2019-09-11 v4.0.0

PowerPoint support

  • Templater now supports pptx and pptm files. Most regular features are available, such as: dynamic resize, slide duplication, table resizing, chart population, etc.

License key change

  • Templater v4 requires a new license key. License key from v1 will not work on v4 of the Templater.

Bugfixes and improvements

  • Support for inline string in Excel. Previously Templater did not support string values embedded directly into cell marked via special inlineStr attribute.
  • Various performance improvements.
  • Support for Java 11. Due to removal of several deprecated features in Java 11, license validation did not work as expected without additional dependencies
  • Avoid analyzing tags on resize which contain :unprocessed metadata (in Excel).
  • Fix merge cells handling/duplication in some edge cases in Excel.

2019-08-15 v3.2.1

Bugfixes and improvements

  • Detect built-in styles defined as lists. Previously Templater did not consider such parts of the documents as list and was treating them differently which resulted in different resize rules.
  • Cleanup all shared tags which are missing. Previously just the first tag was processed (marked with :unprocessed metadata)
  • Include missing tags in resize for dictionary collections when prefix is used. This fixes cleanup of missing tags which now goes over all (shared) of them
  • Support pivot multi-select filters. Templater will now ignore such tags instead of trying to process them.
  • Pushdown in Excel will cope with ranges which are up to maximum row number (1 million)
  • Include repeated tag which is not shared in Word resize. If tag is within the same context it should be included in the resize (even when repeated).
  • Avoid analyzing tags on resize which contain :unprocessed metadata (in Word).
  • Fix tag sharing in some edge cases in Word.
  • (.NET only) Cope with Excel document without count attribute on merge cells. Previously Templater would throw NPE
  • (JVM only) Add empty paragraph within table cell only when necessary (added in 3.0.0 but implemented incorrectly for JVM)

2019-06-17 v3.2.0

Streaming improvements

  • Allow specifying streaming size in IDocumentFactoryBuilder. Streaming size will be used as chunking size for DB reader types or Iterable/Enumerable types (non dictionary ones)
  • Iterable/IEnumerable types will be analyzed only once and processed in chunks (based on the streaming size). By default streaming size of 16384 is used. Previously Templater could consume part of input during analysis
  • Text flushing will use streaming size
  • Collection with known size will not be streamed (ICollection in .Net Collection in Java and Seq in Scala)

Excel improvements

  • Templater will now move drawing objects around on pushdown/pushright. This includes images, WordArt, Charts and similar objects which were previously not affected
  • Support for drawing objects: WordArt and TextBox
  • 3 letter columns support. Previously Templater only supported 2 letter columns (up to ZZ). Now columns up to ZZZ are supported.

Android support (JVM only)

  • Templater now works in Android (it requires global system parameter for ignoring unsupported XML features)
  • Internal image data structure is now public - ImageInfo
  • During setup Java image conversion should be disabled by turning off builtin low-level plugins (which do conversion of BufferedImage and ImageInputStream to ImageInfo)

Bugfixes and improvements

  • Chart data source will be adjusted on pushdown/other changes
  • Guard against sheet dimension over 1M rows - keep dimension at maximum size instead
  • Shared tags are now processed much faster - previously it was prefereable to use a new tag root instead of repeating same tag in a collection on multiple sheets
  • Performance optimization with large number of named ranges pushdowns (use more optimized algorithm)
  • (JVM only) Support adding image to an Excel document which didn’t have images previously. This was already working in .NET version
  • Cope with Excel documents without dimension info. Non MS tools sometime create such documents
  • Cope with conditional formatting on pivots. Templater ignores such formatting, while previously it would fail during initial analysis
  • (JVM only) Support for Scala 2.13
  • Fix for text streaming on multi-row context. Previously Templater would corrupt the order and fail with OutOfMemory error when used in such scenario
  • substring metadata will not throw exceptions anymore. Instead empty string will be returned

2019-05-05 v3.1.0

New configuration API

  • Allow specifying format per each tag pattern through withMatcher on IDocumentFactoryBuilder

Bugfixes

  • Excel comments will now respect cell which they reference. Previously they were considered in same manner as header tags which is not correct
  • Stable tag sort during object processing. Tags should be processed in order of definition in the document (unless they require navigation). Since v2.9.4 they could be sorted in a way which causes problems due to use of handler plugins

Dynamic type improvements (.NET only)

  • Dynamic resize will now work on IList<object> as long as all elements are either IList<object> or IList<string>. This matches the behavior of JVM which due type erasure worked correctly for complex JSONs
  • OnUnprocessed will be called while processing dictionary even when it has no keys
  • Builtin collapse will now be invoked on empty maps even in JVM (previously it was invoked on empty Dictionaries in C# only)

2019-04-15 v3.0.0

New tag format

  • [[tag]], {{tag}} and <<tag>> formats are now supported

Unprocessed tags handling changes

  • There is a new API in configuration builder for specifying custom behavior for handling unprocessed tags: OnUnprocessed
  • Previously unprocessed tags were handled differently for different processor types. Sometimes they were not handled at all which could lead to large memory usage due to bad context detection.
  • The default implementation will append :unprocessed on the tags which were expected to be handled, but input could not be matched (such as missing attributes in JSON, typos in document, etc…)
  • Few handlers still do not use such API (readers/data table/data set)

Plugin customization APIs

  • Now it’s possible to disable builtin handlers/formatters during library initialization

Java bean naming support (JVM only)

  • Templater now recognizes bean naming and will match appropriate tag such as name with getName method.
  • Bean naming support can be disabled during library initialization
  • On naming conflict exact name will be used instead of bean name

Bugfixes and improvements

  • Exception is thrown if clone is called while CSV streaming has started
  • More interrupt checks on some places - Templater will now exit more quickly in case of thread interrupt
  • Cope with empty table cells in Word - when list is removed from a table it could have resulted in corrupted document due to missing paragraph. Templater will now inject empty paragraph so document is not corrupted
  • Cope with Word orientation change as last page - previously when a section is removed which changed the last orientation an empty last page would remain. Now document will be adjusted to look as expected
  • Support for tables without count in XLSX - LibreOffice sometimes removes some attributes which are not required. This fixes NPE which could happen in such cases
  • Improved resizing with headers in Word - previously Templater would not respect tags in headers as it should. This resulted in bad context detection and strange output document
  • Text sharing detection fix - sometimes sharing would be used on the wrong tag during CSV/text processing