pos.h
Go to the documentation of this file.
1 #ifndef NVIM_POS_H
2 #define NVIM_POS_H
3 
4 typedef long linenr_T; // line number type
6 #define PRIdLINENR "ld"
7 
9 typedef int colnr_T;
11 #define PRIdCOLNR "d"
12 
14 enum { MAXLNUM = 0x7fffffff };
16 enum { MAXCOL = 0x7fffffff };
17 // Minimum line number
18 enum { MINLNUM = 1 };
19 // minimum column number
20 enum { MINCOL = 1 };
21 
22 /*
23  * position in file or buffer
24  */
25 typedef struct {
26  linenr_T lnum; /* line number */
27  colnr_T col; /* column number */
29 } pos_T;
30 
31 
32 /*
33  * Same, but without coladd.
34  */
35 typedef struct {
36  linenr_T lnum; /* line number */
37  colnr_T col; /* column number */
38 } lpos_T;
39 
40 #endif // NVIM_POS_H
Definition: pos.h:18
Definition: pos.h:20
int colnr_T
Column number type.
Definition: pos.h:9
colnr_T col
Definition: pos.h:27
colnr_T coladd
Definition: pos.h:28
linenr_T lnum
Definition: pos.h:26
linenr_T lnum
Definition: pos.h:36
Definition: pos.h:35
long linenr_T
Definition: pos.h:4
Definition: pos.h:16
Definition: pos.h:25
Definition: pos.h:14
colnr_T col
Definition: pos.h:37