valadoc r23 - in trunk/src: libvaladoc valadoc



Author: flobrosch
Date: Sun Dec  7 15:43:55 2008
New Revision: 23
URL: http://svn.gnome.org/viewvc/valadoc?rev=23&view=rev

Log:

 -



Modified:
   trunk/src/libvaladoc/doctree.vala
   trunk/src/libvaladoc/parser.vala
   trunk/src/valadoc/valadoc.vala

Modified: trunk/src/libvaladoc/doctree.vala
==============================================================================
--- trunk/src/libvaladoc/doctree.vala	(original)
+++ trunk/src/libvaladoc/doctree.vala	Sun Dec  7 15:43:55 2008
@@ -178,6 +178,21 @@
 		}
 	}
 
+	public string?# filename {
+		get {
+			SourceReference? sref = this.vsymbol.source_reference;
+			if ( sref == null )
+				return null;
+
+			Vala.SourceFile? file = sref.file;
+			if ( file == null )
+				return null;
+
+			string path = sref.file.filename;
+			return GLib.Path.get_basename ( path );
+		}
+	}
+
 	protected string? comment_string  {
 		get {
 			SourceReference sref = this.vsymbol.source_reference;

Modified: trunk/src/libvaladoc/parser.vala
==============================================================================
--- trunk/src/libvaladoc/parser.vala	(original)
+++ trunk/src/libvaladoc/parser.vala	Sun Dec  7 15:43:55 2008
@@ -29,11 +29,6 @@
 
 public static delegate GLib.Type TagletRegisterFunction ( Gee.HashMap<string, Type> taglets );
 
-
-
-
-
-
 public abstract class DocElement : Object {
 	public abstract bool write ( void* res, int max, int index );
 }
@@ -228,53 +223,6 @@
 
 
 
-/** Start Testtaglets **
-
-public class ReturnHtmlTaglet : MainTaglet {
-	public override int order { get { return 90000; } }
-	private Gee.Collection<DocElement> content;
-
-	public override bool parse ( Tree tree, Basic me, Gee.Collection<DocElement> content, out string[] errmsg ) {
-		this.content = content;
-		return true;
-	}
-
-	public override bool write_block_start ( void* ptr ) {
-		weak GLib.FileStream file = (GLib.FileStream)ptr;
-		file.printf ( "<h2 class=\"%s\">Returns:</h2>\n", css_title );
-		return true;
-	}
-
-	public override bool write_block_end ( void* res ) {
-		return true;
-	}
-
-	public override bool write ( void* res, int max, int index ) {
-		int _max = this.content.size;
-		int _index = 0;
-
-		foreach ( DocElement tag in this.content ) {
-			tag.write ( res, _max, _index );
-			_index++;
-		}
-		return true;
-	}
-}
-
-public class LinkHtmlInlineTaglet : InlineTaglet {
-	string content;
-
-	public override bool parse ( Tree tree, Basic me, string content, out string[] errmsg ) {
-		this.content = content;
-		return true;
-	}
-
-	public override bool write ( void* res, int max, int index ) {
-		stdout.printf ( "(%s)", content );
-		return true;
-	}
-}
-/** Ende Testtaglets **/
 
 
 
@@ -586,6 +534,8 @@
 		int starttag_pos = 0;
 		int paragraph = 0;
 
+		this.filename = me.filename;
+
 		this.linestartpos = 0;
 		this.startpos = 0;
 		this.line = 0;
@@ -595,7 +545,6 @@
 		this.str = str;
 		this.line = 0;
 
-		this.filename = "fooo";
 
 		bool tmp = this.skip_documentation_header ();
 		if ( tmp == false ) {

Modified: trunk/src/valadoc/valadoc.vala
==============================================================================
--- trunk/src/valadoc/valadoc.vala	(original)
+++ trunk/src/valadoc/valadoc.vala	Sun Dec  7 15:43:55 2008
@@ -445,7 +445,6 @@
 
 		if ( this.tsources != null ) {
 			foreach ( string src in this.tsources ) {
-				stdout.printf ( ">__>%s\n", src );
 				if ( !doctree.add_file ( src ) ) {
 					Report.error (null, "%s not found".printf (src));
 					return quit ();



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]