mirror of
https://github.com/ziglang/zig.git
synced 2025-12-06 14:23:09 +00:00
std.Progress: adjust the timings a little bit
Slightly slower refresh rate. It's still updating very quickly. Lower the initial delay so that CLI applications feel more responsive. Even though the application is doing work for the full 500ms until something is displayed on the screen, it feels nicer to get the progress earlier.
This commit is contained in:
parent
a5e4fe5487
commit
eea7e5e554
@ -59,9 +59,9 @@ pub const Options = struct {
|
||||
/// Must be at least 200 bytes.
|
||||
draw_buffer: []u8 = &default_draw_buffer,
|
||||
/// How many nanoseconds between writing updates to the terminal.
|
||||
refresh_rate_ns: u64 = 60 * std.time.ns_per_ms,
|
||||
refresh_rate_ns: u64 = 80 * std.time.ns_per_ms,
|
||||
/// How many nanoseconds to keep the output hidden
|
||||
initial_delay_ns: u64 = 500 * std.time.ns_per_ms,
|
||||
initial_delay_ns: u64 = 200 * std.time.ns_per_ms,
|
||||
/// If provided, causes the progress item to have a denominator.
|
||||
/// 0 means unknown.
|
||||
estimated_total_items: usize = 0,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user