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

Side by Side Diff: base/mac/foundation_util.mm

Issue 10543057: Initial RenderTextMac implementation using CoreText. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 5 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 | Annotate | Revision Log
« no previous file with comments | « base/mac/foundation_util.h ('k') | skia/ext/skia_utils_mac.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/mac/foundation_util.h" 5 #include "base/mac/foundation_util.h"
6 6
7 #include <stdlib.h> 7 #include <stdlib.h>
8 #include <string.h> 8 #include <string.h>
9 9
10 #include "base/file_path.h" 10 #include "base/file_path.h"
(...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after
194 TYPE_NAME_FOR_CF_TYPE_DEFN(CFBag); 194 TYPE_NAME_FOR_CF_TYPE_DEFN(CFBag);
195 TYPE_NAME_FOR_CF_TYPE_DEFN(CFBoolean); 195 TYPE_NAME_FOR_CF_TYPE_DEFN(CFBoolean);
196 TYPE_NAME_FOR_CF_TYPE_DEFN(CFData); 196 TYPE_NAME_FOR_CF_TYPE_DEFN(CFData);
197 TYPE_NAME_FOR_CF_TYPE_DEFN(CFDate); 197 TYPE_NAME_FOR_CF_TYPE_DEFN(CFDate);
198 TYPE_NAME_FOR_CF_TYPE_DEFN(CFDictionary); 198 TYPE_NAME_FOR_CF_TYPE_DEFN(CFDictionary);
199 TYPE_NAME_FOR_CF_TYPE_DEFN(CFNull); 199 TYPE_NAME_FOR_CF_TYPE_DEFN(CFNull);
200 TYPE_NAME_FOR_CF_TYPE_DEFN(CFNumber); 200 TYPE_NAME_FOR_CF_TYPE_DEFN(CFNumber);
201 TYPE_NAME_FOR_CF_TYPE_DEFN(CFSet); 201 TYPE_NAME_FOR_CF_TYPE_DEFN(CFSet);
202 TYPE_NAME_FOR_CF_TYPE_DEFN(CFString); 202 TYPE_NAME_FOR_CF_TYPE_DEFN(CFString);
203 203
204 TYPE_NAME_FOR_CF_TYPE_DEFN(CGColor);
205
206 TYPE_NAME_FOR_CF_TYPE_DEFN(CTFont);
207 TYPE_NAME_FOR_CF_TYPE_DEFN(CTRun);
208
204 #undef TYPE_NAME_FOR_CF_TYPE_DEFN 209 #undef TYPE_NAME_FOR_CF_TYPE_DEFN
205 210
206 void NSObjectRetain(void* obj) { 211 void NSObjectRetain(void* obj) {
207 id<NSObject> nsobj = static_cast<id<NSObject> >(obj); 212 id<NSObject> nsobj = static_cast<id<NSObject> >(obj);
208 [nsobj retain]; 213 [nsobj retain];
209 } 214 }
210 215
211 void NSObjectRelease(void* obj) { 216 void NSObjectRelease(void* obj) {
212 id<NSObject> nsobj = static_cast<id<NSObject> >(obj); 217 id<NSObject> nsobj = static_cast<id<NSObject> >(obj);
213 [nsobj release]; 218 [nsobj release];
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after
322 CF_CAST_DEFN(CFBag); 327 CF_CAST_DEFN(CFBag);
323 CF_CAST_DEFN(CFBoolean); 328 CF_CAST_DEFN(CFBoolean);
324 CF_CAST_DEFN(CFData); 329 CF_CAST_DEFN(CFData);
325 CF_CAST_DEFN(CFDate); 330 CF_CAST_DEFN(CFDate);
326 CF_CAST_DEFN(CFDictionary); 331 CF_CAST_DEFN(CFDictionary);
327 CF_CAST_DEFN(CFNull); 332 CF_CAST_DEFN(CFNull);
328 CF_CAST_DEFN(CFNumber); 333 CF_CAST_DEFN(CFNumber);
329 CF_CAST_DEFN(CFSet); 334 CF_CAST_DEFN(CFSet);
330 CF_CAST_DEFN(CFString); 335 CF_CAST_DEFN(CFString);
331 336
337 CF_CAST_DEFN(CGColor);
338
339 CF_CAST_DEFN(CTFont);
340 CF_CAST_DEFN(CTRun);
341
332 #if !defined(OS_IOS) 342 #if !defined(OS_IOS)
333 CF_CAST_DEFN(SecACL); 343 CF_CAST_DEFN(SecACL);
334 CF_CAST_DEFN(SecTrustedApplication); 344 CF_CAST_DEFN(SecTrustedApplication);
335 #endif 345 #endif
336 346
337 #undef CF_CAST_DEFN 347 #undef CF_CAST_DEFN
338 348
339 std::string GetValueFromDictionaryErrorMessage( 349 std::string GetValueFromDictionaryErrorMessage(
340 CFStringRef key, const std::string& expected_type, CFTypeRef value) { 350 CFStringRef key, const std::string& expected_type, CFTypeRef value) {
341 ScopedCFTypeRef<CFStringRef> actual_type_ref( 351 ScopedCFTypeRef<CFStringRef> actual_type_ref(
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
378 CFDictionaryGetValue(user_info.get(), kCFErrorDescriptionKey)); 388 CFDictionaryGetValue(user_info.get(), kCFErrorDescriptionKey));
379 } 389 }
380 o << "Code: " << CFErrorGetCode(err) 390 o << "Code: " << CFErrorGetCode(err)
381 << " Domain: " << CFErrorGetDomain(err) 391 << " Domain: " << CFErrorGetDomain(err)
382 << " Desc: " << desc.get(); 392 << " Desc: " << desc.get();
383 if(errorDesc) { 393 if(errorDesc) {
384 o << "(" << errorDesc << ")"; 394 o << "(" << errorDesc << ")";
385 } 395 }
386 return o; 396 return o;
387 } 397 }
OLDNEW
« no previous file with comments | « base/mac/foundation_util.h ('k') | skia/ext/skia_utils_mac.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698