ONYX - 9.0 - Utilisation

Output conversions

De MappingDoc
Cette page est une version traduite de la page ONYX:9.0:Utilisation:Convertisseurs de sortie et la traduction est complétée à 100 %.

Autres langues :
English • ‎français

<language/>

The configuration file: xpsConfig.conf

Definition

All conversions from the pivot XPS format to the destination languages ​​are handled natively in the engine. They are defined and refined by different fully configurable conversion profiles and stored in a configuration file called XPSConfig.conf. Physically, this file is located in the folder defined by the XPSCONFIG configuration variable.

Example on Windows:

[XPSCONFIG] C:\Program Files\M-Processing Server\Settings\XPSConfig.conf

Example on Linux:

[XPSCONFIG] /apps/mapping/conf/XPSConfig.conf


Structure and syntax

The general structure of the XPSConfig.conf file is based on XML syntax:

<xpsconfig>
  <profile_1>
         <param_1>valeur</param_1>
         <param_2>valeur</param_2>
         <param_3>valeur</param_3>
          …
   </profile_1>
   <profile_2>
           <param_1>valeur</param_1>
           <param_2>valeur</param_2>
           …
   </profile_2>
           …
</xpsconfig>

As many conversion profiles as necessary can be declared depending on the different input/output channels of production documents. Each profile must have a unique name which will be used by Spooler Mapping or on the command line to identify the correct conversion profile. For each profile, all the useful parameters allowing the conversion to be carried out, refined and optimized are provided.


Important:

All information contained in this configuration file is case sensitive: name of the different profiles, names and values ​​of the parameters.


Note:


All parameters documented below can also be used on the command line and can be overridden when calling a map_xps conversion command. The syntax for calling a particular parameter is then: -param:parameter_name=value.

Generic parameters

Some parameters are generic and can be used in all profiles regardless of the conversion language.


Language

This first parameter is required for all profiles. It defines the output language of the conversion. The syntax in the profile is:<language>PCL</language>

Here is the list of all output formats supported by ONYX Server:

  • XPS (default language if not specified in the profile)
  • Print languages:
    • PCL
    • ZEBRA
    • AFPDS
    • PGI
    • PS (PostScript)
    • TEC
    • PROPRINTER
    • EPL
    • ESCP
    • MONARCH
    • XMLPOS
    • DPL (Datamax)
    • DB4


  • Web languages:
    • HTML
    • RTF
    • PDF
    • DOCX
    • TXT


  • ONYX Server outputs:


MAPDRAW (used for importing XPS assets into M-Designer)


  • Image outputs:

IMAGE

BMP

Label

This optional parameter allows you to give a user description to the profile. This description will be used in particular in the ONYX Server Spooler for configuring print queues (XPS compatibility parameter).


The syntax in the profile is:<label>PCL5 printing in black and white</label>


Color

This optional parameter allows you to activate or deactivate color conversion for destinations that support it. When this parameter is not specified in the profile, the principle is to respect a conversion faithful to the original XPS document. So, for destinations that support it, color conversion is enabled by default.


The syntax in the profile is: <color>on</color>


Supported values: ON/OFF, on/off, YES/NO, yes/no, 0/1


Default value: ON, except for the AFPDS language.


For languages ​​that support it, ICC (International Color Consortium) color profiles are also supported, with the syntax: <outputICC>path_to_ICC_file</outputICC>


Code page

This optional parameter allows you to define the output code page for destinations that support it. The syntax in the profile is:<codepage>850</codepage>


Supported values: depending on the output language


Default value: dependent on output language


Resolution

This optional parameter allows you to define the output resolution of the document expressed in dpi (dots per inch). The syntax in the profile is:<resolution>240</resolution>

Supported values: 200, 300, 600....


Default value: that of the defined output language


For destinations that support it, the resolution (in dpi) of the document images can also be specified with the syntax: <resolutionimage>240</resolutionimage>


Supported values: 203, 300, 600…

Default value: that of the defined output language


Rotation

This optional parameter allows you to define the rotation angle (anti-clockwise or trigonometric) of the output pages. The syntax in the profile is:<pagerotation>90</pagerotation>

Supported values: 0, 90, 180, 270

Default value: 0 (no rotation)


Paper Size

This optional parameter allows you to modify the format of the output pages. The size of the pages as well as the content will be recalculated. The syntax in the profile is:<changeformat>Letter</changeformat>

