File: qtgui_edit_box_msg.xml

package info (click to toggle)
gnuradio 3.7.13.4-4
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster, sid
  • size: 45,992 kB
  • sloc: cpp: 155,723; python: 88,934; xml: 42,165; ansic: 41,036; fortran: 927; asm: 803; sh: 224; lisp: 31; makefile: 17
file content (152 lines) | stat: -rw-r--r-- 3,451 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
<?xml version="1.0"?>
<!--
###################################################
##QT GUI Edit Box that sends messages
###################################################
 -->
<block>
  <name>QT GUI Message Edit Box</name>
  <key>qtgui_edit_box_msg</key>
  <import>from PyQt5 import Qt</import>
  <import>from gnuradio import qtgui</import>
  <import>import sip</import>
  <make>#set $win = 'self._%s_win'%$id
qtgui.edit_box_msg($(type.t), $value, $label, $is_pair, $is_static, $key)
self._$(id)_win = sip.wrapinstance(self.$(id).pyqwidget(), Qt.QWidget)
$(gui_hint() % $win)</make>

  <param>
    <name>Type</name>
    <key>type</key>
    <value>string</value>
    <type>enum</type>
    <option>
      <name>String</name>
      <key>string</key>
      <opt>t:qtgui.STRING</opt>
    </option>
    <option>
      <name>Int</name>
      <key>int</key>
      <opt>t:qtgui.INT</opt>
    </option>
    <option>
      <name>Float</name>
      <key>float</key>
      <opt>t:qtgui.FLOAT</opt>
    </option>
    <option>
      <name>Double</name>
      <key>double</key>
      <opt>t:qtgui.DOUBLE</opt>
    </option>
    <option>
      <name>Complex</name>
      <key>complex</key>
      <opt>t:qtgui.COMPLEX</opt>
    </option>
    <option>
      <name>Int (Vec)</name>
      <key>int_vec</key>
      <opt>t:qtgui.INT_VEC</opt>
    </option>
    <option>
      <name>Float (Vec)</name>
      <key>flt_vec</key>
      <opt>t:qtgui.FLOAT_VEC</opt>
    </option>
    <option>
      <name>Double (Vec)</name>
      <key>dbl_vec</key>
      <opt>t:qtgui.DOUBLE_VEC</opt>
    </option>
    <option>
      <name>Complex (Vec)</name>
      <key>cpx_vec</key>
      <opt>t:qtgui.COMPLEX_VEC</opt>
    </option>
  </param>

  <param>
    <name>Value</name>
    <key>value</key>
    <value></value>
    <type>string</type>
  </param>

  <param>
    <name>Label</name>
    <key>label</key>
    <value></value>
    <type>string</type>
  </param>

  <param>
    <name>Pair Mode</name>
    <key>is_pair</key>
    <value>True</value>
    <type>enum</type>
    <option>
      <name>False</name>
      <key>False</key>
    </option>
    <option>
      <name>True</name>
      <key>True</key>
    </option>
  </param>

  <param>
    <name>Static Mode</name>
    <key>is_static</key>
    <value>True</value>
    <type>enum</type>
    <option>
      <name>False</name>
      <key>False</key>
    </option>
    <option>
      <name>True</name>
      <key>True</key>
    </option>
  </param>

  <param>
    <name>Key</name>
    <key>key</key>
    <value></value>
    <type>string</type>
    <hide>#if $is_pair() == 'True' then 'none' else 'all'#</hide>
  </param>

  <param>
    <name>GUI Hint</name>
    <key>gui_hint</key>
    <value></value>
    <type>gui_hint</type>
    <hide>part</hide>
  </param>

  <!-- If both is_pair and is_static are True, we require a default key.
       If either or both are false, we don't care about a default key.
  -->
  <check>($is_pair and $is_static and len($key) &gt; 0) or not ($is_pair and $is_static)</check>

  <sink>
    <name>val</name>
    <type>message</type>
    <optional>1</optional>
  </sink>

  <source>
    <name>msg</name>
    <type>message</type>
    <optional>1</optional>
  </source>

  <doc>
The GUI hint can be used to position the widget within the application. \
The hint is of the form [tab_id@tab_index]: [row, col, row_span, col_span]. \
Both the tab specification and the grid position are optional.
  </doc>
</block>