Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(186)

Side by Side Diff: third_party/WebKit/Source/platform/fonts/FontCustomPlatformData.cpp

Issue 2700123003: DO NOT COMMIT: Results of running old (current) clang-format on Blink (Closed)
Patch Set: Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2007 Apple Computer, Inc. 2 * Copyright (C) 2007 Apple Computer, Inc.
3 * Copyright (c) 2007, 2008, 2009, Google Inc. All rights reserved. 3 * Copyright (c) 2007, 2008, 2009, Google Inc. All rights reserved.
4 * Copyright (C) 2010 Company 100, Inc. 4 * Copyright (C) 2010 Company 100, Inc.
5 * 5 *
6 * Redistribution and use in source and binary forms, with or without 6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions are 7 * modification, are permitted provided that the following conditions are
8 * met: 8 * met:
9 * 9 *
10 * * Redistributions of source code must retain the above copyright 10 * * Redistributions of source code must retain the above copyright
(...skipping 14 matching lines...) Expand all
25 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 25 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
26 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 26 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
27 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 27 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
28 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 28 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
29 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
30 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31 */ 31 */
32 32
33 #include "platform/fonts/FontCustomPlatformData.h" 33 #include "platform/fonts/FontCustomPlatformData.h"
34 34
35 #include <memory>
35 #include "platform/LayoutTestSupport.h" 36 #include "platform/LayoutTestSupport.h"
36 #include "platform/SharedBuffer.h" 37 #include "platform/SharedBuffer.h"
37 #include "platform/fonts/FontCache.h" 38 #include "platform/fonts/FontCache.h"
38 #include "platform/fonts/FontPlatformData.h" 39 #include "platform/fonts/FontPlatformData.h"
39 #include "platform/fonts/WebFontDecoder.h" 40 #include "platform/fonts/WebFontDecoder.h"
40 #include "platform/fonts/opentype/FontSettings.h" 41 #include "platform/fonts/opentype/FontSettings.h"
41 #include "third_party/skia/include/core/SkStream.h" 42 #include "third_party/skia/include/core/SkStream.h"
42 #include "third_party/skia/include/core/SkTypeface.h" 43 #include "third_party/skia/include/core/SkTypeface.h"
43 #include "wtf/PtrUtil.h" 44 #include "wtf/PtrUtil.h"
44 #include <memory>
45 45
46 namespace blink { 46 namespace blink {
47 47
48 FontCustomPlatformData::FontCustomPlatformData(sk_sp<SkTypeface> typeface, 48 FontCustomPlatformData::FontCustomPlatformData(sk_sp<SkTypeface> typeface,
49 size_t dataSize) 49 size_t dataSize)
50 : m_baseTypeface(typeface), m_dataSize(dataSize) {} 50 : m_baseTypeface(typeface), m_dataSize(dataSize) {}
51 51
52 FontCustomPlatformData::~FontCustomPlatformData() {} 52 FontCustomPlatformData::~FontCustomPlatformData() {}
53 53
54 FontPlatformData FontCustomPlatformData::fontPlatformData( 54 FontPlatformData FontCustomPlatformData::fontPlatformData(
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
112 new FontCustomPlatformData(std::move(typeface), decoder.decodedSize())); 112 new FontCustomPlatformData(std::move(typeface), decoder.decodedSize()));
113 } 113 }
114 114
115 bool FontCustomPlatformData::supportsFormat(const String& format) { 115 bool FontCustomPlatformData::supportsFormat(const String& format) {
116 return equalIgnoringCase(format, "truetype") || 116 return equalIgnoringCase(format, "truetype") ||
117 equalIgnoringCase(format, "opentype") || 117 equalIgnoringCase(format, "opentype") ||
118 WebFontDecoder::supportsFormat(format); 118 WebFontDecoder::supportsFormat(format);
119 } 119 }
120 120
121 } // namespace blink 121 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698