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

Side by Side Diff: third_party/harfbuzz-ng/src/hb-coretext.cc

Issue 1551753002: Build third-party code with -Wall, build chromium_code with -Wextra on Linux (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: thestig Created 4 years, 11 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
« no previous file with comments | « third_party/harfbuzz-ng/README.chromium ('k') | third_party/mach_override/BUILD.gn » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright © 2012,2013 Mozilla Foundation. 2 * Copyright © 2012,2013 Mozilla Foundation.
3 * Copyright © 2012,2013 Google, Inc. 3 * Copyright © 2012,2013 Google, Inc.
4 * 4 *
5 * This is part of HarfBuzz, a text shaping library. 5 * This is part of HarfBuzz, a text shaping library.
6 * 6 *
7 * Permission is hereby granted, without written agreement and without 7 * Permission is hereby granted, without written agreement and without
8 * license or royalty fees, to use, copy, modify, and distribute this 8 * license or royalty fees, to use, copy, modify, and distribute this
9 * software and its documentation for any purpose, provided that the 9 * software and its documentation for any purpose, provided that the
10 * above copyright notice and the following two paragraphs appear in 10 * above copyright notice and the following two paragraphs appear in
(...skipping 675 matching lines...) Expand 10 before | Expand all | Expand 10 after
686 FAIL ("Buffer resize failed"); 686 FAIL ("Buffer resize failed");
687 687
688 /* Adjust scratch, pchars, and log_cluster arrays. This is ugly, but really the 688 /* Adjust scratch, pchars, and log_cluster arrays. This is ugly, but really the
689 * cleanest way to do without completely restructuring the rest of this shap er. */ 689 * cleanest way to do without completely restructuring the rest of this shap er. */
690 scratch = buffer->get_scratch_buffer (&scratch_size); 690 scratch = buffer->get_scratch_buffer (&scratch_size);
691 pchars = reinterpret_cast<UniChar *> (((char *) scratch + ((char *) pchars - (char *) old_scratch))); 691 pchars = reinterpret_cast<UniChar *> (((char *) scratch + ((char *) pchars - (char *) old_scratch)));
692 log_clusters = reinterpret_cast<unsigned int *> (((char *) scratch + ((char *) log_clusters - (char *) old_scratch))); 692 log_clusters = reinterpret_cast<unsigned int *> (((char *) scratch + ((char *) log_clusters - (char *) old_scratch)));
693 scratch += old_scratch_used; 693 scratch += old_scratch_used;
694 scratch_size -= old_scratch_used; 694 scratch_size -= old_scratch_used;
695 } 695 }
696 retry:
697 { 696 {
698 string_ref = CFStringCreateWithCharactersNoCopy (NULL, 697 string_ref = CFStringCreateWithCharactersNoCopy (NULL,
699 pchars, chars_len, 698 pchars, chars_len,
700 kCFAllocatorNull); 699 kCFAllocatorNull);
701 if (unlikely (!string_ref)) 700 if (unlikely (!string_ref))
702 FAIL ("CFStringCreateWithCharactersNoCopy failed"); 701 FAIL ("CFStringCreateWithCharactersNoCopy failed");
703 702
704 /* Create an attributed string, populate it, and create a line from it, then release attributed string. */ 703 /* Create an attributed string, populate it, and create a line from it, then release attributed string. */
705 { 704 {
706 CFMutableAttributedStringRef attr_string = CFAttributedStringCreateMutable (kCFAllocatorDefault, 705 CFMutableAttributedStringRef attr_string = CFAttributedStringCreateMutable (kCFAllocatorDefault,
(...skipping 415 matching lines...) Expand 10 before | Expand all | Expand 10 after
1122 CFRelease (range_records[i].font); 1121 CFRelease (range_records[i].font);
1123 1122
1124 return ret; 1123 return ret;
1125 } 1124 }
1126 1125
1127 1126
1128 /* 1127 /*
1129 * AAT shaper 1128 * AAT shaper
1130 */ 1129 */
1131 1130
1132 HB_SHAPER_DATA_ENSURE_DECLARE(coretext_aat, face)
1133 HB_SHAPER_DATA_ENSURE_DECLARE(coretext_aat, font)
1134
1135
1136 /* 1131 /*
1137 * shaper face data 1132 * shaper face data
1138 */ 1133 */
1139 1134
1140 struct hb_coretext_aat_shaper_face_data_t {}; 1135 struct hb_coretext_aat_shaper_face_data_t {};
1141 1136
1142 hb_coretext_aat_shaper_face_data_t * 1137 hb_coretext_aat_shaper_face_data_t *
1143 _hb_coretext_aat_shaper_face_data_create (hb_face_t *face) 1138 _hb_coretext_aat_shaper_face_data_create (hb_face_t *face)
1144 { 1139 {
1145 hb_blob_t *mort_blob = face->reference_table (HB_CORETEXT_TAG_MORT); 1140 hb_blob_t *mort_blob = face->reference_table (HB_CORETEXT_TAG_MORT);
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
1210 1205
1211 hb_bool_t 1206 hb_bool_t
1212 _hb_coretext_aat_shape (hb_shape_plan_t *shape_plan, 1207 _hb_coretext_aat_shape (hb_shape_plan_t *shape_plan,
1213 hb_font_t *font, 1208 hb_font_t *font,
1214 hb_buffer_t *buffer, 1209 hb_buffer_t *buffer,
1215 const hb_feature_t *features, 1210 const hb_feature_t *features,
1216 unsigned int num_features) 1211 unsigned int num_features)
1217 { 1212 {
1218 return _hb_coretext_shape (shape_plan, font, buffer, features, num_features); 1213 return _hb_coretext_shape (shape_plan, font, buffer, features, num_features);
1219 } 1214 }
OLDNEW
« no previous file with comments | « third_party/harfbuzz-ng/README.chromium ('k') | third_party/mach_override/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698