package progress
User-definable progress bars
Install
Dune Dependency
Authors
Maintainers
Sources
progress-0.1.0.tbz
sha256=1f101c2823d84d4dc8af693d1571ebdd614f30d675f8efeedf0d6c3018f602e2
sha512=663494ac7f4ddcbc130edc90f5ae036ec198b44f826a966fa94edee419ce7d9bb7e00a5c3996eb65b2d8213a3907a05fff60707f828102ef1e5c5133bcd78037
doc/src/progress.unix/progress_unix.ml.html
Source file progress_unix.ml
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
let stopwatch () = Progress.Segment.stateful (fun () -> let start_time = Mtime_clock.counter () in Progress.Units.seconds (fun ~width pp_time -> let pp ppf = pp_time ppf (Mtime_clock.count start_time) in Progress.Segment.const_fmt ~width pp)) let counter = Progress.Internal.counter ~prebar:(stopwatch ()) let stderr_if_tty = if Unix.(isatty stderr) then Format.err_formatter else Format.make_formatter (fun _ _ _ -> ()) (fun () -> ()) let with_display x = Progress.with_display ~ppf:stderr_if_tty x let start x = Progress.start ~ppf:stderr_if_tty x let finalise = Progress.finalise let ( / ) = Progress.( / )
sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>