Windows Dynamics

GraphWorX64 uses a windows hierarchy to determine what you can do in the current or active window, how windows relate to one another, when windows require input before you can do something else in the program, or whether windows are independent entities. These behaviors affect program flow and actions, and are very valuable in creating and enforcing logic and behavior. For example, if you define a pop-up window to be modal, then that window has the focus of user action exclusively and does not allow interaction with other windows that are part of that display. You would use a modal window for an alert box or perhaps for a dialog box. If you define a pop-up window in a Load Display action that is independent of the current display, then a Close Window action applied to the parent window leaves the child window on the screen; whereas a pop-up window that is dependent on the parent window would be closed.

Window Types

The first place you might encounter window types is if you define a Pick Action that performs the Load Display command. The TargetType property shown in the figure below offers several different window types:

  • Current Display This assignment refers to the display that is currently active in the order in which displays were loaded. It is not a window type.
  • Popup Window (Display Dependent) A display dependent pop-up window appears as an individual window that you can manipulate and set the properties for, but one that closes when the display is closed.
  • Popup Windows (Display Dependent - Modal) This type of pop-up window appears as an individual window that you can move and manipulate. When it is open in the display it has the focus for user interaction. Other windows in the display cannot get the focus of user interaction  until the modal window is closed. You can only have one modal window opened on the screen at any one time for each display.
  • Popup Window (Window Dependent) A window dependent pop-up window can be moved and manipulated and have its properties set. It is not modal, and you can work in other windows while this pop-up is in view. However, when you close the parent window the window dependent pop-up closes at the same time.
  • Popup Window (Window Dependent -Modal) This type of pop-up window appears as an individual window that you can move and manipulate. When it is selected in the display it has the focus for user interaction for the parent window. Other windows in the display can get the focus of user interaction  if they are not related to the modal window. You can have one modal window opened for each unrelated window.
  • Popup Window (Independent) An independent pop-up window appears as an individual window that you can manipulate and set the properties for. You can close any window in the display or all other windows and still leave this window open. A close all windows command would close this window as well. When you close a display the independent window is closed.
  • Embedded Window An embedded window is a window contained within another window, and one that doesn't have an independent existence. If you move the embedded window within the parent the contents clips (a modifiable property) when the embedded window is dragged beyond the parent window's boundary. An embedded window can have its properties modified and can have windows elements, menus, and controls in view. The figure below shows an embedded window slightly clipped. ClosedView image

    Embedded windows are constrained within the parent window.

  • Parent Window This is the window that creates the window.
  • Root Window This is the first windows shown in a display from which all other windows are created.
  • New Instance (Separate Process) is a new instance of the same window.
  • Any Named Window is any window name in the TargetName property.
 

The Load Display Command's TargetType Property

Different windows types are defined in the TargetType property.

The TargetType parameter is used in conjunction with the TargetName parameter to designate which type of display window to open.

If Target Type Parameter is...

Than...

Self

TargetName is unused. The current (default) window loads the display.

WindowOwnedPopup

  • If TargetName is specified, a pop-up window matching that name (and is owned by the current window) loads display into that pop-up window.
  • If TargetName is NOT specified, the display is loaded into a new unnamed pop-oup window.

DisplayOwnedPopup

Same as WindowOwnedPopup except the pop-up is owned by the display, meaning that if a new display is loaded in a given window, all pop-ups owned by the display that is being replaced automatically close.

DisplayOwnedModalPopup

Same as DisplayOwnedPopup except the pop-up is modal and disables parent window.

WindowOwnedModalPopup

Same as WindowOwnedPopup except the pop-up is modal and disables parent window.

UnownedPopup

Same as WindowOwnedPopup except the pop-up is "unowned" (owned by the desktop). Unowned pop-ups do not necessarily stay above the window that opened them. Unowned pop-ups remain open even if the display is changed in the window that opened them. Unowned pop-ups are automatically closed when the root window exits runtime or is closed.

Embedded

Same as DisplayOwnedPopup except the window is an embedded child of its parent.

Parent

  • If TargetName is specified and there is a parent window that matches that name, the display is loaded into that parent window.
  • If TargetName is specified and there is NOT a parent window in the parent chain matching that name, the behavior is the same as Self. Also, if there is parent window, the behavior is the same as Self.

Root

TargetName is unused— display is loaded into the topmost (root) parent window in the parent chain, or if there is no parent parent window, the behavior is the same as Self.

Window Stack

As windows are opened in a GraphWorX64 display the program maintains a list of the last 50 windows names and order they were used in a buffer. Windows are ordered from first to last, with the selected window being the current window and the first window being the root window. As you click the GraphWorX64 Browse forward or Browse back buttons in the display you move through the order that you viewed the windows as maintained in the buffer. The display file history (forward or back commands) remembers the initial alias settings specified when a display is opened and will reset those aliases when you go back to that display in the file history.  Therefore, there are three different windows properties that you need to consider when you want to predict the result of a user action on the currently displayed windows:

  • Windows type (modal vs. non modal).
  • Windows relationship to other windows (parent vs. child, dependent vs. independent vs. embedded, and so forth).
  • Windows Display Order or the position of the window in the Browse order.

 

See also: