ScienceSoft, LLC

CHAPTER 12: Using the Workwindows

The NMRanalyst analysis of multidimensional spectra can be divided into four separate computing tasks: the analysis of one or more 1D spectra, the Fast Fourier Transform (FFT) of the multidimensional FID or import of a Fourier transformed spectrum, the spin system identification in the multidimensional spectrum, and the summary of obtained analysis results. Two further tasks are supported. AssembleIt provides the identification of best matching from millions of candidate structures (dereplication), verification of a specified structure, and combination of analysis results from several spectra and derivation of possible molecular skeletons. The other task is the graphic display of spectral plots and molecular structures. For all the tasks, the user can (1) specify input values for the task, (2) start and control the progress (pause/continue, background/foreground, and stop the task), and (3) examine the program output. The workwindow provides the input/output functionality using a consistent user interface. The NMRanalyst application provides the process control features for all the workwindows.

A workwindow can be displayed by clicking on the [1D Analysis], [2D FFT], [2D Analysis],1 [Report], [AssembleIt], and [Graphic] tabs in the NMRanalyst window. Each workwindow controls a separate program which can be run independently of other programs and even independently of the user interface.

The figure shows the NMRanalyst window with displayed nD Analysis workwindow. The workwindow area consists of an input screen at the top and an output screen at the bottom of the window. When the area of the workwindow input and output screens exceeds the workwindow display area, the horizontal and vertical scroll-bars can be used to scroll to the area of interest. Between the input and output screens is a sash (a separator line with a small rectangular button at the right side). To change the relative visible area of the input and output screens, drag2 the sash vertically as desired. When entering input values in the workwindow, the sash is normally at the bottom of the window, so only the input screen is visible. When computations are in progress, the sash is at the top of the window and the output screen is displayed. Besides using the sash, the [Input Screen]/[Output Screen] button at the top of the NMRanalyst window or the corresponding menu item can be used to switch between the two screens. See CHAPTER 9: "Using the NMRanalyst Window" for details.

12.1 The Workwindow Input Screen

The input screen allows the user to modify the input values for the computing task supported by the workwindow. The input values in the input screen are initially loaded from a corresponding "input value file". The workwindow updates this file as soon as the user changes input screen values. The following are the input value files corresponding to the six workwindows of the NMRanalyst application:

1D Analysis workwindow
FFT workwindow
nD Analysis workwindow
Report workwindow
AssembleIt workwindow
Graphic workwindow

An input value file contains the input screen values as a set of key-value pairs. The ".txt" file name ending stems from the fact that these are plain text files. The following examples explain the kinds of interface objects used in the input screens:

The above example contains three related interface objects (widgets). The button on the left describes the function of the input line and shows a History popup (described below) when clicked. The text field in the middle is used to enter one piece of information such as a number or file name (described below). The folder button at the right side of the example starts a Filebox allowing the interactive location of directories and files as described in CHAPTER 11: "Using the Filebox Popup".

The button with the text label in the previous figure displays the shown History popup when clicked. The history list in this popup shows from top (the oldest value) to bottom (the newest value) previous values of the text field. Any previous value can be selected, and the value is copied back to the input field when [OK] is clicked. The [Cancel] button removes the History popup without changing the text field content.

For input fields in the input screen, like the one in the previous example, the standard editing facilities are implemented. An input field can be edited by moving the mouse pointer to the desired character position and clicking the first (left) mouse button to give the input field the keyboard focus. Text entered from the keyboard is inserted at the current cursor position. The text cursor can be moved using the keyboard left and right arrow keys. The [Backspace] key can be used to erase the character before the text cursor. The following table describes the implemented additional control characters supported by workwindow input fields:

copy clipboard
cut clipboard
paste clipboard
backward one character
forward one character
kill next character
kill characters from cursor position to end of line
move cursor position to beginning of line
move cursor position to end of line
[Down Arrow]
show next history entry for the input field
[Up Arrow]
show previous history entry for the input field

Regions of text can be selected and used in the subsequent operations. Clicking on a word twice with the first (left) mouse button selects the word, clicking on text three times selects all text in the input field, and pressing the first (left) mouse button and moving the mouse with the button pressed (dragging) selects the corresponding text area. A selected area can be removed using the [Delete] key. The selected area can be copied to another input field, possibly in another workwindow, by first selecting the [Copy] item from the Edit pull-down menu, then clicking on the final destination with the first (left) mouse button, and finally selecting the [Paste] item from the Edit pull-down menu. All workwindow input screen text fields are limited to one line of text, and entered newline characters are ignored. All text input fields are scrollable horizontally and can hold at least 200 input characters independent of their displayed length.

Clicking the right mouse button above an input field with selected text brings up the shown popup menu. [Cut] removes the selected text and pastes it to the clipboard. [Copy] copies the selected text to the clipboard. [Paste] adds any text on the clipboard to this input field. [History...] brings up the history popup for this input field.

Most input fields request a numerical input value, and ignore entered characters which cannot be part of a valid number. If the final entry is not a valid number, the shown popup appears. [Restore] resets the input field to the last valid entry.

Some input fields expect a file name entry. These input fields have a folder button at the right side. When typing the [Space] key, NMRanalyst auto-completes the file name as long as the file name can be uniquely determined. Otherwise, a white space is inserted in the input field.

The workwindow input screen utilizes an option menu for choosing one item out of a fixed list of items. For example, the frequency unit can be chosen by clicking on the shown option button. When this button is clicked with the first (left) mouse button, the menu with the unit choices is displayed and the desired item can be selected.

For toggling between two possible states of an item, the workwindow input screen uses check boxes as shown. A check box is selected when the check symbol shows.

All input screen objects recognize their default setting. To guide the user's attention, all input screen objects with modified (non-default) values are shown in a color different from the default background color. [Make Default] in the Workwindow pull-down menu allows making the current settings of the input screen objects the default settings.

The NMRanalyst software comes with a complete set of default *.txt files for each supported spectrum type. These default files are used whenever the current $NMRDATA/$NMRSPEC directory does not contain an appropriate *.txt file. Upon the initial display of a workwindow, or a NMRDATA directory or a spectrum type change, the corresponding *.txt file is loaded automatically. The following popup should not be encountered if the NMRanalyst software is installed as described in CHAPTER 2: "NMRanalyst Installation". However, a user can supply modified *.txt default files and require the workwindow to use them by setting the NMRUSER shell variable appropriately. If *.txt files are missing from a modified spectrum specific NMRUSER directory, the following popup results:

Click [Cancel] or [Exit] (whichever button is displayed) to abort the load process. Check the Directory Editor NMRUSER and NMRSPEC variables. Either change the variables or copy the missing *.txt file into the $NMRUSER/$NMRSPEC directory.

The workwindow input screen keeps an unlimited history of previous input values. Should this information exceed 200 KBytes, the shown popup is displayed. [Clear History] deletes all history information for this input screen, and [Keep History] proceeds without deleting old input values.

If a NMRanalyst computing program is not available, this popup is shown. [OK] returns to NMRanalyst. See CHAPTER 2: "NMRanalyst Installation" for corrective actions.

12.2 The Workwindow Output Screen

The workwindow output screen is used to display the output of the running computation. During computation, the text displayed in the output screen is also written to a *.log file named according to the following table:

1D Analysis workwindow
FFT workwindow
nD Analysis workwindow
Report workwindow
AssembleIt workwindow
Graphic workwindow

Whenever a workwindow is selected, the corresponding *.log file from the previous analysis (if any) is automatically loaded into the output screen. When the computation of a workwindow is started, a previous *.log file is saved by appending .bck ("backup") to the old file name before writing the new *.log file. Changing between workwindows or exiting and restarting NMRanalyst does not alter the content of any workwindow input or output screen.

The shown popup is displayed if there is insufficient computer memory to load a *.log file into its corresponding workwindow. This file is automatically renamed by appending .bck to the original file name. [OK] removes the popup.

When a text region is selected in the output screen, clicking the right mouse button above the output screen brings up the shown popup menu. Selected text can be copied to the clipboard or printed by choosing [Copy Selection] or [Print Selection]. To select all text in the output screen, choose [Select All]. To print all text independent of selection state, choose [Print All].

12.3 The Workwindow File Locking

The shown popup is displayed if one copy of NMRanalyst tries to access a *.txt file already in use by another NMRanalyst program. Clicking [Cancel] or [Exit] aborts the action which led to this *.txt file conflict.

For interactive computing processes associated with a workwindow and for backgrounded computing processes, the corresponding *.log output file is kept locked while computations are in progress. A newly started workwindow reconnects to a running background process, if possible.

12.4 Summary of Workwindow File Usage

Each NMRanalyst workwindow is associated with three files. These files are automatically created and managed, and are stored in directory $NMRDIR/$NMRSPEC. The workwindow input screen values are stored in a *.txt file as described in SECTION 12.1: "The Workwindow Input Screen". The workwindow output screen information is saved in a corresponding *.log file as described in SECTION 12.2: "The Workwindow Output Screen". Whenever computations are started in a workwindow, the previous *.log file is renamed to *.log.bck and a new *.log file is created. All other files created by NMRanalyst are described in the subsequent workwindow reference chapters. The following figure shows the data flow of the NMRanalyst software:

1Button labels change depending on the dimensionality of the selected spectrum type (e.g., [2D Analysis], [3D Analysis]).

2Press the first (left) mouse button over the sash and move the mouse with the button pressed.

ScienceSoft, LLC