File: macro.h

package info (click to toggle)
jupp 3.1.38-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster, sid
  • size: 2,420 kB
  • sloc: ansic: 31,382; sh: 4,199; makefile: 431
file content (48 lines) | stat: -rw-r--r-- 1,106 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
/*
 *	Keyboard macros
 *	Copyright
 *		(C) 1992 Joseph H. Allen
 *
 *	This file is part of JOE (Joe's Own Editor)
 */
#ifndef _JOE_MACRO_H
#define _JOE_MACRO_H 1

#ifdef EXTERN
__IDSTRING(rcsid_macro_h, "$MirOS: contrib/code/jupp/macro.h,v 1.5 2017/12/06 21:16:57 tg Exp $");
#endif

/* Set when macro is recording: for status line */
extern struct recmac *recmac;

/* Macro construction functions */
MACRO *mkmacro(int k, int arg, int n, CMD *cmd);
void addmacro(MACRO *macro, MACRO *m);
MACRO *dupmacro(MACRO *mac);
void rmmacro(MACRO *macro);
MACRO *macstk(MACRO *m, int k);
MACRO *macsta(MACRO *m, int a);

void chmac(void);

/* Text to macro / Macro to text */
MACRO *mparse(MACRO *m, unsigned char *buf, int *sta);
unsigned char *mtext(unsigned char *s, MACRO *m);

/* Execute a macro */
extern MACRO *curmacro;
int exemac(MACRO *m);
int exmacro(MACRO *m, int u);

/* Keyboard macros user interface */
int uplay(BW *bw, int c);
int ustop(void);
int urecord(BW *bw, int c);
int uquery(BW *bw);
int umacros(BW *bw);

/* Repeat prefix user command */
int uarg(BW *bw);
int uuarg(BW *bw, int c);

#endif