In #6888 the colors that indicate the type of each field in the
block properties were replaced by labels, because colors can give
contrast problems, specially in dark mode. I personally find colors
useful, because they help me to identify quickly the field that I
want to edit (perhaps I'm just too used to having colors).
This commit adds the field colors back, but only as an optional
feature controlled by an entry in the View menu. This setting is
saved to the GRC preferences, and it defaults to colors disabled.
Users that prefer colors can simply enable the old behavior in this
menu entry.
The new labels to the right of each field that indicate the field
type are always shown, regardless of whether field colors are enabled.
Even when colors are shown, the labels can be a useful reminder of
what type each color stands for, and they don't use too much screen
real state.
Signed-off-by: Daniel Estévez <daniel@destevez.net>
This allows connections (graph edges) to have properties associated with
them. In order to do so, the edge types must have parameters associated
with them in the *.domain.yml file.
For edges that have properties/parameters associated with them,
a property dialog can be summoned by right-clicking a connector arrow.
Signed-off-by: Martin Braun <martin.braun@ettus.com>
Each time File -> Open Recent is used on Windows, the number of
backslashes in the filename doubles. This happens because a GLib.Variant
object is passed through str(), which produces a quoted (and escaped)
string. The quotes are then removed, but the escaping remains. The
underlying string can instead be accessed using the get_string() method.
See https://xkcd.com/1638/ for further details. ;)
Signed-off-by: Clayton Smith <argilo@gmail.com>
fixes#4788fixes#5100fixes#5108
Tested with the coresponding examples.
Now disabling or deleting the symbol_rate block in #4788 correctly
updates the depending blocks
Signed-off-by: Volker Schroer <3470424+dl1ksv@users.noreply.github.com>
This code belongs in MainWindow and not Application since the menu is
created in there. Additionally the commented-out code block below it
can also come out.
Signed-off-by: Mark Pentler <tehhustler@hotmail.com>
The gr-digital/examples/tx_ofdm.grc fails to evaluate the
header_formater variable.
This pr fixes#4937
Signed-off-by: Volker Schroer <3470424+dl1ksv@users.noreply.github.com>
Fixes#4781. When a variable is controlled by another variable,
updating the latter does not update the former in the flowgraph when
`Ok` is pressed. Caused by commit c4f46bf. This commit patches the bug.
Signed-off-by: Solomon Tan <solomonbstoner@yahoo.com.au>
Make all ports follow the `vlen` of their master port the same way it is
for `dtype`. Fixes#4634.
Signed-off-by: Solomon Tan <solomonbstoner@yahoo.com.au>
1. Add option to show variable name only
2. Add option to show variable name and value
3. default to traditional behavior
Signed-off-by: Jason Uher <jason.uher@jhuapl.edu>
Saves the grc prefs before executing a flowgraph to avoid losing them if
anything goes wrong and grc needs to be forcibly closed.
Also fixes recent files sub-menu refresh. When a file is opened, opened
from recent, or saved as, the recent files sub-menu is now updated.
When the modify parameters dialog block is constructed, the instance of
the block to be modified, is passed in. When the apply button is clicked
there is an extraenous flowgraph.import_data() call that re-creates all
blocks in the flowgraph. The consequence is that the block instance
passed to the dialog box is no longer the one in the flowgraph, and so
subsequent Applies have no effect. This change simply removes this call.
All of the removed `from __future__ import` were needed in older
versions of Python (mostly 2.5.x and below) but later became mandatory
in most versions of Python 3 hence are not necessary anymore.
More specifically, according to __future__.py[1]:
- unicode_literals is part of Python since versions 2.6.0 and 3.0.0;
- print_function is part of Python since versions 2.6.0 and 3.0.0;
- absolute_import is part of Python since versions 2.5.0 and 3.0.0;
- division is part of Python since versions 2.2.0 and 3.0.0;
Get rid of those unnecessary imports to slightly clean up the codebase.
[1] https://github.com/python/cpython/blob/master/Lib/__future__.py
Addresses the issue of losing access to the block id on many/most blocks
though there are scenarios where you may need to see them in GRC
Added a menu item tied into the grc prefs that will show the block ids
Fixes#2780
Bus ports had not been added back in since the refactor of grc
Hopefully this fully enables busports though there are still some
issues with the gr-fec flowgraphs
Fixes#2277
grc does not initialize the visibility of disabled blocks.
This sometimes leads to stranges effects.
Toggling the visibility does not update the flowgraph. So this take effect not until a change
to the flowgraph is made that forces an update of the flowgraph.
On a parameter change of block , the block will not be updated correctly.
Example:
Open a new Flowgraph tab.
Add an math add block. The default of the io ports is complex.
Open the property dialog and change the type of the io ports from complex to float and select OK.
Only the first input and the output port change from 'complex' to 'float'. The second input port remains 'complex'.
The only way to change the type of the second input port is to reopen the property dialog and select quit !!!!
Now the second port has the correct type.
The proposed change fixes this issue. But I'm not sure if there isn't a more elegant way to handle this issue.