| 1 |
#ifndef _praat_script_h_ |
| 2 |
#define _praat_script_h_ |
| 3 |
/* praat_script.h |
| 4 |
* |
| 5 |
* Copyright (C) 1992-2005,2007,2009-2016,2018,2021-2026 Paul Boersma |
| 6 |
* |
| 7 |
* This code is free software; you can redistribute it and/or modify |
| 8 |
* it under the terms of the GNU General Public License as published by |
| 9 |
* the Free Software Foundation; either version 3 of the License, or (at |
| 10 |
* your option) any later version. |
| 11 |
* |
| 12 |
* This code is distributed in the hope that it will be useful, but |
| 13 |
* WITHOUT ANY WARRANTY; without even the implied warranty of |
| 14 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. |
| 15 |
* See the GNU General Public License for more details. |
| 16 |
* |
| 17 |
* You should have received a copy of the GNU General Public License |
| 18 |
* along with this work. If not, see <http://www.gnu.org/licenses/>. |
| 19 |
*/ |
| 20 |
|
| 21 |
#include "Interpreter.h" |
| 22 |
|
| 23 |
bool praat_executeCommand (Interpreter me, char32 *command); // returns false only if nocheck cancelled an error |
| 24 |
void praat_executeCommandFromStandardInput (conststring32 programName); |
| 25 |
void praat_executeScript_noGUI (MelderFile file, bool fullTrust); |
| 26 |
void praat_runScript (InterpreterStack interpreterStack, conststring32 fileName, integer narg, Stackel args, Editor optionalInterpreterOwningEditor); // called only from Formula as `runScript` (last checked 2022-10-07) |
| 27 |
void praat_runScriptWithForm (conststring32 fileName, bool fullTrust); |
| 28 |
void praat_runNotebook (InterpreterStack interpreterStack, conststring32 fileName, integer narg, Stackel args, Editor optionalInterpreterOwningEditor); |
| 29 |
void praat_executeScriptFromCommandLine (conststring32 fileName, integer argc, char **argv, bool fullTrust); // called only from `praat_run` (last checked 2022-10-07) |
| 30 |
void praat_executeScriptFromText (conststring32 text); |
| 31 |
extern "C" void praatlib_executeScript (const char *text8); |
| 32 |
void DO_RunTheScriptFromAnyAddedMenuCommand (UiForm sendingForm_dummy, integer narg, Stackel args, conststring32 scriptPath, |
| 33 |
Interpreter /* interpreter */, conststring32 invokingButtonTitle, bool modified, void *dummy, Editor optionalInterpreterOwningEditor); |
| 34 |
void praat_executeScriptFromEditorCommand (Editor interpreterOwningEditor, EditorCommand command, conststring32 script); |
| 35 |
|
| 36 |
/* |
| 37 |
Deprecated stuff. |
| 38 |
*/ |
| 39 |
void praat_executeScriptFromFileNameWithArguments (conststring32 nameAndArguments); // called only from external man pages with \SC (deprecated 2026) (last checked 2026-02-03) |
| 40 |
void praat_runOldExecuteCommand (InterpreterStack owningInterpreterStack, conststring32 nameAndArguments); // called only from `execute` (deprecated 2014) (last checked 2026-02-03) |
| 41 |
|
| 42 |
#endif // !_praat_script_h_ |