Boost logo

Boost :

From: Beman Dawes (bdawes_at_[hidden])
Date: 2001-12-01 16:30:56


At 10:27 AM 11/29/2001, Toon Knapen wrote:

>Would it be possible to get rid of the leading `\n` in
>_os << "\n0% 10 20 30 40 50 60 70 80 90 100%\n"
>in the progress_display. In some cases I do not want the newline.
>
>Even better would be that the constructor would take three extra string
>arguments. The first string will be the leading string for the
>scale-numbers, the second the leading string for the scale, the third
>for the 'stars'.
>Thus instead of the above, something like :
>
>_os << lead1 <<
"0% 10 20 30 40 50 60 70 80 90 100%\n";
>_os << lead2 << "|----|----|----|----|----|----|----|----|----|----|" <<
>lead3 << std::endl;
>
>with the constraint that lead1.lenth() == lead2.length() ==
>lead3.length() of course.
>This way, one could e.g. have following output :
>
>
>energy remaining 0% 10 20 30 40 50 60 70 80 90 100%
> x 10KJ |----|----|----|----|----|----|----|----|----|----|
> ******************************

Nice!

I've updated the CVS. Please let me know if you spot any problems.

(I'll be out of town for a week, so may not reply right away.)

--Beman


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk