Before adding a structure, you must select a Structure Library. If you do not have a Structure Library selected, do this now. For help on selecting a Structure Library, please see Structure Libraries.

 

 

The Add Structure dialog can be invoked either by using the keycut Ctrl+L, by right-clicking on the Context menu and selecting "Add Structure" from the Structure Viewer, by pressing the "+" button on the Structure Viewer Window, or by selecting "Add Structure" from the "Tools:Structure Viewer" menu.

 

After you have selected a structure from the Structure Library located on the left of the dialog, select desired options, and then press OK button. Options are described below.

 

Floating Structure

 

A floating structure is not locked to a specific document or fixed to a specific address/offset. Moving your cursor around a document and changing the document focus will force a floating structure to recalculate and re-render all of it's data elements given the new document and/or offset. This is very useful when searching for structures within documents.

 

Locked document/offset

 

A locked structure is locked to a specific offset within document. The document will recalculate and re-render it's data elements whenever the structure is refreshed. Closing and reopening the root data element is one method of refreshing a structure. Locked structures are automatically removed when the document it is locked to is closed.

 

Document

 

If adding a locked structure, you must select a document to anchor the structure to. By default, Hex Workshop fills in the in-focus document.

 

Offset

 

If adding a locked structure, you must select an offset to anchor the structure to. By default, Hex Workshop fills in the cursor offset of the in-focus document.

 

Byte Order

 

If your structure contains integer or floating point values, then you may need to specify the byte order used to interpret the data values. You can select either Big Endian (Motorola) or Little Endian (Intel).

 

The byte order control is disabled when a byte order is specified in the structure definition using a #pragma byteorder directive.  

 

See also Structure Viewer Overview, Removing a Structure, Defining a Structure and Basic Structure Data Types.