name: "Lime Room" panels { name: "RAT" path: "Panels/Lingo2/panel_1" clue: "rat" answer: "tartar" } panels { name: "POMPOM" path: "Panels/Lingo2/panel_2" clue: "pompom" answer: "mop" } panels { name: "TWENTY" path: "Panels/Lingo2/panel_7" clue: "twenty" answer: "blind" symbols: SUN } panels { name: "EQUAL" path: "Panels/Lingo2/panel_8" clue: "equal" answer: "fifty" symbols: SUN } panels { name: "PIGEON" path: "Panels/Lingo2/panel_10" clue: "pigeon" answer: "cuckoo" symbols: ZERO symbols: SOUND } panels { name: "BIRD" path: "Panels/Lingo2/panel_11" clue: "bird" answer: "do" symbols: EXAMPLE } panels { name: "MISTAKE" path: "Panels/Lingo2/panel_12" clue: "mistake" answer: "ghost" symbols: SUN symbols: SOUND } panels { name: "INJURY" path: "Panels/Lingo2/panel_26" clue: "injury" answer: "boo" symbols: PYRAMID } panels { name: "TRAIN" path: "Panels/Lingo2/panel_13" clue: "train" answer: "chew" symbols: ZERO symbols: SOUND } panels { name: "ELLIPSIS" path: "Panels/Lingo2/panel_14" clue: "ellipsis" answer: "dot" symbols: SUN } panels { name: "SLEEPER" path: "Panels/Lingo2/panel_15" clue: "sleeper" answer: "z" symbols: SOUND } panels { name: "OH" path: "Panels/Lingo2/panel_16" clue: "oh" answer: "santa" symbols: SOUND } 8a254360c12d3c9a2a687c77b864132'>refs log blame commit diff stats
path: root/vendor/whereami/whereami.h
blob: 8988f1d30a50bfed70d6db36103e86b7e0f15c4e (plain) (tree)


































































                                                                                
// (‑●‑●)> dual licensed under the WTFPL v2 and MIT licenses
//   without any warranty.
//   by Gregory Pakosz (@gpakosz)
// https://github.com/gpakosz/whereami

#ifndef WHEREAMI_H
#define WHEREAMI_H

#ifdef __cplusplus
extern "C" {
#endif

#ifndef WAI_FUNCSPEC
#define WAI_FUNCSPEC
#endif
#ifndef WAI_PREFIX
#define WAI_PREFIX(function) wai_##function
#endif

/**
 * Returns the path to the current executable.
 *
 * Usage:
 *  - first call `int length = wai_getExecutablePath(NULL, 0, NULL);` to
 *    retrieve the length of the path
 *  - allocate the destination buffer with `path = (char*)malloc(length + 1);`
 *  - call `wai_getExecutablePath(path, length, NULL)` again to retrieve the
 *    path
 *  - add a terminal NUL character with `path[length] = '\0';`
 *
 * @param out destination buffer, optional
 * @param capacity destination buffer capacity
 * @param dirname_length optional recipient for the length of the dirname part
 *   of the path.
 *
 * @return the length of the executable path on success (without a terminal NUL
 * character), otherwise `-1`
 */
WAI_FUNCSPEC
int WAI_PREFIX(getExecutablePath)(char* out, int capacity, int* dirname_length);

/**
 * Returns the path to the current module
 *
 * Usage:
 *  - first call `int length = wai_getModulePath(NULL, 0, NULL);` to retrieve
 *    the length  of the path
 *  - allocate the destination buffer with `path = (char*)malloc(length + 1);`
 *  - call `wai_getModulePath(path, length, NULL)` again to retrieve the path
 *  - add a terminal NUL character with `path[length] = '\0';`
 *
 * @param out destination buffer, optional
 * @param capacity destination buffer capacity
 * @param dirname_length optional recipient for the length of the dirname part
 *   of the path.
 *
 * @return the length of the module path on success (without a terminal NUL
 * character), otherwise `-1`
 */
WAI_FUNCSPEC
int WAI_PREFIX(getModulePath)(char* out, int capacity, int* dirname_length);

#ifdef __cplusplus
}
#endif

#endif  // #ifndef WHEREAMI_H