Understanding windows docking system

There are two main types (classes) of windows within the main CandleScanner window: documents windows and tool windows, shown in Figure 1. They are used for different purposes. Document windows are mainly used to present some content in CandleScanner like candlestick charts, statistics or candlestick pattern dictionary. Tool windows are more auxiliary in nature and in CandleScanner are used mainly to change the current content(s) in the document window or to change the content of other tool windows. Both types have separate types of containers within which they can be docked.

Figure 1.

Figure 1. Displayed are the tool windows (green rectangle) and document windows (red rectangle). Windows from the green area can be docked in the red rectangle, but the opposite is not possible (i.e. document windows cannot be docked in the tools container).

The container is just a place in which a specific window can be docked (placed).
The Container for tool windows can contain only tool windows. However, the document container can contain both, namely, the document and tool windows.
This means, for example, that the Symbols window (which is of type tool window) can be docked in the documents container, along with other documents like, for example, candlestick charts. The reverse is not possible, however.

For example, when in CandleScanner there is a document window open with a candlestick chart, and we can click on the tool window and select different symbols from the list. By doing this, the document window with the candlestick chart will reload the content to display data for the newly selected symbol. If, however, the currently opened document is of a different type, for example containing a Patterns Dictionary, then clicking on the same list of symbols in the tool window would not change anything. This is because not all documents have to be connected with tool windows – candlestick Patterns Dictionary is an example. No matter what symbol is selected in the tool window with symbols, the document with the dictionary stays the same.

Clicking on the tool window can have an impact on the content of another tool window. In CandleScanner, for example, there is a tool window with a list of symbol groups (e.g. S&P 500) and another one with symbols belonging to the specific group. Changing different symbol group from the list reloads the list of symbols and displays symbols from the newly selected group. This mechanism is presented in the Figure 2.

Figure 2.

Figure 2. Clicking on the S&P 500 item in the Groups tool window causes the reloading of the S&P 500 components in the Symbols tool window, which then displays the S&P 500 components (symbols), as shown.

Another difference between document windows and tool windows is in the way they can be managed within CandleScanner. Because tool windows are auxiliary they can be pinned opened or unpinned and then auto-hidden (i.e. collapsed against the nearest side of the tool window container). When there are any hidden tool windows (i.e. unpinned), there is a so-called auto-hide tool tab strip visible. The Auto-hide tool tab strip contains all the hidden windows in minimized form, displaying just their names without the content. Clicking on them expands the hidden window. When the mouse is not hovered over the unpinned tool window, it will minimize, automatically, into the auto-hide tool tab strip again. This can be very helpful because it may happen that we want to have more working space to display, for example, a document window with candlestick charts. Hidden (unpinned) tool windows can be pinned if we want to them to be always visible.

Differences in the behavior of the document windows vs. tool windows are also reflected in their context menus. Document window has commands for closing windows, creating new horizontal and vertical tab groups and for moving windows between groups. Tool window context menu has commands that allow the panel to be Floating, Dockable (causes the panel to dock) or Tabbed Document. If Tabbed Document is selected, the tool window becomes hosted in a tab strip container along with the tabbed documents. Auto Hide causes the panel to be unpinned and collapsed. Hide makes the panel invisible.

The anatomy of the windows management system in CandleScanner is shown in the Figure 3. Some of the components presented in that figure are described in the subsequent subsections.

Figure 3.

Figure 3. Anatomy of CandleScanner windows. Tool windows are in green rectangles (called tool tab strips). In the yellow rectangle, there is a document window container which is divided by a splitter bar (violet line). We can see two document tab strips (red rectangles). Tool windows can be docked on the document window container, but the opposite is not possible. The blue rectangle is used for auto-hiding tool windows.

Comments are closed.