New article: Graphical Interfaces I: Form for Controls (Chapter 2)

Back to topics list To post a new topic, please log in or register
avatar
Moderator
72408
MetaQuotes 2016.02.08 11:18
 

New article Graphical Interfaces I: Form for Controls (Chapter 2) has been published on mql5.com:

This article is the continuation of the first part of the series about graphical interfaces. The first article Graphical Interfaces I: Preparation of the Library Structure (Chapter 1) considers in detail what this library is for. A full list of the links to the articles of the first part is at the end of each chapter. There you can also find and download a complete version of the library at the current stage of development. The files must be located in the same directories as in the archive.

In the previous chapter we discussed a library structure for creating graphical interfaces. There (1) derived classes for primitive objects, (2) a base class for all controls, (3) principle classes for storing control pointers and managing those controls in the common event handler were created.

In this article we shall create the first and main element of the graphical interface — a form for controls. Multiple controls can be attached to this form anywhere and in any combination. The form will be movable and all controls attached to it will be moved together with it.

What parts will constitute the window that we are going to create?

  1. Background. All the controls will be located in this area.
  2. Header. This part enables moving the window and contains the interface controls listed below.
  3. Icon. Additional attributes for visual identification.
  4. Caption. Window name.
  5. The "Tooltip" button. Pressing this button enables the mode of showing control tooltips where they are present.
  6. Button for minimizing/maximizing the window.
  7. Button for closing the window.

Fig. 1. Compound parts of the form for controls

Fig. 1. Compound parts of the form for controls

Author: Anatoli Kazharski

avatar
249
4evermaat 2016.02.09 04:24 #
 
Does this work 100% on MT4?  Or is this only limited to mt5?
Back to topics list  

To add comments, please log in or register