Supported ISO standard values: A2, A3, A3 Extra, A4, A4 Plus, A4 Extra, A5, A5 Extra, A6, B4, B5, B5 Extra, B6, Envelope #9, Envelope #10 , Envelope #11, Envelope #12, Envelope #14, Envelope B4, Envelope B5, Envelope B6, Envelope C3, Envelope C4, Envelope C5, Envelope C6, Envelope C65, Envelope DL, Envelope Invite, Envelope Monarch, Envelope, Executive, Folio, German Legal Fanfold, German Std Fanfold, Japanese Postcard, Japanese Double Postcard, Ledger, Legal, Legal Extra, Letter , Letter Extra, Letter Plus, Letter Small, Note,PRC 16K, PRC 32K, PRC 32K(Big), PRC Envelope #1, PRC Envelope #2, PRC Envelope #3, PRC Envelope #4, PRC Envelope #5, PRC Envelope #6, PRC Envelope #7, PRC Envelope #8, PRC Envelope #9, PRC Envelope #10, Quarto, Statement, SuperA, SuperB, Tabloid, Tabloid Extra, US Std Fanfold.


Custom values ​​are also supported, with the syntax:<changeformat>xx.xx,xx.xx[,cm|in|mm]</changeformat>


  • two decimal values, separated by a comma corresponding to width and height respectively
  • The decimal separator is ‘.’
  • The unit is optional: cm (default), mm or in (for inch)
  • The brackets should be removed (they symbolize the optional aspect)


Image output

This optional parameter allows conversion to image mode, for languages ​​that support it. The size of the flows is not optimal but the rendering of all elements is thus guaranteed. The syntax in the profile is:<fullimage>on</fullimage>


Supported values: ON/OFF, on/off, YES/NO, yes/no, 0/1


Default value: off


Interval between 2 labels

This optional parameter allows you to define, for thermal languages, the distance between two labels. The value is expressed in points. The syntax in the profile is:<gap>24</gap>


Page offset

These optional parameters allow you to shift all the pages of a document without changing the margins. Values ​​are expressed in 96dpi and are decimal. The syntax in the profile is:

<XpsTopOffset>10.2</XpsTopOffset>
<XpsLeftOffset>8.1</XpsLeftOffset>


Image resizing quality

This optional parameter allows you to improve the quality of image resizing in order to make it more precise. The syntax in the profile is:<precisemode>on</precisemode>


Supported values: ON/OFF, on/off, YES/NO, yes/no, 0/1


Default value: off


Font management

The XPS document contains all the resources necessary for its display including, in particular, the fonts used in ODTTF format. In conversion to an output language, the choice is possible whether or not to embed the fonts in the flow. This choice will depend on the languages ​​and printing equipment.


Embedded fonts

This optional parameter allows you to activate or deactivate the incorporation of fonts in the final document. When this setting is enabled, the fonts used in the XPS document will be embedded in the output stream and therefore sent to the printer. Otherwise, the printer's resident fonts will be used for printing. When this parameter is not specified, it is enabled by default. The syntax in the profile is: <embeddedfont>ON</embeddedfont>


Supported values: ON/OFF


Default value: ON (except for AFPDS, PS and RTF languages)


When this setting is disabled, another setting allows you to force the use of a default resident font for any undeclared XPS font (see below). The syntax in the profile is:<defaultfont>1</defaultfont>


Supported values: from 1 to n, identifying the number of the font match to use by default in the profile.


Default value: 1


Resident fonts

When the previous setting is disabled, it is necessary to predict the correspondence between the fonts of the XPS document and those to be used on the printer. This correspondence table is constructed in the profile with the following syntax:

<fonts>
          <font name="Arial" size="10" height="100" italic="0" bold="0" zoomx="1" zoomy="1" codeFont="4" />
          <font name="Tahoma" size="10" height="100" italic="0" bold="0" zoomx="1" zoomy="1" codeFont="A" />
          …
          </fonts>


In this table, between one and five parameters are used to identify XPS fonts:


  • name = XPS font name (required)
  • size = size in points of the font (optional)
  • height = height or vertical deformation in percentage (optional)
  • italic = italicized font or not (optional)
  • bold = bold font or not (optional)


Then between one and five parameters are used to identify the resident font that should be called:


  • codeFont = resident font number to use for printing (required). The values ​​depend on the printing language and printer model and are generally given by the printer manufacturer.


Examples:


- for a Zebra printer, the values ​​go from A to Z, or from 1 to 9


- for an Eltron printer, the values ​​range from 1 to 5


  • zoomx = size to width multiplication factor (optional)
  • zoomy = size-height multiplication factor (optional)
  • type = resident font type (bitmap or vector) in TEC language (optional)
  • fgid = AFP font identifier (optional)


