1,847
edits
m (→uicontrols: Build a GUI in GNU Octave: Use syntax highlighter.) |
(Use URL without version.) |
||
(2 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
= uicontrols: Build a GUI in GNU Octave = | == uicontrols: Build a GUI in GNU Octave == | ||
You have to use the "qt" graphics toolkit (default since 4.0). For the best results GNU Octave version >= 4.2.x should be used. | You have to use the "qt" graphics toolkit (default since 4.0). For the best results GNU Octave version >= 4.2.x should be used. | ||
== | === Example 1: imageViewer === | ||
GUI which opens a file selection dialog when a button is pressed and views the selected image. | GUI which opens a file selection dialog when a button is pressed and views the selected image. | ||
Line 58: | Line 52: | ||
Then run <code>imageViewer()</code> from your terminal: | Then run <code>imageViewer()</code> from your terminal: | ||
=== demo_uicontrol === | === Example 2: demo_uicontrol === | ||
This example tries to show all available uicontrols (needs Octave >= 4.0 and qt): | This example tries to show all available uicontrols (needs Octave >= 4.0 and qt): | ||
Line 255: | Line 249: | ||
update_plot (gcf, true); | update_plot (gcf, true); | ||
</syntaxhighlight>}} | </syntaxhighlight>}} | ||
== See also == | |||
* [https://octave.org/doc/interpreter/GUI-Development.html GNU Octave manual -- GUI Development] | |||
[[Category:Examples]] | [[Category:Examples]] |