aboutsummaryrefslogtreecommitdiff
path: root/editor.h
diff options
context:
space:
mode:
authorMarc André Tanner <mat@brain-dump.org>2014-09-10 12:44:25 +0200
committerMarc André Tanner <mat@brain-dump.org>2014-09-10 12:44:25 +0200
commit49196eba130b3ab4f0939f13d071aef3d0a70eab (patch)
tree4d3f5d95dac9a8d01677ed66245f18796c63f695 /editor.h
parente46158f31369b8b16ed9ea3885b9def08afc4a55 (diff)
downloadvis-49196eba130b3ab4f0939f13d071aef3d0a70eab.tar.gz
vis-49196eba130b3ab4f0939f13d071aef3d0a70eab.tar.xz
Simplify drawing of the window statusbar
Diffstat (limited to 'editor.h')
-rw-r--r--editor.h6
1 files changed, 2 insertions, 4 deletions
diff --git a/editor.h b/editor.h
index 388f8d5..2f47b52 100644
--- a/editor.h
+++ b/editor.h
@@ -28,8 +28,6 @@ typedef struct {
bool active; /* whether the prompt is currently shown or not */
} Prompt;
-typedef void (*editor_statusbar_t)(WINDOW *win, bool active, const char *filename, size_t line, size_t col);
-
enum Reg {
REG_a,
REG_b,
@@ -99,7 +97,7 @@ struct Editor {
Prompt *prompt; /* used to get user input */
Regex *search_pattern; /* last used search pattern */
void (*windows_arrange)(Editor*); /* current layout which places the windows */
- editor_statusbar_t statusbar; /* configurable user hook to draw statusbar */
+ void (*statusbar)(EditorWin*); /* configurable user hook to draw statusbar */
bool running; /* (TODO move elsewhere?) */
};
@@ -149,7 +147,7 @@ void editor_prompt_set(Editor *vis, const char *line);
void editor_prompt_show(Editor *vis, const char *title);
void editor_prompt_hide(Editor *vis);
-void editor_statusbar_set(Editor*, editor_statusbar_t);
+void editor_statusbar_set(Editor*, void (*statusbar)(EditorWin*));
/* look up a curses color pair for the given combination of fore and
* background color */