diff options
author | Josh Blum | 2011-03-07 18:40:57 -0800 |
---|---|---|
committer | Josh Blum | 2011-03-07 18:40:57 -0800 |
commit | 9121b75d68a0c90deee814edffe387480b52019b (patch) | |
tree | 566b418847c51ce97997547fd261f201b50f89be /grc | |
parent | 51bcf966e09e15bd97822608b236f02fd379ea87 (diff) | |
download | gnuradio-9121b75d68a0c90deee814edffe387480b52019b.tar.gz gnuradio-9121b75d68a0c90deee814edffe387480b52019b.tar.bz2 gnuradio-9121b75d68a0c90deee814edffe387480b52019b.zip |
qtgui-grc: minor tweaks to the various things
Diffstat (limited to 'grc')
-rw-r--r-- | grc/blocks/variable_function_probe.xml | 7 | ||||
-rw-r--r-- | grc/python/flow_graph.tmpl | 1 |
2 files changed, 6 insertions, 2 deletions
diff --git a/grc/blocks/variable_function_probe.xml b/grc/blocks/variable_function_probe.xml index 49f48fc89..269966c70 100644 --- a/grc/blocks/variable_function_probe.xml +++ b/grc/blocks/variable_function_probe.xml @@ -13,7 +13,9 @@ <make>#slurp def _$(id)_probe(): while True: - self.set_$(id)(self.$(block_id()).$(function_name())($(function_args()))) + val = self.$(block_id()).$(function_name())($(function_args())) + try: self.set_$(id)(val) + except AttributeError, e: pass time.sleep(1.0/($poll_rate)) _$(id)_thread = threading.Thread(target=_$(id)_probe) _$(id)_thread.daemon = True @@ -57,7 +59,8 @@ Set the values for block ID, function name, and function args appropriately: \ Block ID should be the ID of another block in this flow graph. \ Function name should be the name of a class method on that block. \ Function args are the parameters passed into that function. \ -For a function with no arguments, leave function args blank. +For a function with no arguments, leave function args blank. \ +When passing a string for the function arguments, quote the string literal: '"arg"'. The values will used literally, and generated into the following form: self.block_id.function_name(function_args) diff --git a/grc/python/flow_graph.tmpl b/grc/python/flow_graph.tmpl index 070ad7ed1..1aea58838 100644 --- a/grc/python/flow_graph.tmpl +++ b/grc/python/flow_graph.tmpl @@ -235,6 +235,7 @@ if __name__ == '__main__': #elif $generate_options == 'qt_gui' qapp = Qt.QApplication(sys.argv) tb = $(class_name)($(', '.join($params_eq_list))) + tb.setWindowTitle("$title") #if $flow_graph.get_option('run') tb.start() #end if |