Clone in a terminal:
Commit e4dcce9
Johan Mattsson - 2015-05-22T10:47:11+00:00
e4dcce931200cb9b7517d6ac3635743fb6df8c9fjohan.mattsson.m@gmail.com

Remove debug info

Changed files (10)

Diff

diff --git a/libbirdfont/BirdFontFile.vala b/libbirdfont/BirdFontFile.valaindex 38ded00..dd32490 100644--- a/libbirdfont/BirdFontFile.vala+++ b/libbirdfont/BirdFontFile.vala@@ -1136,16 +1136,12 @@ class BirdFontFile : GLib.Object { 		foreach (Tag t in tag) {			 			if (t.get_name () == "glyph") { 				parse_glyph (t, gc, name, unicode, selected_id, unassigned);-				-				print (@"g e2: $(gc.get_current ().ref_count)\n"); 			} 		} 		 		if (new_glyph_collection) { 			font.add_glyph_collection (gc); 		}-		-		print (@"g 2: $(gc.get_current ().ref_count)\n"); 	}  	private int parse_selected (Tag tag) {@@ -1214,10 +1210,8 @@ class BirdFontFile : GLib.Object { 		glyph.version_id = (has_id) ? id : (int) gc.length () + 1; 		gc.set_unassigned (unassigned); 		-		print (@"i parse_glyph $(glyph.ref_count)\n"); 		gc.insert_glyph (glyph, selected || selected_id == id); 		glyph = new Glyph.no_lines ("");-		print (@"i2 parse_glyph $(glyph.ref_count)\n"); 	}  	private Path parse_path (Tag tag) {	diff --git a/libbirdfont/EditPoint.vala b/libbirdfont/EditPoint.valaindex 6b55ef0..bb36d98 100644--- a/libbirdfont/EditPoint.vala+++ b/libbirdfont/EditPoint.vala@@ -188,7 +188,6 @@ public class EditPoint : GLib.Object { 		} 		 		n_points++;-		print (@"n_points: $(n_points)\n"); 	}  	~EditPoint () {diff --git a/libbirdfont/EditPointHandle.vala b/libbirdfont/EditPointHandle.valaindex 661b806..9fe598b 100644--- a/libbirdfont/EditPointHandle.vala+++ b/libbirdfont/EditPointHandle.vala@@ -100,8 +100,6 @@ public class EditPointHandle : GLib.Object { 		this.selected = false; 		 		n_handles++;-		-		print (@"EditPointHandle $(n_handles)\n"); 	}  	~EditPointHandle () {diff --git a/libbirdfont/Glyph.vala b/libbirdfont/Glyph.valaindex 7585bf8..fe38e4b 100644--- a/libbirdfont/Glyph.vala+++ b/libbirdfont/Glyph.vala@@ -121,9 +121,7 @@ public class Glyph : FontDisplay { 		left_limit = -28; 		right_limit = 28; 		-		n_instances++;-		-		warning (@"glyphs $name: $(n_instances)");+		n_instances++;		 	}  	public Glyph.no_lines (string name, unichar unichar_code = 0) {@@ -133,7 +131,6 @@ public class Glyph : FontDisplay { 		path_list.add (new Path ()); 		 		n_instances++;-		warning (@"glyphs no lines $name: $(n_instances)"); 	} 	 	static int n_instances = 0;diff --git a/libbirdfont/GlyphCollection.vala b/libbirdfont/GlyphCollection.valaindex 5a4c286..3ba152e 100644--- a/libbirdfont/GlyphCollection.vala+++ b/libbirdfont/GlyphCollection.vala@@ -26,9 +26,7 @@ public class GlyphCollection : GLib.Object { 	public GlyphCollection (unichar unicode_character, string name) { 		this.unicode_character = unicode_character; 		this.name = name;-		print (@"GlyphCollection: $(ref_count)\n"); 		versions = new VersionList (null, this);-		print (@"Afer version list GlyphCollection: $(ref_count)\n"); 	}  	public GlyphCollection.with_glyph (unichar unicode_character, string name) {@@ -38,10 +36,7 @@ public class GlyphCollection : GLib.Object { 		this.name = name; 		 		g = new Glyph (name, unicode_character);-		-		print (@"GlyphCollection: $(ref_count)\n"); 		versions = new VersionList (g, this);-		print (@"Afer version list GlyphCollection: $(ref_count)\n"); 	}  	~GlyphCollection () {@@ -69,9 +64,7 @@ public class GlyphCollection : GLib.Object { 	} 	 	public void insert_glyph (Glyph g, bool selected) {-		print (@"Before VersionList $(g.ref_count)\n"); 		versions.add_glyph (g, selected);-		print (@"After VersionList $(g.ref_count)\n"); 		assert (versions.glyphs.size > 0); 	} 	diff --git a/libbirdfont/Path.vala b/libbirdfont/Path.valaindex 3d46193..75e484a 100644--- a/libbirdfont/Path.vala+++ b/libbirdfont/Path.vala@@ -97,7 +97,6 @@ public class Path { 		} 	 		n_paths++;-		print (@"Paths: $n_paths\n"); 	}  	~Path () {diff --git a/libbirdfont/Renderer/FallbackFont.vala b/libbirdfont/Renderer/FallbackFont.valaindex a1fa9cf..8144ead 100644--- a/libbirdfont/Renderer/FallbackFont.vala+++ b/libbirdfont/Renderer/FallbackFont.vala@@ -112,7 +112,6 @@ public class FallbackFont : GLib.Object { 	 	public Font get_single_glyph_font (unichar c) { 		Font f = load_glyph_from_ttf (c);-		print (@"font e1 : $(f.ref_count)\n"); 		return f; 	} 	@@ -123,24 +122,15 @@ public class FallbackFont : GLib.Object { 		 		bf_font = new Font (); 		-		if (bf_font != null)-			print (@"font e1 a : $(((!)bf_font).ref_count)\n");-		 		for (int i = fallback_fonts.size - 1; i >= 0; i--) { 			f = fallback_fonts.get (i); 			 			font = open_font ((!) f.get_path ()); 			bf_font = get_glyph_in_font ((!) font, c); 			-			if (bf_font != null)-				print (@"font e1 b : $(((!)bf_font).ref_count)\n");-			 			close_font (font); 			 			if (bf_font != null) {-				if (((!)bf_font).get_glyph_by_name ((!) c.to_string ()) != null)-					print (@"first: $(((!) ((!)bf_font).get_glyph_by_name ((!) c.to_string ())).ref_count)\n");-					 				return (!) bf_font; 			} 		}@@ -154,8 +144,6 @@ public class FallbackFont : GLib.Object { 		BirdFontFile bf_parser; 		Font bf_font = new Font (); 		-		print (@"font e1 before load : $(bf_font.ref_count)\n");-		 		gc = new GlyphCollection (c, (!)c.to_string ());		 		glyph_data = load_glyph (font, (uint) c); @@ -163,17 +151,9 @@ public class FallbackFont : GLib.Object { 			return null; 		} -		print (@"font e1 before parser : $(bf_font.ref_count)\n"); 		bf_parser = new BirdFontFile (bf_font);-		print (@"font e2 before parser1 : $(bf_font.ref_count)\n"); 		bf_parser.load_data (((!) glyph_data).str);-		print (@"font e1 before parser load : $(bf_font.ref_count)\n");--		if (((!)bf_font).get_glyph_by_name ((!) c.to_string ()) != null)-			print (@"after parser: $(((!) ((!)bf_font).get_glyph_by_name ((!) c.to_string ())).ref_count)\n");- 		bf_parser = new BirdFontFile (new Font ());-		print (@"font e1 after remove parser : $(bf_font.ref_count)\n"); 					 		return bf_font; 	}diff --git a/libbirdfont/Renderer/FontCache.vala b/libbirdfont/Renderer/FontCache.valaindex 8a6c241..e234265 100644--- a/libbirdfont/Renderer/FontCache.vala+++ b/libbirdfont/Renderer/FontCache.vala@@ -112,8 +112,6 @@ public class FontCache { 			} 			 			if (g == null && name.char_count () == 1) {-				return null; //FIXME-				 				f = fallback_font.get_single_glyph_font (name.get_char (0)); 				g = f.get_glyph_by_name (name); 				@@ -124,48 +122,8 @@ public class FontCache { 				top_limit = f.top_limit; 				base_line = f.base_line; 				bottom_limit = f.bottom_limit;	-				-				GlyphCollection? gc = f.get_glyph_collection (name);-				if (gc != null) {-					print (@"GC BEFORE UNREF: $(((!)gc).ref_count)\n");-				}-				-				print (@"before bad unref: $(((!)g).ref_count)\n");-				//((!)g).unref (); //FIXME:	-				f = new Font (); // FIXME DELTE-				print (@"after bad unref: $(((!)g).ref_count)\n");--				if (gc != null) {-					print (@"GC AFTER UNREF: $(((!)gc).ref_count)\n");-				}--			}-			-			print (@"font in get_glyph_by_name: $(f.ref_count)\n");--			-			if (g != null) {-				print (@"b: $(((!)g).ref_count)\n");	 			} 					-			-			Glyph tg;-			-			// FIXME: DELETE-			tg = new Glyph ("");-			print (@"tg: $(tg.ref_count)\n");-			-			{-				GlyphCollection tgc = new GlyphCollection ('\0', "");-				tgc.add_glyph (tg);-				-				print (@"after add tg: $(tg.ref_count)\n");-				-				tgc.versions.glyphs.clear ();-			}-			-			print (@"DONE tg: $(tg.ref_count)\n");-			 			return g; 		} 		diff --git a/libbirdfont/Renderer/Text.vala b/libbirdfont/Renderer/Text.valaindex bdedd4d..37dec2a 100644--- a/libbirdfont/Renderer/Text.vala+++ b/libbirdfont/Renderer/Text.vala@@ -58,13 +58,11 @@ public class Text : Widget { 		set_font_size (size); 		set_text (text); 		-		warning (@"ntext: $(ntext)"); 		ntext++; 	}   	~Text () { 		ntext--;-		warning (@"remove ntext: $(ntext)"); 	} 	 	public void use_cache (bool cache) {diff --git a/libbirdfont/VersionList.vala b/libbirdfont/VersionList.valaindex 3e4cadb..679fbf5 100644--- a/libbirdfont/VersionList.vala+++ b/libbirdfont/VersionList.vala@@ -26,8 +26,6 @@ public class VersionList : DropMenu { 	public VersionList (Glyph? g = null, GlyphCollection glyph_collection) { 		base (); 		-		print (@"VersionList: glyph_collection: $(glyph_collection.ref_count)\n");-		 		this.glyph_collection = glyph_collection; 		glyphs = new  Gee.ArrayList<Glyph> (); 		set_direction (MenuDirection.POP_UP);

Contact

Email: johan.mattsson.m@gmail.com
Mastodon: typo.social/@birdfont
GitHub: johanmattssonm
LinkedIn: johan-mattsson-2ab324112