Imported Upstream version 3.2.2
[debian/gnuradio] / grc / blocks / parameter.xml
1 <?xml version="1.0"?>
2 <!--
3 ###################################################
4 ##Parameter block: a grc variable with key, value
5 ###################################################
6  -->
7 <block>
8         <name>Parameter</name>
9         <key>parameter</key>
10         <var_make>self.$(id) = $(id)</var_make>
11         <make>$value</make>
12         <param>
13                 <name>Label</name>
14                 <key>label</key>
15                 <value></value>
16                 <type>string</type>
17                 <hide>#if $label() then 'none' else 'part'#</hide>
18         </param>
19         <param>
20                 <name>Value</name>
21                 <key>value</key>
22                 <value>0</value>
23                 <type>$type.type</type>
24         </param>
25         <param>
26                 <name>Type</name>
27                 <key>type</key>
28                 <value></value>
29                 <type>enum</type>
30                 <hide>#if $type() then 'none' else 'part'#</hide>
31                 <option>
32                         <name>None</name>
33                         <key></key>
34                         <opt>type:raw</opt>
35                 </option>
36                 <option>
37                         <name>Complex</name>
38                         <key>complex</key>
39                         <opt>type:complex</opt>
40                 </option>
41                 <option>
42                         <name>Float</name>
43                         <key>eng_float</key>
44                         <opt>type:real</opt>
45                 </option>
46                 <option>
47                         <name>Int</name>
48                         <key>int</key>
49                         <opt>type:int</opt>
50                 </option>
51                 <option>
52                         <name>Long</name>
53                         <key>long</key>
54                         <opt>type:int</opt>
55                 </option>
56                 <option>
57                         <name>String</name>
58                         <key>string</key>
59                         <opt>type:string</opt>
60                 </option>
61         </param>
62         <param>
63                 <name>Short ID</name>
64                 <key>short_id</key>
65                 <value></value>
66                 <type>string</type>
67                 <hide>#if not $type()
68 all#slurp
69 #elif $short_id()
70 none#slurp
71 #else
72 part#slurp
73 #end if</hide>
74         </param>
75         <check>len($short_id) in (0, 1)</check>
76         <check>$short_id == '' or $(short_id).isalpha()</check>
77         <doc>
78 This block represents a parameter to the flow graph. \
79 A parameter can be used to pass command line arguments into a top block. \
80 Or, parameters can pass arguments into an instantiated hierarchical block.
81
82 The paramater value cannot depend on any variables.
83
84 Leave the label blank to use the parameter id as the label.
85
86 When type is not None, this parameter also becomes a command line option of the form:
87
88 -[short_id] --[id] [value]
89
90 The Short ID field may be left blank.
91         </doc>
92 </block>