Integrate Software AG Products Using Digital Event Services 10.4 | Integrate Software AG Products Using Digital Event Services | MashZone NextGen Help | Appendix | Legacy Presto components | Mashables and Mashups | Mashups in MashZone NextGen Wires | Customizing Wires | Configure Field and Line Sizes for Custom Block Properties
 
Configure Field and Line Sizes for Custom Block Properties
You can make property fields be Multi-Line Input Fields. You can also set Field Width and Height for custom block properties.
Multi-Line Input Fields
By default, the block property fields for macro input parameters are a single-line entry field. You can change this to a multi-line field using the macro metadata element <type> with a datatype of textarea in <parameter>.
For example:

<macros xmlns="http://www.open-mashup.org/schemas/v1.0/EMML"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.openmashup.org/schemas/v1.0/EMML/..
/schemas/EMMLPrestoSpec.xsd"
domain="myBlocks">

<macro name="helloWorld"
xmlns:presto="http://www.jackbe.com/v1.0/EMMLPrestoExtensions"
xmlns:macro="http://www.openmashup.org/schemas/v1.0/EMMLMacro">
<presto:macro-meta>
<block usage="Wires">
...
</block>
<parameters>
<parameter name="aString">
<label>A description</label>
<type datatype="textarea"/>
</parameter>
...
</parameters>
</presto:macro-meta>
....
</macro>
...
</macros>
Field Width and Height
By default, Wires sets the width for block property fields to fill the width of the current Block Properties pane. See for an example.
You can use the macro metadata element <uiconfig> in <parameter> to manually set the width and height of block property fields.
Note: The <uiconfig> element contains a configuration object in JSON (Javascript Object Notation) format. Typically, you should enclose this in a CDATA section to ensure there are no conflicts between the JSON and XML syntaxes.
See Advanced Custom Block and Property Configuration for more information on the options you can use with <uiconfig>.
Use the anchor property to set the width and the style property to set the height. For a single-line block property, for example:
The metadata would look something like this:

<macros xmlns="http://www.open-mashup.org/schemas/v1.0/EMML"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.openmashup.org/schemas/v1.0/EMML/..
/schemas/EMMLPrestoSpec.xsd"
domain="myBlocks">

<macro name="helloWorld"
xmlns:presto="http://www.jackbe.com/v1.0/EMMLPrestoExtensions"
xmlns:macro="http://www.openmashup.org/schemas/v1.0/EMMLMacro">
<presto:macro-meta>
<block usage="Wires">
...
</block>
<parameters>
...
<parameter name="aNumber">
<label>An integer</label>
<type datatype="integer"/>
<uiconfig>
<![CDATA[{ "anchor":"60%" }]]>
</uiconfig>
</parameter>
...
</parameters>
</presto:macro-meta>
....
</macro>
...
</macros>
For a multi-line block property, you can set both height and width:
The metadata would look something like this:

<macros xmlns="http://www.open-mashup.org/schemas/v1.0/EMML"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.openmashup.org/schemas/v1.0/EMML/..
/schemas/EMMLPrestoSpec.xsd"
domain="myBlocks">

<macro name="helloWorld"
xmlns:presto="http://www.jackbe.com/v1.0/EMMLPrestoExtensions"
xmlns:macro="http://www.openmashup.org/schemas/v1.0/EMMLMacro">
<presto:macro-meta>
<block usage="Wires">
...
</block>
<parameters>
<parameter name="aString">
<label>A description</label>
<type datatype="textarea"/>
<uiconfig>
<![CDATA[{ "anchor":"75%", "style":"height:120px;" }]]>
</uiconfig>
</parameter>
...
</parameters>
</presto:macro-meta>
....
</macro>
...
</macros>

Copyright © 2019 | Software AG, Darmstadt, Germany and/or Software AG USA, Inc., Reston, VA, USA, and/or its subsidiaries and/or its affiliates and/or their licensors.
Innovation Release