//------------------------------------------------
//--- 010 Editor v4.0 Binary Template
//
//      File: Inspector.bt
//   Authors: SweetScape Software
//   Version: 1.2
//   Purpose: This template may be used 
//            to customize the auto tab of the 
//            Inspector with your own variables. 
//            See the Inspector section of the 
//            Options dialog for more information. 
//  Category: Inspector
//   History: 
//   1.2   2017-10-12 SweetScape: Added time64_t data type. Commented out Unicode. Updated header.
//   1.1   SweetScape: Added hfloat data type.
//   1.0   SweetScape: Initial release.
//------------------------------------------------
RequiresVersion( 9.0 );

// Calculate the position for each variable,
//  either at the beginning of the selection
//  or at the current cursor position.
local int64 pos;
if( GetSelSize() > 0 )
    pos = GetSelStart();
else
    pos = GetCursorPos();

// Define variables for the inspector
FSeek( pos ); byte     _si8  <name="Signed Byte">;
FSeek( pos ); ubyte    _ui8  <name="Unsigned Byte">;
FSeek( pos ); short    _si16 <name="Signed Short">;
FSeek( pos ); ushort   _ui16 <name="Unsigned Short">;
FSeek( pos ); int      _si32 <name="Signed Int">;
FSeek( pos ); uint     _ui32 <name="Unsigned Int">;
FSeek( pos ); int64    _si64 <name="Signed Int64">;
FSeek( pos ); uint64   _ui64 <name="Unsigned Int64">;
FSeek( pos ); float    _f    <name="Float">;
FSeek( pos ); double   _d    <name="Double">;
FSeek( pos ); hfloat   _hf   <name="Half Float">;
FSeek( pos ); char     _s [ReadStringLength(pos,256)]  <name="String">;  // limit to 256 characters
//FSeek( pos ); wchar_t  _ws[ReadWStringLength(pos,256)] <name="Unicode">; // limit to 256 characters - uncomment to enable
FSeek( pos ); DOSDATE  _dd   <name="DOS Date">;
FSeek( pos ); DOSTIME  _dt   <name="DOS Time">;
FSeek( pos ); FILETIME _ft   <name="FILETIME">;
FSeek( pos ); OLETIME  _ot   <name="OLETIME">;
FSeek( pos ); time_t   _tt   <name="time_t">;
FSeek( pos ); time64_t _tt64 <name="time64_t">;
