OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2011 Google Inc. | 2 * Copyright 2011 Google Inc. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
6 */ | 6 */ |
7 | 7 |
8 | 8 |
9 #include "gm.h" | 9 #include "gm.h" |
10 #include "SkCanvas.h" | 10 #include "SkCanvas.h" |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
42 // : fFace(SkTypeface::CreateFromName("STIXGeneral", SkTypeface::kNormal
)) | 42 // : fFace(SkTypeface::CreateFromName("STIXGeneral", SkTypeface::kNormal
)) |
43 // : fFace(SkTypeface::CreateFromName("Yuppy SC", SkTypeface::kNormal)) | 43 // : fFace(SkTypeface::CreateFromName("Yuppy SC", SkTypeface::kNormal)) |
44 // : fFace(SkTypeface::CreateFromName("Yuppy TC", SkTypeface::kNormal)) | 44 // : fFace(SkTypeface::CreateFromName("Yuppy TC", SkTypeface::kNormal)) |
45 | 45 |
46 { | 46 { |
47 } | 47 } |
48 | 48 |
49 //SkAutoTUnref<SkTypeface> fFace; | 49 //SkAutoTUnref<SkTypeface> fFace; |
50 | 50 |
51 protected: | 51 protected: |
| 52 virtual uint32_t onGetFlags() const SK_OVERRIDE { |
| 53 return kSkipTiled_Flag; |
| 54 } |
52 | 55 |
53 SkString onShortName() { | 56 SkString onShortName() { |
54 return SkString("verttext"); | 57 return SkString("verttext"); |
55 } | 58 } |
56 | 59 |
57 SkISize onISize() { return make_isize(640, 480); } | 60 SkISize onISize() { return make_isize(640, 480); } |
58 | 61 |
59 static void drawBaseline(SkCanvas* canvas, const SkPaint& paint, | 62 static void drawBaseline(SkCanvas* canvas, const SkPaint& paint, |
60 SkScalar x, SkScalar y) { | 63 SkScalar x, SkScalar y) { |
61 SkScalar total = paint.measureText(gText, gLen); | 64 SkScalar total = paint.measureText(gText, gLen); |
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
111 private: | 114 private: |
112 typedef GM INHERITED; | 115 typedef GM INHERITED; |
113 }; | 116 }; |
114 | 117 |
115 /////////////////////////////////////////////////////////////////////////////// | 118 /////////////////////////////////////////////////////////////////////////////// |
116 | 119 |
117 static GM* MyFactory(void*) { return new VertTextGM; } | 120 static GM* MyFactory(void*) { return new VertTextGM; } |
118 static GMRegistry reg(MyFactory); | 121 static GMRegistry reg(MyFactory); |
119 | 122 |
120 } | 123 } |
OLD | NEW |