robin/laufey
git clone https://git.robinwobin.dev/robin/laufey
a4a544032a
master
1#pragma once 2 3// Some defines from the old feature.h 4#define SESSION_FILE "Session.vim" 5#define SYS_OPTWIN_FILE "$VIMRUNTIME/scripts/optwin.lua" 6#define RUNTIME_DIRNAME "runtime" 7 8enum { 9/// length of a buffer to store a number in ASCII (64 bits binary + NUL) 10NUMBUFLEN = 65 , 11}; 12 13#define MAX_TYPENR 65535 14 15/// Directions. 16typedef enum { 17kDirectionNotSet = 0 , 18FORWARD = 1 , 19BACKWARD = -1 , 20FORWARD_FILE = 3 , 21BACKWARD_FILE = -3 , 22}Direction ; 23 24/// Used to track the status of external functions. 25/// Currently only used for iconv(). 26typedef enum { 27kUnknown , 28kWorking , 29kBroken , 30}WorkingStatus ; 31 32/// The scope of a working-directory command like `:cd`. Enumerated from lowest to highest. 33typedef enum { 34kCdScopeInvalid = -1 , 35kCdScopeBuffer ,///< Affects one buffer. 36kCdScopeWindow ,///< Affects one window. 37kCdScopeTabpage ,///< Affects one tab page. 38kCdScopeGlobal ,///< Affects the entire Nvim instance. 39}CdScope ; 40 41/// What caused the current directory to change. 42typedef enum { 43kCdCauseOther = -1 , 44kCdCauseManual ,///< Using `:cd`, `:tcd`, `:lcd`, `:bcd` or `chdir()`. 45kCdCauseWindow ,///< Switching to another window. 46kCdCauseBuffer ,///< Switching to another buffer. 47kCdCauseAuto ,///< On 'autochdir'. 48}CdCause ; 49 50// return values for functions 51#if !(defined(OK )&& (OK == 1 )) 52// OK already defined to 1 in MacOS X curses, skip this 53# define OK 1 54#endif 55#define FAIL 0 56#define NOTDONE 2 // not OK or FAIL but skipped