1
+ OrgApiRefileOpts *OrgApiRefileOpts*
2
+
3
+ Fields: ~
4
+ {source} (OrgApiHeadline)
5
+ {destination} (OrgApiFile|OrgApiHeadline)
6
+
7
+
8
+ OrgApi *OrgApi*
9
+
10
+
1
11
OrgApi.load({name?}) *OrgApi.load*
2
12
3
13
Parameters: ~
4
14
{name?} (string|string[]) specific file names to return (absolute path). If ommitted, returns all loaded files
5
15
6
16
Returns: ~
7
- (OrgFile|OrgFile [])
17
+ (OrgApiFile|OrgApiFile [])
8
18
9
19
10
20
OrgApi.current() *OrgApi.current*
11
21
Get current org buffer file
12
22
13
23
Returns: ~
14
- (OrgFile)
24
+ (OrgApiFile)
25
+
26
+
27
+ OrgApi.refile({opts} ) *OrgApi.refile*
28
+ Refile headline to another file or headline
29
+ If executed from capture buffer, it will close the capture buffer
30
+
31
+ Parameters: ~
32
+ {opts} (OrgApiRefileOpts)
33
+
34
+ Returns: ~
35
+ (boolean)
15
36
16
37
17
- OrgFile *OrgFile *
38
+ OrgApiFile *OrgApiFile *
18
39
19
40
Fields: ~
20
- {category} (string) current file category name. By default it's only filename without extension unless defined differently via #+CATEGORY directive
21
- {filename} (string) absolute path of the current file
22
- {headlines} (OrgHeadline [])
41
+ {category} (string) current file category name. By default it's only filename without extension unless defined differently via #+CATEGORY directive
42
+ {filename} (string) absolute path of the current file
43
+ {headlines} (OrgApiHeadline [])
23
44
{is_archive_file} (boolean)
24
45
25
46
26
47
OrgFile:reload() *OrgFile:reload*
27
48
Return refreshed instance of the file
28
49
29
50
Returns: ~
30
- (OrgFile)
51
+ (OrgApiFile)
52
+
53
+
54
+ OrgFile:get_closest_headline() *OrgFile:get_closest_headline*
55
+ Return closest headline, or nil if there are no headlines found
56
+ If cursor is not provided, it will use current cursor position
57
+ @param cursor? { line: number, col: number } (1, 0)-indexed cursor position, same as returned from `vim .api.nvim_win_get_cursor (0 )`
58
+ @return OrgApiHeadline | nil
31
59
32
60
33
- OrgHeadline *OrgHeadline *
61
+ OrgApiHeadline *OrgApiHeadline *
34
62
35
63
Fields: ~
36
- {title} (string) headline title without todo keyword, tags and priority. Ex. `* TODO I am a headline :SOMETAG:` returns `I am a headline`
37
- {line} (string) full headline line
38
- {level} (number) headline level (number of asterisks). Example: 1
39
- {todo_value?} (string) todo keyword of the headline (Example: TODO, DONE)
40
- {todo_type?} (string|)
64
+ {title} (string) headline title without todo keyword, tags and priority. Ex. `* TODO I am a headline :SOMETAG:` returns `I am a headline`
65
+ {line} (string) full headline line
66
+ {level} (number) headline level (number of asterisks). Example: 1
67
+ {todo_value?} (string) todo keyword of the headline (Example: TODO, DONE)
68
+ {todo_type?} ("TODO"|"DONE"|"")
69
+ {tags} (string[]) List of own tags
70
+ {deadline} (OrgDate|nil)
71
+ {scheduled} (OrgDate|nil)
72
+ {properties} (table<string,string>) Table containing all properties. All keys are lowercased
73
+ {closed} (OrgDate|nil)
74
+ {dates} (OrgDate[]) List of all dates that are not "plan" dates
75
+ {position} (OrgRange)
76
+ {all_tags} (string[]) List of all tags (own + inherited)
77
+ {file} (OrgApiFile)
78
+ {parent} (OrgApiHeadline|nil)
79
+ {priority} (string|nil)
80
+ {is_archived} (boolean) headline marked with the `:ARCHIVE:` tag
81
+ {headlines} (OrgApiHeadline[])
41
82
42
83
43
84
OrgHeadline:reload() *OrgHeadline:reload*
44
85
Return updated version of headline
45
86
46
87
Returns: ~
47
- (OrgHeadline )
88
+ (OrgApiHeadline )
48
89
49
90
50
91
OrgHeadline:set_tags({tags} ) *OrgHeadline:set_tags*
@@ -54,21 +95,21 @@ OrgHeadline:set_tags({tags}) *OrgHeadline:set_tags*
54
95
{tags} (string[])
55
96
56
97
Returns: ~
57
- (Promise )
98
+ (OrgPromise )
58
99
59
100
60
101
OrgHeadline:priority_up() *OrgHeadline:priority_up*
61
102
Increase priority on a headline
62
103
63
104
Returns: ~
64
- (Promise )
105
+ (OrgPromise )
65
106
66
107
67
108
OrgHeadline:priority_down() *OrgHeadline:priority_down*
68
109
Decrease priority on a headline
69
110
70
111
Returns: ~
71
- (Promise )
112
+ (OrgPromise )
72
113
73
114
74
115
OrgHeadline:set_priority({priority} ) *OrgHeadline:set_priority*
@@ -78,27 +119,27 @@ OrgHeadline:set_priority({priority}) *OrgHeadline:set_priority*
78
119
{priority} (string)
79
120
80
121
Returns: ~
81
- (Promise )
122
+ (OrgPromise )
82
123
83
124
84
125
OrgHeadline:set_deadline({date?}) *OrgHeadline:set_deadline*
85
126
Set deadline date
86
127
87
128
Parameters: ~
88
- {date?} (Date | string | nil) If ommited, opens the datepicker. Empty string removes the date. String must follow org date convention (YYYY-MM-DD HH:mm...)
129
+ {date?} (OrgDate | string | nil) If ommited, opens the datepicker. Empty string removes the date. String must follow org date convention (YYYY-MM-DD HH:mm...)
89
130
90
131
Returns: ~
91
- (Promise )
132
+ (OrgPromise )
92
133
93
134
94
135
OrgHeadline:set_scheduled({date?}) *OrgHeadline:set_scheduled*
95
136
Set scheduled date
96
137
97
138
Parameters: ~
98
- {date?} (Date | string | nil) If ommited, opens the datepicker. Empty string removes the date. String must follow org date convention (YYYY-MM-DD HH:mm...)
139
+ {date?} (OrgDate | string | nil) If ommited, opens the datepicker. Empty string removes the date. String must follow org date convention (YYYY-MM-DD HH:mm...)
99
140
100
141
Returns: ~
101
- (Promise )
142
+ (OrgPromise )
102
143
103
144
104
145
OrgHeadline:set_property({key} , {value} ) *OrgHeadline:set_property*
@@ -137,7 +178,7 @@ OrgAgendaOptions *OrgAgendaOptions*
137
178
138
179
Fields: ~
139
180
{filters?} (OrgAgendaFilter)
140
- {from?} (string|Date )
181
+ {from?} (string|OrgDate )
141
182
{span?} (number|"day"|"week"|"month"|"year")
142
183
143
184
0 commit comments