zygo

ncurses gopher client
git clone https://hhvn.uk/zygo
git clone git://hhvn.uk/zygo
Log | Files | Refs

config.def.h (2293B)


      1 static char *plumber = "xdg-open";
      2 static char *yanker = "xclip";
      3 static char *normsep = "│"; /* separates link number/info and description */
      4 static char *toolong = ">"; /* line is too long to fit in terminal */
      5 static int parallelplumb = 0;
      6 static int stimeout = 5;
      7 static int regexflags = REG_ICASE|REG_EXTENDED;
      8 static int mdhilight = 0; /* attempt to hilight markdown headers */
      9 static int autotls = 0;   /* automatically try to establish TLS connections */
     10 
     11 static short bar_pair[2] = {-1,  0};
     12 static short uri_pair[2] = {0,   7};
     13 static short cmd_pair[2] = {7,   0};
     14 static short arg_pair[2] = {-1,  0};
     15 static short err_pair[2] = {160, 0};
     16 static short eid_pair[2] = {4,   -1};
     17 
     18 /* Page shown if zygo is called without any arguments.
     19  * This can contain anything you want, really.
     20  *
     21  * The convenience macros INFO() and LINK() are in zygo.h */
     22 static Elem start_page[] = {
     23 	INFO("Welcome to zygo."),
     24 	LINK('1', " - git repo", "/git/o/zygo", "hhvn.uk", "70"),
     25 	INFO(""),
     26 	INFO("Type 'h' to read the man page."),
     27 };
     28 
     29 /* Some bindings are still hardcoded in zygo.c */
     30 enum Bindings {
     31 	BIND_URI = ':',
     32 	BIND_DISPLAY = '+',
     33 	BIND_SEARCH = '/',
     34 	BIND_SEARCH_BACK = '?',
     35 	BIND_APPEND = 'a',
     36 	BIND_YANK = 'y',
     37 	BIND_DOWN = 'j',
     38 	BIND_UP = 'k',
     39 	BIND_QUIT = 'q',
     40 	BIND_BACK = '<',
     41 	BIND_RELOAD = '*',
     42 	BIND_TOP = 'g',
     43 	BIND_BOTTOM = 'G',
     44 	BIND_SEARCH_NEXT = 'n',
     45 	BIND_SEARCH_PREV = 'N',
     46 	BIND_ROOT = 'r',
     47 	BIND_HELP = 'h',
     48 	BIND_HISTORY = 'H',
     49 };
     50 
     51 static Scheme scheme[] = {
     52 	/* type, name,   fg */
     53 	{'i',    "    ", -1 },
     54 	{'0',    "Text", -1 },
     55 	{'1',    "Dir ",  2 },
     56 	{'2',    "CCSO",  3 },
     57 	{'4',    "Bin ",  4 },
     58 	{'5',    "Bin ",  4 },
     59 	{'9',    "Bin ",  4 },
     60 	{'7',    "Srch",  3 },
     61 	{'8',    "Teln",  5 },
     62 	{'T',    "Teln",  5 },
     63 	{'+',    "Alt ",  5 },
     64 	{'I',    "Img ",  6 },
     65 	{'g',    "Img ",  6 },
     66 	{'h',    "HTML",  5 },
     67 	{EXTR,   "Extr",  5 },
     68 	{'s',    "Snd ",  7 },
     69 	{'d',    "Doc ",  8 },
     70 	{'3',    "ERR ",  1 },
     71 
     72 	/* Experimental markdown header hilighting.
     73 	 * mdhilight must be set for this to show.
     74 	 * Unlike other elements of scheme, the fore-
     75 	 * ground is used for the text itself, not
     76 	 * the name. */
     77 	{MDH1,	 "    ",  6 },
     78 	{MDH2,   "    ",  5 },
     79 	{MDH3,   "    ",  4 },
     80 	{MDH4,   "    ",  3 },
     81 
     82 	/* must be last, see getscheme() */
     83 	{DEFL,   "????",  8 },
     84 };