зеркало из https://github.com/mozilla/moz-skia.git
Sanitizing source files in Housekeeper-Nightly
git-svn-id: http://skia.googlecode.com/svn/trunk@9882 2bbb7eff-a529-9590-31e7-b0007b416f81
This commit is contained in:
Родитель
c631b792c4
Коммит
98a196770c
|
@ -46,7 +46,7 @@ static void charsToGlyphs_proc(const SkPaint& paint, const void* text,
|
|||
SkTypeface::Encoding encoding = paint2Encoding(paint);
|
||||
uint16_t glyphs[NGLYPHS];
|
||||
SkASSERT(glyphCount <= NGLYPHS);
|
||||
|
||||
|
||||
SkTypeface* face = paint.getTypeface();
|
||||
for (int i = 0; i < LOOP; ++i) {
|
||||
face->charsToGlyphs(text, encoding, glyphs, glyphCount);
|
||||
|
@ -56,7 +56,7 @@ static void charsToGlyphs_proc(const SkPaint& paint, const void* text,
|
|||
static void charsToGlyphsNull_proc(const SkPaint& paint, const void* text,
|
||||
size_t len, int glyphCount) {
|
||||
SkTypeface::Encoding encoding = paint2Encoding(paint);
|
||||
|
||||
|
||||
SkTypeface* face = paint.getTypeface();
|
||||
for (int i = 0; i < LOOP; ++i) {
|
||||
face->charsToGlyphs(text, encoding, NULL, glyphCount);
|
||||
|
@ -73,7 +73,7 @@ public:
|
|||
CMAPBench(void* param, TypefaceProc proc, const char name[]) : SkBenchmark(param) {
|
||||
fProc = proc;
|
||||
fName.printf("cmap_%s", name);
|
||||
|
||||
|
||||
for (int i = 0; i < NGLYPHS; ++i) {
|
||||
// we're jamming values into utf8, so we must keep it legal utf8
|
||||
fText[i] = 'A' + (i & 31);
|
||||
|
@ -101,4 +101,3 @@ DEF_BENCH( return new CMAPBench(p, containsText_proc, "paint_containsText"); )
|
|||
DEF_BENCH( return new CMAPBench(p, textToGlyphs_proc, "paint_textToGlyphs"); )
|
||||
DEF_BENCH( return new CMAPBench(p, charsToGlyphs_proc, "face_charsToGlyphs"); )
|
||||
DEF_BENCH( return new CMAPBench(p, charsToGlyphsNull_proc, "face_charsToGlyphs_null"); )
|
||||
|
||||
|
|
|
@ -1,2 +1 @@
|
|||
#include "SkPdfUtils.h"
|
||||
|
||||
|
|
|
@ -1,4 +1,2 @@
|
|||
|
||||
#include "SkPdfNYI.h"
|
||||
|
||||
|
||||
|
|
|
@ -9,4 +9,3 @@ SkNativeParsedPDF::SkNativeParsedPDF() {
|
|||
SkNativeParsedPDF::~SkNativeParsedPDF() {
|
||||
// TODO(edisonn): Auto-generated destructor stub
|
||||
}
|
||||
|
||||
|
|
|
@ -9,4 +9,3 @@ SkPdfNativeTokenizer::SkPdfNativeTokenizer() {
|
|||
SkPdfNativeTokenizer::~SkPdfNativeTokenizer() {
|
||||
// TODO(edisonn): Auto-generated destructor stub
|
||||
}
|
||||
|
||||
|
|
|
@ -191,4 +191,3 @@ void SkTraceRect(const SkRect& rect, const char* sz) {
|
|||
printf("\n");
|
||||
}
|
||||
#endif
|
||||
|
||||
|
|
|
@ -412,5 +412,3 @@ bool StreamFromDictionary(const SkPodofoParsedPDF* pdfDoc,
|
|||
if (abr == NULL || *abr == '\0') return false;
|
||||
return StreamFromDictionary(pdfDoc, dict, abr, data);
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -82,14 +82,14 @@ static void test_cmap(skiatest::Reporter* reporter) {
|
|||
}
|
||||
// inject some random chars, to sometimes abort early
|
||||
src[rand.nextU() & 63] = rand.nextU() & 0xFFF;
|
||||
|
||||
|
||||
for (size_t k = 0; k < SK_ARRAY_COUNT(gRec); ++k) {
|
||||
paint.setTextEncoding(gRec[k].fEncoding);
|
||||
|
||||
size_t len = gRec[k].fSeedTextProc(src, dst, NGLYPHS);
|
||||
|
||||
|
||||
uint16_t glyphs0[NGLYPHS], glyphs1[NGLYPHS];
|
||||
|
||||
|
||||
bool contains = paint.containsText(dst, len);
|
||||
int nglyphs = paint.textToGlyphs(dst, len, glyphs0);
|
||||
int first = face->charsToGlyphs(dst, paint2encoding(paint), glyphs1, NGLYPHS);
|
||||
|
@ -231,7 +231,7 @@ static void TestPaint(skiatest::Reporter* reporter) {
|
|||
regression_measureText(reporter);
|
||||
|
||||
test_bicubic(reporter);
|
||||
|
||||
|
||||
// need to implement charsToGlyphs on other backends (e.g. linux, win)
|
||||
// before we can run this tests everywhere
|
||||
if (false) {
|
||||
|
|
Загрузка…
Ссылка в новой задаче