QT GUI Toggle Switch: Difference between revisions

From GNU Radio
Jump to navigation Jump to search
No edit summary
No edit summary
 
Line 4: Line 4:


This button also will produce a state message matching the set values.<br>
This button also will produce a state message matching the set values.<br>


== Parameters ==
== Parameters ==

Latest revision as of 16:01, 24 October 2021

Added in 3.9

This block creates a modern toggle switch. The variable will take on one value or the other as set in the dialog.

This button also will produce a state message matching the set values.

Parameters

(R): Run-time adjustable

Label
the name for the toggle switch.
Label Position
options: [Left, Right]
Type
options: [Float, Integer, String, Boolean]
Default Value
initial value (default: 0)
Initial State
options: [Released, Pressed]
On Value
default: 1
Off Value
default: 0
Message Property Name
default: value
Switch On Background
options: [silver, gray, black, white, red, green, blue, navy, yellow, orange, purple, lime, aqua, teal]
switchOffBackground
see above
Cell Alignment
options: [Center,Left,Right]
Vertical Alignment
options: [Center,Top,Bottom]

See GUI Hint for how to position the GUI within a window.

Example Flowgraph

This flowgraph can be found at [1]

Test toggleswitch fg.png

Example Output

This flowgraph can be found at [2]

Test toggleswitch2 out.png

Source Files

C++ files
TODO
Header files
TODO
Public header files
TODO
Block definition
TODO