aboutsummaryrefslogtreecommitdiff
path: root/vis.h
diff options
context:
space:
mode:
authorMarc André Tanner <mat@brain-dump.org>2016-01-29 19:39:38 +0100
committerMarc André Tanner <mat@brain-dump.org>2016-01-29 19:46:18 +0100
commit68c3fa73b29fc1cc560414518a73ceac93f087b0 (patch)
treee0e30245524e6949c2a87cf0f2ec92cd78bbd432 /vis.h
parent5f3ad60675c5962e1fb003105ceaeed17a622ed3 (diff)
downloadvis-68c3fa73b29fc1cc560414518a73ceac93f087b0.tar.gz
vis-68c3fa73b29fc1cc560414518a73ceac93f087b0.tar.xz
vis: factor out filter command implementation
Diffstat (limited to 'vis.h')
-rw-r--r--vis.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/vis.h b/vis.h
index 96a9914..477ffe4 100644
--- a/vis.h
+++ b/vis.h
@@ -364,6 +364,11 @@ bool vis_cmd(Vis*, const char *cmd);
/* execute any kind (:,?,/) of prompt command */
bool vis_prompt_cmd(Vis*, const char *cmd);
+/* pipe a given file range to an external process */
+int vis_pipe(Vis *vis, void *context, Filerange *range, const char *argv[],
+ ssize_t (*read_stdout)(void *context, char *data, size_t len),
+ ssize_t (*read_stderr)(void *context, char *data, size_t len));
+
/* given the start of a key, returns a pointer to the start of the one immediately
* following as will be processed by the input system. skips over special keys
* such as <Enter> as well as pseudo keys registered via vis_action_register. */