OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2004, 2008, 2010 Apple Inc. All rights reserved. | 2 * Copyright (C) 2004, 2008, 2010 Apple Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
(...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
152 | 152 |
153 TextStream& operator<<(TextStream& ts, const FloatRect& r) { | 153 TextStream& operator<<(TextStream& ts, const FloatRect& r) { |
154 ts << "at (" << TextStream::FormatNumberRespectingIntegers(r.x()); | 154 ts << "at (" << TextStream::FormatNumberRespectingIntegers(r.x()); |
155 ts << "," << TextStream::FormatNumberRespectingIntegers(r.y()); | 155 ts << "," << TextStream::FormatNumberRespectingIntegers(r.y()); |
156 ts << ") size " << TextStream::FormatNumberRespectingIntegers(r.width()); | 156 ts << ") size " << TextStream::FormatNumberRespectingIntegers(r.width()); |
157 ts << "x" << TextStream::FormatNumberRespectingIntegers(r.height()); | 157 ts << "x" << TextStream::FormatNumberRespectingIntegers(r.height()); |
158 return ts; | 158 return ts; |
159 } | 159 } |
160 | 160 |
161 TextStream& operator<<(TextStream& ts, const LayoutUnit& unit) { | 161 TextStream& operator<<(TextStream& ts, const LayoutUnit& unit) { |
162 return ts << unit.toDouble(); | 162 return ts << TextStream::FormatNumberRespectingIntegers(unit.toDouble()); |
163 } | 163 } |
164 | 164 |
165 TextStream& operator<<(TextStream& ts, const LayoutPoint& point) { | 165 TextStream& operator<<(TextStream& ts, const LayoutPoint& point) { |
166 return ts << FloatPoint(point); | 166 return ts << FloatPoint(point); |
167 } | 167 } |
168 | 168 |
169 TextStream& operator<<(TextStream& ts, const LayoutRect& rect) { | 169 TextStream& operator<<(TextStream& ts, const LayoutRect& rect) { |
170 return ts << FloatRect(rect); | 170 return ts << FloatRect(rect); |
171 } | 171 } |
172 | 172 |
173 TextStream& operator<<(TextStream& ts, const LayoutSize& size) { | 173 TextStream& operator<<(TextStream& ts, const LayoutSize& size) { |
174 return ts << FloatSize(size); | 174 return ts << FloatSize(size); |
175 } | 175 } |
176 | 176 |
177 void writeIndent(TextStream& ts, int indent) { | 177 void writeIndent(TextStream& ts, int indent) { |
178 for (int i = 0; i != indent; ++i) | 178 for (int i = 0; i != indent; ++i) |
179 ts << " "; | 179 ts << " "; |
180 } | 180 } |
181 | 181 |
182 } // namespace blink | 182 } // namespace blink |
OLD | NEW |