Is there a way to center output...
there's a way to left justify and it right jutifies by default...any way to center?Code:cout << setiosflags(ios::left) << setw(5) << 'x' << endl;
Is there a way to center output...
there's a way to left justify and it right jutifies by default...any way to center?Code:cout << setiosflags(ios::left) << setw(5) << 'x' << endl;
not any standard way that I know of at least... your best solution may be to write it to a character array or String and then output that. you'd have to use a little math to get it centered in the string though.
here's a list of the standard manipulators and stream flags: http://www.cppreference.com/io_flags.html#format_flags
Join is in our Unofficial Cprog IRC channel
Server: irc.phoenixradio.org
Channel: #Tech
Team Cprog Folding@Home: Team #43476
Download it Here
Detailed Stats Here
More Detailed Stats
52 Members so far, are YOU a member?
Current team score: 1223226 (ranked 374 of 45152)
The CBoard team is doing better than 99.16% of the other teams
Top 5 Members: Xterria(518175), pianorain(118517), Bennet(64957), JaWiB(55610), alphaoide(44374)
Last Updated on: Wed, 30 Aug, 2006 @ 2:30 PM EDT