MacLua5.3/Sources/lua_compiler.r

1 line
No EOL
2 KiB
R

#include "Types.r"
#include "BalloonTypes.r"
#include "Cmdo.r"
resource 'hfdr' (-5696, purgeable) {
HelpMgrVersion,
hmDefaultOptions,
0, // Default balloon definition function
0, // Default variation code
{
HMSTRResItem
{
128 // Resource ID of help string ('STR ') to display
}
}
};
resource 'STR ' (128, purgeable) {
"This is an MPW tool. It requires the Macintosh Programmer's Workshop to run.\n\n"
"This tool allows you to precompile Lua scripts from within MPW."
};
resource 'cmdo' (128) {
{
230, // height of dialog
"Allows you to precompile Lua chunks from within MPW.", // help text
{
// #1
notDependent {}, CheckOption {
NotSet,
{25, 20, 40, 115},
"Print listing",
"-l",
"Writes a detailed bytecode listing to standard output.",
},
// #2
Or { { 1 } }, CheckOption {
NotSet,
{25, 120, 40, 160},
"Full",
"-l",
"Writes even more information, including information about constants and upvalues.",
},
// #3
And { { -5 } }, CheckOption {
NotSet,
{25, 185, 40, 460},
"Strip debug information",
"-s",
"Removes the debugging information from the resulting chunk. This results in smaller filesize.",
},
// #4
And { { -5, 6 } }, Files {
OutputFile,
RequiredFile {
{70, 20, 90, 460},
"Choose output path…",
"-o",
"Chooses where to save the compiled result.",
},
NoMore {}
},
// #5
notDependent {}, CheckOption {
NotSet,
{95, 20, 115, 460},
"Do not save output (parse only)",
"-p",
"Checks syntax and optionally produces a listing, but does not save the compiled chunk."
},
// #6
notDependent { }, Files {
InputFile,
RequiredFile {
{45, 20, 65, 460},
"Choose script to compile…",
"",
"Chooses the script that will be compiled.",
},
Additional {
"",
".lua",
"Lua scripts only",
"All files",
{text},
},
},
// #7
Or { { 4, 5 } }, Dummy { },
// #8
And { { 6, 7 } }, doItButton {},
}
}
};