NeoMutt  2025-12-11-596-g7cc1dd
Teaching an old dog new tricks
DOXYGEN
Loading...
Searching...
No Matches
lib.h
Go to the documentation of this file.
1
23
69
70#ifndef MUTT_PROGRESS_LIB_H
71#define MUTT_PROGRESS_LIB_H
72
73#include <stdbool.h>
74#include <stdio.h>
75
76struct Progress;
77
87
88void progress_free (struct Progress **ptr);
89struct Progress *progress_new (enum ProgressType type, size_t size);
90bool progress_update (struct Progress *progress, size_t pos, int percent);
91void progress_set_message(struct Progress *progress, const char *fmt, ...)
92 __attribute__((__format__(__printf__, 2, 3)));
93void progress_set_size (struct Progress *progress, size_t size);
94
95#endif /* MUTT_PROGRESS_LIB_H */
ProgressType
What kind of operation is this progress tracking?
Definition lib.h:82
@ MUTT_PROGRESS_NET
Progress tracks bytes, according to $net_inc
Definition lib.h:83
@ MUTT_PROGRESS_READ
Progress tracks elements, according to $read_inc
Definition lib.h:84
@ MUTT_PROGRESS_WRITE
Progress tracks elements, according to $write_inc
Definition lib.h:85
struct Progress * progress_new(enum ProgressType type, size_t size)
Create a new Progress Bar.
Definition progress.c:139
void progress_free(struct Progress **ptr)
Free a Progress Bar.
Definition progress.c:110
void progress_set_message(struct Progress *progress, const char *fmt,...) __attribute__((__format__(__printf__
void void progress_set_size(struct Progress *progress, size_t size)
Set the progress size.
Definition progress.c:193
bool progress_update(struct Progress *progress, size_t pos, int percent)
Update the state of the progress bar.
Definition progress.c:80