Discussion of article "DoEasy. Controls (Part 28): Bar styles in the ProgressBar control"

 

New article DoEasy. Controls (Part 28): Bar styles in the ProgressBar control has been published:

In this article, I will develop display styles and description text for the progress bar of the ProgressBar control.

Currently, the ProgressBar control created for the library has a single progress bar display style — a continuous line (Continuous). But such a control has two more display styles - segmented blocks (Blocks) and continuous scrolling of a block in an object (Marquee). The Blocks style is pretty clear (a continuous line is replaced with separately located blocks). The Marquee style can be used if the number of iterations that need to be visually displayed using the ProgressBar control is not known in advance. In this case, a single block equal to half the width of the progress bar will constantly scroll. 

In addition to creating these two new styles, I will add a text to the progress bar to be displayed inside. The text itself will be represented by a regular object of the CLabel class of the library, and it will be bound not to the progress bar object, but to the underlay object, which is the base of the ProgressBar control. The text will be rendered inside a fully transparent text label object sized to the width and height of the progress bar. This object will always be in the foreground - above all objects in the ProgressBar control.

Compile the EA and launch it on the chart:


As we can see, all the declared modes work well.

Author: Artyom Trishkin

Reason: