-
Notifications
You must be signed in to change notification settings - Fork 0
/
DFMLoadWave_v2.r
357 lines (334 loc) · 7.04 KB
/
DFMLoadWave_v2.r
1
#include "XOPStandardHeaders.r"resource 'vers' (1) { /* XOP version info */ 0x01, 0x00, final, 0x00, 0, /* version bytes and country integer */ "1.00", "1.00, Copyright 1993-2013 WaveMetrics, Inc., all rights reserved."};resource 'vers' (2) { /* Igor version info */ 0x06, 0x20, release, 0x00, 0, /* version bytes and country integer */ "6.20", "(for Igor 6.20 or later)"};resource 'STR#' (1101) { // Misc strings that Igor looks for. { /* [1] */ "-1", // This item is no longer supported by the Carbon XOP Toolkit. /* [2] */ "---" , // This item is no longer supported by the Carbon XOP Toolkit. /* [3] */ "DFMLoadWave Help", // Name of XOP's help file. }};// Description of menu items added to built-in Igor menus.resource 'XMI1' (1100) { { 50, // Add item to menu with ID=50 (Load Waves menu). "Load DFM Binary File...", // This is text for added menu item. 0, // This item has no submenu. 0, // Flags field. }};/* Balloon strings for "Load DFM Binary File..." item */resource 'STR#' (1110, "Load DFM Binary File...") { { /* [1] (used when menu item is enabled) */ "Loads data from various kinds of binary files into Igor waves.\n\n" "This can load 16 or 32 bit integer and 32 or 64 bit IEEE floating point binary data, " "providing that you can tell it precisely how data is stored in the file.", /* [2] (used when menu item is disabled) */ "", /* item is never disabled */ /* [3] (used when menu item is checked) */ "", /* item is never checked */ /* [4] (used when menu item is marked) */ "", /* item is never marked */ }};resource 'STR#' (1100) { /* custom error messages */ { /* [1] */ "This is not a DFM binary file", /* [2] */ "There is no data in file", /* [3] */ "Expected name of general binary file", /* [4] */ "Expected base name for new waves", /* [5] */ "Expected file type", /* [6] */ "Too many file types (4 allowed)", /* [7] */ "Data length in bits must be 8, 16, 32 or 64", /* [8] */ "Number of arrays must be >= 1", /* [9] */ "File contains too few bytes for specified number of bytes/point, points and arrays", /* [10] */ "Bad data type value", /* [11] */ "DFMLoadWave requires Igor version 5.00 or later", /* [12] */ "Valid floating point formats are 1 (IEEE) and 2 (VAX)" }};resource 'XOPI' (1100) { XOP_VERSION, // XOP protocol version. DEV_SYS_CODE, // Development system information. 0, // Obsolete - set to zero. 0, // Obsolete - set to zero. XOP_TOOLKIT_VERSION, // XOP Toolkit version.};resource 'XOPC' (1100) { { "DFMLoadWave", /* name of operation */ XOPOp+UtilOP+compilableOp, /* operation's category */ }};resource 'ALRT' (1258, purgeable) { {88, 62, 250, 390}, 1258, { /* array: 4 elements */ /* [1] */ OK, visible, silent, /* [2] */ OK, visible, silent, /* [3] */ OK, visible, silent, /* [4] */ OK, visible, silent }, noAutoCenter};resource 'DITL' (1258) { { /* [1] */ {124, 10, 146, 56}, Button { enabled, "OK" }, /* [2] */ {5, 97, 21, 243}, StaticText { disabled, "DFMLoadWave Error" }, /* [3] */ {50, 90, 115, 340}, StaticText { disabled, "^0" }, }};resource 'dlgx' (1260, "Load DFM Binary") { versionZero { kDialogFlagsUseThemeBackground | kDialogFlagsUseControlHierarchy | kDialogFlagsUseThemeControls | kDialogFlagsHandleMovableModal }};resource 'CNTL' (1101, "Data Path Popup Menu", purgeable) { {62, 111, 82, 261}, 0, // Title constant. visible, 0, // Width of title in pixels. -12345, // MENU resource ID; MUST BE -12345! kControlPopupButtonProc | kControlPopupFixedWidthVariant, // CDEF ID 0, // Refcon "" // Title};resource 'CNTL' (1102, "DFM Path Popup Menu", purgeable) { {31, 111, 51, 261}, 0, // Title constant. visible, 0, // Width of title in pixels. -12345, // MENU resource ID; MUST BE -12345! kControlPopupButtonProc | kControlPopupFixedWidthVariant, // CDEF ID 0, // Refcon "" // Title};resource 'CNTL' (1103, "Byte Order Popup Menu", purgeable) { {96, 111, 116, 259}, 0, // Title constant. visible, 0, // Width of title in pixels. -12345, // MENU resource ID; MUST BE -12345! kControlPopupButtonProc | kControlPopupFixedWidthVariant, // CDEF ID 0, // Refcon "" // Title};resource 'CNTL' (1105, "Command Box") { {312, 12, 332, 576}, 0, visible, 0, 0, kControlGroupBoxTextTitleProc, 0, ""};resource 'CNTL' (1107, "Input Group Box") { {8, 12, 195, 576}, 0, visible, 0, 0, kControlGroupBoxTextTitleProc, 0, "Input File"};resource 'CNTL' (1108, "Output Group Box") { {201, 12, 303, 576}, 0, visible, 0, 0, kControlGroupBoxTextTitleProc, 0, "Output Waves"};resource 'DLOG' (1260) { {50, 30, 430, 620}, movableDBoxProc, invisible, noGoAway, 0x0, 1260, "Load DFM Binary", noAutoCenter};resource 'DITL' (1260) { /* Main dialog */ { /* array DITLarray: 21 elements */ /* [1] */ {347, 12, 367, 82}, Button { enabled, "Do It" }, /* [2] */ {347, 506, 367, 576}, Button { enabled, "Cancel" }, /* [3] */ {347, 97, 367, 211}, Button { enabled, "To Cmd Line" }, /* [4] */ {347, 227, 367, 307}, Button { enabled, "To Clip" }, /* [5] */ {312, 12, 332, 576}, Control { enabled, 1105 }, /* [6] */ {347, 420, 367, 490}, Button { enabled, "Help" }, /* [7] */ {8, 12, 195, 576}, Control { // Input Group Box enabled, 1107 }, /* [8] */ {31, 28, 49, 100}, StaticText { // dfm path label enabled, "DFM Path:" }, /* [9] */ // dfm path popup. {31, 111, 51, 261}, Control { enabled, 1102 }, /* [10] */ // dfm path button {32, 271, 52, 341}, Button { enabled, "File..." }, /* [11] */ // dfm path text {34, 352, 51, 561}, StaticText { enabled, "Static Text" }, /* [12] */ // byte order label {97, 29, 115, 106}, StaticText { enabled, "Byte Order:" }, /* [13] */ // byte order popup. {96, 111, 116, 259}, Control { enabled, 1103 }, /* [14] */ // data path label {61, 31, 80, 100}, StaticText { enabled, "Data Path:" }, /* [15] */ // data path popup {62, 111, 82, 261}, Control { enabled, 1101 }, /* [16] */ // data path btton {62, 270, 82, 340}, Button { enabled, "File..." }, /* [17] */ // data path text {66, 351, 83, 560}, StaticText { enabled, "Static Text" }, /* [18] */ // output group box {201, 12, 303, 576}, Control { enabled, 1108 }, /* [19] */ // overwrite check box {261, 31, 281, 220}, CheckBox { enabled, "Overwrite existing waves" }, /* [20] */ // sample time label {264, 319, 280, 394}, StaticText { enabled, "Sample Time:" }, /* [21] */ // sample time edit box {264, 414, 280, 489}, EditText { enabled, "" }, /* [22] */ // c-string check box {221, 31, 242, 245}, CheckBox { enabled, "Treat char fields as c-strings" }, }};