1/* 2 * Copyright (c) 2003-2005 The Regents of The University of Michigan 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions are 7 * met: redistributions of source code must retain the above copyright 8 * notice, this list of conditions and the following disclaimer; --- 36 unchanged lines hidden (view full) --- 45 bool blank_space; 46 bool fill_zero; 47 bool uppercase; 48 enum { dec, hex, oct } base; 49 enum { none, string, integer, character, floating } format; 50 enum { best, fixed, scientific } float_format; 51 int precision; 52 int width; |
53 bool get_precision; 54 bool get_width; |
55 56 Format() { clear(); } 57 58 void clear() 59 { 60 alternate_form = false; 61 flush_left = false; 62 print_sign = false; 63 blank_space = false; 64 fill_zero = false; 65 uppercase = false; 66 base = dec; 67 format = none; 68 precision = -1; 69 width = 0; |
70 get_precision = false; 71 get_width = false; |
72 } 73}; 74 75template <typename T> 76inline void 77_format_char(std::ostream &out, const T &data, Format &fmt) 78{ 79 using namespace std; --- 281 unchanged lines hidden --- |