1D barcode management

Since 1D barcodes are also rendered by fonts, the same choice as above is possible depending on the languages ​​and printing equipment.


Onboard or resident barcode

This optional parameter allows, for thermal languages ​​and AFPDS, to activate or deactivate the rendering of 1D barcodes by the printers themselves. When this setting is enabled, barcode printing is handled by the printer using its resident fonts. Otherwise, the fonts used in the XPS document will be embedded in the flow and therefore sent to the printer. When this parameter is not specified, it is activated by default.

The syntax in the profile is:<barcode>PRINTER</barcode>

Supported values: IMG, FONT, PRINTER

Default value: PRINTER


IMG: embedded as an image
FONT: embedded as a font
PRINTER: the barcode is generated by the printer


Printer rendering

When the previous setting is activated, it is necessary to predict the correspondence between the fonts of the XPS document and those to be used on the printer. This correspondence table is constructed in the profile with the following syntax:

<barcodes>
<barcode type="21" size="35" height="200" bcheight="40" bcwidth="A,B" />
…
</barcodes>


In this table, three parameters are used to identify XPS fonts:

  • type = barcode type (see table below)
  • size = size in points of the font
  • height = height or vertical deformation in percentage


Then two parameters are used to customize the physical dimensions of a barcode when printed:


  • bcheight = desired height of the barcode (in points)
  • bcwidth = desired width of the barcode, specifying for example the width of a thin element and the ratio between thin and thick element


The syntax and values ​​of these two parameters depend on the final printing language and the type of barcode. List of barcodes supported by ONYX Server, with their type:

2 PDF 417
11 Data Matrix
12 QR Code
14 MaxiCode
17 EAN 13
18 EAN 8
19 Code 39
20 Code 39 No check
21 Code 128 alpha optimzed
22 Code 128 alpha non optimized
23 Code 128 Numeric
24 2 Among 5 Interlaced
25 2 Among 5 Interlaced No Check
26 2 Among 5 industrial
27 2 Among 5 industrial No ckeck
28 EAN 128 alpha non optimized
29 EAN 128 numéric
30 EAN 128 alpha optimized
31 Postnet
32 Planet
35 Native
77 Japan Postal
78 Codabar
79 USPS
80 UPC-A
81 UPC-E
82 MSI
83 MSI 2 mod. 10
84 MSI mod. 11
85 MSI mod. 11 mod. 10
86 MSI no check
Autres langues :
English • ‎français

Conversion to PCL5

Language tag

To configure the conversion profile for XPS to PCL conversion, you must set the language parameter to PCL <language>PCL</language>


Input/output bin management

This involves defining a correspondence table between a logical code (numerical value) applied in the XPS document and the PCL code of the destination printer tray. The syntax in the profile is:

<inputbin>
       <bin from="1" to="8" />
       <bin from="2" to="1" />
       <bin from="3" to="2" />
</inputbin>
<outputbin>
       <bin from="5" to="2" />
       <bin from="7" to="3" />
</outputbin>


Caution :

The logical codes (which can, for example, represent the geographical location of the bins on the printer) can be the same from one printer to another. These are 'user' values ​​and the PCL codes are specific to each printer. They can vary from one manufacturer to another and sometimes even from one printer model to another for the same brand.


Paper type management

Here again, it is a correspondence table between a logical value (user) and a PCL code (hardware dependent) corresponding to the desired paper format.


Management at Print Job level : To add a MEDIATYPE sequence to an XPS file, you can run the following command:

"[%PATH_BIN%]/map_xps" "-infile:[%MAP_FILE_IN%]" "-set:MEDIATYPE=Header_Paper" "-outfile:[%MAP_FILE_OUT%]"


<mediatype>

       <type from="Letterhead" to="Letterhead" />
       <type from="Preprinted" to="Preprinted" />
       <type from="Normal paper" to="Plain" />
</mediatype>


In the generated PCL flow, the information will be positioned in a PJL sequence at the start of the print job: @PJL SET MEDIATYPE=Preprinted


Management at Document or Page level :

<mediatype mode="AlphanumericID">
       <type from="Letterhead" to="Letterhead" />
       <type from="Preprinted" to="Preprinted" />
       <type from="Normal paper" to="Plain" />
</mediatype>


In the generated PCL flow, the information will be positioned in PCL sequences for each document (or for each page) of the print job. Example: &n11WdPreprinted.

