~mdw
/
dvdrip
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
multiprogress.c: Remove pointless return value from `setup_render_state'.
[dvdrip]
/
multiprogress.h
diff --git
a/multiprogress.h
b/multiprogress.h
index
1db97a8
..
f5147c4
100644
(file)
--- a/
multiprogress.h
+++ b/
multiprogress.h
@@
-10,13
+10,15
@@
struct progress_ttyinfo {
struct { /* terminal capabilities */
unsigned f; /* various flags */
#define TCF_BCE 1u /* erases to background colour */
struct { /* terminal capabilities */
unsigned f; /* various flags */
#define TCF_BCE 1u /* erases to background colour */
- const char *cr, *
up, *ce, *cd;
/* cursor motion */
+ const char *cr, *
nw, *up, *ce, *cd;
/* cursor motion */
const char *mr, *md, *me; /* reverse video, bold */
const char *af, *ab, *op; /* colour */
const char *mr, *md, *me; /* reverse video, bold */
const char *af, *ab, *op; /* colour */
+ char pc; /* pad character (termcap) */
} cap;
} cap;
-
unsigned defwd, defht;
/* default width and height */
+
unsigned defwd, defht;
/* default width and height */
};
};
-#define PROGRESS_TTYINFO_INIT { 0, 0, 0, { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } }
+#define PROGRESS_TTYINFO_INIT \
+ { 0, 0, 0, { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, 80, 25 }
struct progress_state {
struct progress_ttyinfo tty; /* terminal state */
struct progress_state {
struct progress_ttyinfo tty; /* terminal state */
@@
-34,7
+36,7
@@
struct progress_render_state {
char *tempbuf; size_t tempsz; /* scratch buffer */
size_t leftsz, rightsz; /* left and right cursors */
unsigned leftwd, rightwd; /* left and right widths */
char *tempbuf; size_t tempsz; /* scratch buffer */
size_t leftsz, rightsz; /* left and right cursors */
unsigned leftwd, rightwd; /* left and right widths */
- char *old_bc, *old_up
; /* old fixup string
s */
+ char *old_bc, *old_up
, old_pc; /* saved `termcap' global
s */
};
struct progress_item {
};
struct progress_item {
@@
-48,16
+50,15
@@
struct progress_item {
extern int progress_init(struct progress_state */*progress*/);
extern void progress_free(struct progress_state */*progress*/);
extern int progress_init(struct progress_state */*progress*/);
extern void progress_free(struct progress_state */*progress*/);
-extern int progress_clear(struct progress_state */*progress*/);
-
-extern int progress_update(struct progress_state */*progress*/);
-
extern int progress_additem(struct progress_state */*progress*/,
struct progress_item */*item*/);
extern int progress_removeitem(struct progress_state */*progress*/,
struct progress_item */*item*/);
extern int progress_additem(struct progress_state */*progress*/,
struct progress_item */*item*/);
extern int progress_removeitem(struct progress_state */*progress*/,
struct progress_item */*item*/);
+extern int progress_clear(struct progress_state */*progress*/);
+
+extern int progress_update(struct progress_state */*progress*/);
extern int progress_vputleft(struct progress_render_state */*render*/,
const char */*fmt*/, va_list /*ap*/);
extern int progress_vputleft(struct progress_render_state */*render*/,
const char */*fmt*/, va_list /*ap*/);