CIB merge technical documentation (EN)
6. Call parameters in detail
6.6. Parameter --charformat
With --charformat can be determined, if CIB merge shall use the switch \* CHARFORMAT if the results of fields do not deliver an own formatting.
Syntax
--charformat=<Option>
<Option>: off/none, auto/automatic oder plain-values-only
Description
With the parameter --charformat can be set, for which fields the character format is to be changed, i.e. for which fields the formatting is to be transferred to the field contents.
With the parameter --charformat most of the \* CHARFORMAT switches can be omitted, making the raw text shorter and more readable.
If the \* NOCHARFORMAT switch is specifically set for a field, this can prevent the --charformat parameter from being applied to this field (from CIB merge version 3.9.156).Nicht formatbehaftet sind Feldinhalte aus CSV-Datei, aus Paramterdatei, Datum Felder mit Schalter sind formatbehaftet.
For <Option> can be set the following values:
Option |
Description |
off or none |
The character format is not changed unless \* CHARFORMAT is explicitly specified in the field. |
auto or automatic |
Default setting. |
plain-values-only |
The character format is changed for fields that produce results without their own formatting, whether or not they have switches. |
Example
--charformat=plain-values-only
The
result of
{REF Vorname \* <cib-formfield type="text" info="Vorname" testvalue="Max" />}
gets the formatting of the REF field if --charformat=plain-values-only is set (in this case the text is written bold), although this field has a switch.
The use of the parameter is described in detail in the use case example Gap Text.There are field contents with formatted values on the one hand and field contents with non-formatted values on the other.
Formatted values that are output as field results do not need the field switch \* CHARFORMAT, but could be formatted in the same way.
Examples of field contents with formatting
are:
{includetext}, inserted RTF contents, {REF} (if the variable is formatted).
In these cases it is normally not useful to use the --charformat parameter. If desired, the \* CHARFORMAT switch can be set manually.
Values that CIB merge calculates from fields may be visible in the input text, may be completely new or may originate from the control file.
Examples of visible values are IF fields whose text comes from one of the alternatives exactly as it appears in the field or values assigned with SET. Visible values are formatted and not affected by the parameter.
By using the switch \*NOFORMAT in the SET command, this value can be turned into a non-formatted value (from CIB merge version 3.9.174).
Non-formatted values appear by default in the standard font (Times Roman, font size 10). They will be formatted by the --charformat parameter as if you specified the /* CHARFORMAT switch each time.
Examples for field contents with: {MERGEREC}, {date}, {=…}, values from CSV, {REF} (if the variable is not formatted),.
If --charformat is set for these fields, the \* CHARFORMAT switches can be omitted.
Examples of generated values are Aktualdat or the expression calculation with "=". These values are not formatted and are therefore affected by the parameter when they appear in the output.
Furthermore, there is no need to apply the switch if another switch already changes the formatting, for example \@ "dd.MM.yy". Here the formatting of the mask is used and not the character format. This also applies to superior fields. An IF field with \* CHARFORMAT does not need to handle the contents from the THEN or ELSE part in a formatted manner. A field contained in one of the two parts is formatted with the character format anyway.