
Hi Vladimir, Thanks for your comments! On Apr 1, 2004, at 1:49 AM, Vladimir Prus wrote:
Specifically, there reference is really lacking -- for example, try to figure out what the 'make_label_writer' function does
That is documented in write-graphviz.html. Did you find the explanation there hard to understand? (In general, I'm not particularly happy with the read/write graphviz interface, but I don't have time now to do a redesign)
and in what header it's defined.
I've added a "Where Defined" section.
I remember that I had similiar question about a bunch of other functions, too.
When you hit one, let me know.
Another issue is that I never seem to remember how event visitors work and have to look it up in documentation, which invariably requires looking at 3 or 4 separate pages.
Any suggestions on how to improve this?
My favourite problem is external property maps. I really think that I should be able to just run
topological_sort(G, back_inserter(order));
and don't bother if 'G' has vertex_index_t property or not. Currently, if I use anything else than vecS for vertex storage, the above code won't compile.
So is your problem with external property maps, or with some graphs that don't provide a vertex index property?
Generally, most of the time I assume that all vertex descriptors are integers, and don't try to write really generic code, because I suspect it too much work.
I should admit that basic operations like iteration over adjacent vertices are fine -- they are a bit verbose, but it's not a big problem.
[snip]
To tell the truth, I have no idea how to specify vertex properties when adding vertex, so maybe this is the thing to improve first. We might have:
add_vertex(g, "brother");
This is how: add_vertex(std::string("brother"), g) or more explicitly: add_vertex(property<vertex_name_t,std::string>("brother"), g) which I have to admit is pretty ugly. Perhaps one way to avoid the complication of using the property class would be to provide some support for the use of a plain struct where each member is a vertex property.
we can also have a way to find a vertex with specific value of specific property:
find(g, vertex_name, "brother")
Sure. Write it up and we'll add it :) It should only be a few lines of code. Cheers, Jeremy _______________________________________________ Jeremy Siek <jsiek@osl.iu.edu> http://www.osl.iu.edu/~jsiek Ph.D. Student, Indiana University Bloomington Graduating in August 2004 and looking for work C++ Booster (http://www.boost.org) _______________________________________________