User Guide

Advanced GUI Editing
Drawing
This section describes how to draw using the GUI components. With the introduction of the Ruby component you can now also draw using
Ruby code. This is now the recommended way of drawing in FlowBotics Studio. For more details see the Drawing section in the Ruby
Component chapter.
Drawing on a Panel
Drawing on a front panel is a simple matter of picking a drawing primitive and connecting the View output of the MGUI to the View input of
the primitive.
All the drawing primitives can be found by selecting the GUI filter group. There are primitives for drawing lines, rectangles, text, bitmaps and
more.
The example below shows how to draw a simple filled rectangle. We've used a little shortcut to specify the Area for the rectangle. This makes
use of a string component to specify the x,y,width and height that define the Area. The colour is defined using the colour component.
Drawing Order
Often you'll be drawing more than one element on a front panel. If two elements overlap then the one that is last in the link order will be
displayed last and therefore over the top of the other element.
The example below shows this. The orange rectangle is on the second link from the MGUI (see Links for more on link order). The orange
rectangle will therefore be drawn on top of the red one.
90 of 212