| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2013 Google Inc. | 2 * Copyright 2013 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 #include "SkLua.h" | 8 #include "SkLua.h" |
| 9 #include "SkCanvas.h" | 9 #include "SkCanvas.h" |
| 10 #include "SkData.h" | 10 #include "SkData.h" |
| (...skipping 627 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 638 SkLua(L).pushU32(get_obj<SkPaint>(L, 1)->getStrokeCap()); | 638 SkLua(L).pushU32(get_obj<SkPaint>(L, 1)->getStrokeCap()); |
| 639 return 1; | 639 return 1; |
| 640 } | 640 } |
| 641 | 641 |
| 642 static int lpaint_getStrokeJoin(lua_State* L) { | 642 static int lpaint_getStrokeJoin(lua_State* L) { |
| 643 SkLua(L).pushU32(get_obj<SkPaint>(L, 1)->getStrokeJoin()); | 643 SkLua(L).pushU32(get_obj<SkPaint>(L, 1)->getStrokeJoin()); |
| 644 return 1; | 644 return 1; |
| 645 } | 645 } |
| 646 | 646 |
| 647 static int lpaint_getTextEncoding(lua_State* L) { | 647 static int lpaint_getTextEncoding(lua_State* L) { |
| 648 SkLua(L).pushScalar(static_cast<SkScalar>(get_obj<SkPaint>(L, 1)->getTextEnc
oding())); | 648 SkLua(L).pushU32(get_obj<SkPaint>(L, 1)->getTextEncoding()); |
| 649 return 1; | 649 return 1; |
| 650 } | 650 } |
| 651 | 651 |
| 652 static int lpaint_getStrokeWidth(lua_State* L) { | 652 static int lpaint_getStrokeWidth(lua_State* L) { |
| 653 SkLua(L).pushScalar(get_obj<SkPaint>(L, 1)->getStrokeWidth()); | 653 SkLua(L).pushScalar(get_obj<SkPaint>(L, 1)->getStrokeWidth()); |
| 654 return 1; | 654 return 1; |
| 655 } | 655 } |
| 656 | 656 |
| 657 static int lpaint_setStrokeWidth(lua_State* L) { | 657 static int lpaint_setStrokeWidth(lua_State* L) { |
| 658 get_obj<SkPaint>(L, 1)->setStrokeWidth(lua2scalar(L, 2)); | 658 get_obj<SkPaint>(L, 1)->setStrokeWidth(lua2scalar(L, 2)); |
| (...skipping 569 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1228 REG_CLASS(L, SkShader); | 1228 REG_CLASS(L, SkShader); |
| 1229 REG_CLASS(L, SkTypeface); | 1229 REG_CLASS(L, SkTypeface); |
| 1230 REG_CLASS(L, SkMatrix); | 1230 REG_CLASS(L, SkMatrix); |
| 1231 } | 1231 } |
| 1232 | 1232 |
| 1233 extern "C" int luaopen_skia(lua_State* L); | 1233 extern "C" int luaopen_skia(lua_State* L); |
| 1234 extern "C" int luaopen_skia(lua_State* L) { | 1234 extern "C" int luaopen_skia(lua_State* L) { |
| 1235 SkLua::Load(L); | 1235 SkLua::Load(L); |
| 1236 return 0; | 1236 return 0; |
| 1237 } | 1237 } |
| OLD | NEW |