Management of printing margins

Two parameters, expressed in points (based on a resolution of 300 dpi) allow you to adjust the horizontal (X) and vertical (Y) printing margins. This corresponds to the actual printer margins.

<marginx>78</marginx>
<marginy>0</marginy>


Default values: 78 for marginx and 0 for marginy. That is to say 0.66cm for the marginx and 0cm for the marginy, corresponding to the default margins of PCL printers.


Stapling management

New correspondence table between a stapling type defined in the XPS document and the PCL/PJL code which will be inserted in the final document to control the stapling equipment.


The syntax in the profile is:

<stapling>
        <staple from="SaddleStitch" to="@PJL SET STAPLE=ON" />
        <staple from="StapleBottomLeft" to="@PJL SET STAPLE=ON" />
        …
</stapling>


Supported stapling types:

SaddleStitch stitched binding
StapleBottomLeft staple bottom left
StapleBottomRight staple bottom right
StapleDualBottom staple at bottom
StapleDualLeft left stapling
StapleDualRight right stapling
StapleDualTop staple on top
StapleTopLeft staple top left
StapleTopRight staple top right


Image management

Sharing of resources

To optimize the size of the converted stream, a first parameter allows you to manage the background images as a resource in the document. Images common to several pages are only present once in the final PCL.


The syntax in the profile is:<imageresource>ON</imageresource>


Supported values: ON/OFF, on/off, YES/NO, yes/no, 0/1


Image compression

Still with the aim of optimizing the size of the streams, several output image compression algorithms are implemented and can be used in the profiles:<RasterCompressionMethod>Raw</RasterCompressionMethod>


Supported values:


  • Raw: Raw mode, without optimization or compression. This mode is not recommended in production, but it does allow you to validate the interpretation of the input image stream.


  • RLE: Run Length Encoding mode. This method is recommended for images with a high rate of identical colors. On the other hand, it is strongly not recommended for images with color gradients.
  • TIFF: Enhanced RLE mode. This versatile method mixes the two previous ones, thus avoiding wasting space on gradients in particular.
  • DeltaRow: Row difference mode. This method uses the previous line to describe the next line and therefore only encodes the differences. Optimal method in most cases.


  • Adaptive: Adaptive mode. This method detects among the previous ones which method is the best for each of the lines of the image to be encoded.
  • Dynamic: Improved version of Adaptive mode for very large images, especially in combination with the fullimage setting ON.


Filling management

For black and white output only, the following parameter allows you to use the fill patterns generated in the XPS (= true), or those of the printer (= false): <uploadPattern>true</ uploadPattern>

Autres langues :
English • ‎français

Converting to PDF

This page explains how to use an XPS to PDF conversion profile to set the expected type of PDF output, electronic signature and the different protection options.

Language Tags

To set the conversion profile to produce PDF output, first add the Language tabs as shown:

<language>PDF</language>

PDF/A output

Use the tags below to enable PDF/A output:

<pdfa>on</pdfa>

The parameter is set to off by default

When <pdfa> is enabled, the next parameter is for which version of PDF/A you wish to use.

<pdfaversion>1b</pdfaversion>

Supported values include:

  • 1b (default, for PDF/A-1b)
  • 2b (for PDF/A-2b)
  • 2u (for PDF/A-2u)
  • 3b (for PDF/A-3b)


Electronic Signature

Use the tags below to enable electronic signature of PDF documents created with Mapping ONYX Server:

<signclass>3</signclass>
<signmode>FILENAME</signmode>
<signpassword>test</signpassword>
<signdriver>OPENSSL</signdriver>
<signsha1hash>3eb783643e522c81d1e34c1943e6f4163e9ad439</signsha1hash>
<signpemfile>C:\tmp\test.pem</signpemfile>
<signcerfile>C:\tmp\test.cer</signcerfile>
<signpfxfile>C:\tmp\valid.pfx</signpfxfile>
<timestampurl>http://servertemp.domain/tsp</timestampurl>

By default, the PDF documents produced using ONYX Server are not signed.


Protecting PDF Files

Use the tags below to enable the various protection settings for PDF files produced using ONYX Server:

<encryptmode>on</encryptmode>
<encryptuserpwd>mapadmin</encryptuserpwd>
<encryptownerpwd>********</encryptownerpwd>
<encryptallowall>on</encryptallowall>
<encryptallowprint>on</encryptallowprint>
<encryptallowmodify>on</encryptallowmodify>
<encryptallowdataextraction>on</encryptallowdataextraction>
<encryptallowcomment>on</encryptallowcomment>
<encryptallowsignature>on</encryptallowsignature>
<encryptallowaccessibility>on</encryptallowaccessibility>
<encryptallowassemble>on</encryptallowassemble>
<encryptallowhightlevel>on</encryptallowhightlevel>

