From ccaf24e5125386f6c8d2c157cca03b04f7235c7b Mon Sep 17 00:00:00 2001 From: =?utf8?q?Alexis=20Laferri=C3=A8re?= Date: Fri, 11 Dec 2015 21:17:53 -0500 Subject: [PATCH] contrib/inkscape_tools: update support for gamnit MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Alexis Laferrière --- contrib/inkscape_tools/src/svg_to_png_and_nit.nit | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/contrib/inkscape_tools/src/svg_to_png_and_nit.nit b/contrib/inkscape_tools/src/svg_to_png_and_nit.nit index abd0912..d762c11 100644 --- a/contrib/inkscape_tools/src/svg_to_png_and_nit.nit +++ b/contrib/inkscape_tools/src/svg_to_png_and_nit.nit @@ -191,14 +191,14 @@ class GamnitImageSetSrc # Attributes of the class var attributes = new Array[String] - attributes.add "\tprivate var main_image = new Texture(\"images/{document.drawing_name}.png\")\n" + attributes.add "\tprivate var root_texture = new Texture(\"images/{document.drawing_name}.png\")\n" # Add single images to Nit source file for image in single_images do # Adapt coordinates to new top left and scale var coordinates = document.coordinates(image) - attributes.add "\tvar {image.name}: Texture = main_image.subtexture({coordinates})\n" + attributes.add "\tvar {image.name}: Texture = root_texture.subtexture({coordinates})\n" end # Add array of images too @@ -224,7 +224,7 @@ class GamnitImageSetSrc add """ # File generated by svg_to_png_and_nit, do not modify, redef instead -import gamnit::display +import gamnit::textures class {{{document.nit_class_name}}} -- 1.7.9.5