1cb93a386Sopenharmony_ci#if 0  // Disabled until updated to use current API.
2cb93a386Sopenharmony_ci// Copyright 2019 Google LLC.
3cb93a386Sopenharmony_ci// Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.
4cb93a386Sopenharmony_ci#include "tools/fiddle/examples.h"
5cb93a386Sopenharmony_ci// HASH=e311cdd451edacec33b50cc22a4dd5dc
6cb93a386Sopenharmony_ciREG_FIDDLE(Path_lineTo, 256, 100, false, 0) {
7cb93a386Sopenharmony_civoid draw(SkCanvas* canvas) {
8cb93a386Sopenharmony_ci    SkPaint paint;
9cb93a386Sopenharmony_ci    paint.setAntiAlias(true);
10cb93a386Sopenharmony_ci    paint.setTextSize(72);
11cb93a386Sopenharmony_ci    canvas->drawString("#", 120, 80, paint);
12cb93a386Sopenharmony_ci    paint.setStyle(SkPaint::kStroke_Style);
13cb93a386Sopenharmony_ci    paint.setStrokeWidth(5);
14cb93a386Sopenharmony_ci    SkPath path;
15cb93a386Sopenharmony_ci    SkPoint hash[] = {{58, 28}, {43, 80}, {37, 45}, {85, 45}};
16cb93a386Sopenharmony_ci    SkVector offsets[] = {{0, 0}, {17, 0}, {0, 0}, {-5, 17}};
17cb93a386Sopenharmony_ci    unsigned o = 0;
18cb93a386Sopenharmony_ci    for (unsigned i = 0; i < SK_ARRAY_COUNT(hash); i += 2) {
19cb93a386Sopenharmony_ci        for (unsigned j = 0; j < 2; o++, j++) {
20cb93a386Sopenharmony_ci            path.moveTo(hash[i].fX + offsets[o].fX, hash[i].fY + offsets[o].fY);
21cb93a386Sopenharmony_ci            path.lineTo(hash[i + 1].fX + offsets[o].fX, hash[i + 1].fY + offsets[o].fY);
22cb93a386Sopenharmony_ci        }
23cb93a386Sopenharmony_ci    }
24cb93a386Sopenharmony_ci    canvas->drawPath(path, paint);
25cb93a386Sopenharmony_ci}
26cb93a386Sopenharmony_ci}  // END FIDDLE
27cb93a386Sopenharmony_ci#endif  // Disabled until updated to use current API.
28