By default, the PDF documents produced using ONYX Server are not protected. ONYX:9.0:Utilisation:XPSConfig et conversion AFPDS/en ONYX:9.0:Utilisation:XPSConfig et conversion HTML/en ONYX:9.0:Utilisation:XPSConfig et conversion DOCX/en ONYX:9.0:Utilisation:XPSConfig et conversion IMAGE/en ONYX:9.0:Utilisation:XPSConfig et conversion ESCP/en

Autres langues :
English • ‎français

Conversion to ZEBRA

Language Tags

To enable the XPS to ZEBRA conversion profile, you first need to create a ZEBRA profile using the <language> tag like this

<language>ZEBRA</language>

Résolution

To change the resolution of the ZEBRA output stream, we need to use the resolution XML tag.

<resolution>203</resolution>

Fonts settings

Utilization of the resident text fonts

In order to make the ZEBRA stream ligher, it is possible no to include the fonts in the Zebra job. To do so, we need to use the fonts tag.

Exemple :

 <fonts>
   <font name="Arial" italic="0" bold="0" codeFont="I"/>
   <font name="Arial" italic="0" bold="1" codeFont="J"/>
 </fonts>

In our above example, if in the Designer project creating the XPS file, we have :

  • Arial , Not bold then in the output stream will have the call of font I
  • Arial , bold then in the output stream will have the call of font J

Barcodes case

Barcode tag

This parameter is to embed or not the font of the barcode in the datastream. If the barcode font is not embedded, the barcode will then be managed by the printer itself using its own resident fonts.

When this parameter is not set, it is set to OFF, this means the barcode font will be embedded in the datastream.

The syntax in the profile is as follow :

<barcode>off</barcode>

Supported values:

  • FONT : The font is embedded in the datastream
  • PRINTER : The font is NOT embedded in the datastream
  • IMG : The barcode will be sent in image mode

For retrocompatibily reason, the following values are also possible :

  • ON (on, YES, yes, 1) : The font will not be embedded in the datastream
  • OFF (off, NO, no, 0) : The font will be embedded in the datastream

Default value : FONT

Custom Barcode Size

  • bcheight: barcode height in points.
  • bcwidth: two comma-separated values, corresponding to, respectively:

- width of a thin bar in points

- ratio between a thin bar and a thick bar


Example:

<barcodes>
        <barcode type="19" height="100" size="46" bcheight="55" bcwidth="3,2.6" />
</barcodes>

Means that a Code39 (type 19) barcode, with font size 46 and vertical deformation 100%, will be printed in Zebra as a resident barcode of 55 points high, with a thin bar of 3 points, and a thin bar/thick bar ratio of 2.6.

Cutter Management

<cutter config="MMT" cmd="MMC" />

Activates the cutter at the end of printing

Exemple de XPSConfig.conf

<zebra>
   <label>Zebra</label>
   <language>ZEBRA</language>
   <resolution>300</resolution>
   <fonts>
     <font name="Arial" italic="0" bold="0" codeFont="0" />
     <font name="Arial" italic="0" bold="1" codeFont="0" />
   </fonts>
   barcode>OFF</barcode>
   <barcodes>
    <barcode type="80" height="100" size="56" bcheight="200" bcwidth="2,2.0" />
    <barcode type="80" height="100" size="54" bcheight="250" bcwidth="3,2.1" />
    <barcode type="80" height="100" size="55" bcheight="150" bcwidth="4,2.2" />
    <barcode type="80" height="100" size="57" bcheight="100" bcwidth="5,2.3" />
    <barcode type="80" height="100" size="58" bcheight="50" bcwidth="1,2.4" />
    <barcode type="20" height="100" size="20" bcheight="60" bcwidth="2,2.9" />
   </barcodes>
 </zebra>

ONYX:9.0:Utilisation:XPSConfig et conversion ELTRON/en ONYX:9.0:Utilisation:XPSConfig et conversion TEC/en ONYX:9.0:Utilisation:XPSConfig et conversion MONARCH/en ONYX:9.0:Utilisation:XPSConfig et conversion IGP/en ONYX:9.0:Utilisation:XPSConfig et conversion DPL/en Onyx 9.0 utilisation:utilisation des profils de conversion/en