summaryrefslogtreecommitdiff
path: root/grc/blocks/wxgui_scopesink2.xml
diff options
context:
space:
mode:
authorjblum2009-07-06 02:28:52 +0000
committerjblum2009-07-06 02:28:52 +0000
commit25c5d91fb7c4b54f1e7d77fd9af213a3675a8339 (patch)
tree317d2e623aa9de602197089dab6dcc4fbb17da6f /grc/blocks/wxgui_scopesink2.xml
parenta6396abe127c504f890d0cd45171c46ebfbb0f3d (diff)
downloadgnuradio-25c5d91fb7c4b54f1e7d77fd9af213a3675a8339.tar.gz
gnuradio-25c5d91fb7c4b54f1e7d77fd9af213a3675a8339.tar.bz2
gnuradio-25c5d91fb7c4b54f1e7d77fd9af213a3675a8339.zip
Merged r11309:11357 from grc branch.
Adds notebook cabability to grc and its wxgui windows/controls. git-svn-id: http://gnuradio.org/svn/gnuradio/trunk@11358 221aa14e-8319-0410-a670-987f0aec2ac5
Diffstat (limited to 'grc/blocks/wxgui_scopesink2.xml')
-rw-r--r--grc/blocks/wxgui_scopesink2.xml20
1 files changed, 14 insertions, 6 deletions
diff --git a/grc/blocks/wxgui_scopesink2.xml b/grc/blocks/wxgui_scopesink2.xml
index 78c39f80d..503d52972 100644
--- a/grc/blocks/wxgui_scopesink2.xml
+++ b/grc/blocks/wxgui_scopesink2.xml
@@ -9,8 +9,9 @@
<key>wxgui_scopesink2</key>
<import>from gnuradio.wxgui import scopesink2</import>
<import>from gnuradio import gr</import>
- <make>scopesink2.$(type.fcn)(
- self.GetWin(),
+ <make>#set $parent = $notebook() and 'self.%s.GetPage(%s)'%$notebook() or 'self'
+scopesink2.$(type.fcn)(
+ $(parent).GetWin(),
title=$title,
sample_rate=$samp_rate,
v_scale=$v_scale,
@@ -19,11 +20,10 @@
xy_mode=$xy_mode,
num_inputs=$num_inputs,
)
-#set $grid_pos = $grid_pos()
-#if not grid_pos
-self.Add(self.$(id).win)
+#if not $grid_pos()
+$(parent).Add(self.$(id).win)
#else
-self.GridAdd(self.$(id).win, $grid_pos[0], $grid_pos[1], $grid_pos[2], $grid_pos[3])
+$(parent).GridAdd(self.$(id).win, $(', '.join(map(str, $grid_pos()))))
#end if</make>
<callback>set_sample_rate($samp_rate)</callback>
<param>
@@ -108,6 +108,12 @@ self.GridAdd(self.$(id).win, $grid_pos[0], $grid_pos[1], $grid_pos[2], $grid_pos
<value></value>
<type>grid_pos</type>
</param>
+ <param>
+ <name>Notebook</name>
+ <key>notebook</key>
+ <value></value>
+ <type>notebook</type>
+ </param>
<check>not $xy_mode or '$type' == 'complex' or $num_inputs != 1</check>
<sink>
<name>in</name>
@@ -122,5 +128,7 @@ Set the T Scale to 0 for automatic setting.
XY Mode allows the scope to initialize as an XY plotter.
Use the Grid Position (row, column, row span, column span) to position the graphical element in the window.
+
+Use the Notebook Param (notebook-id, page-index) to place the graphical element inside of a notebook page.
</doc>
</block>