title: How to visualize a binary tree in C++
body: <p>When I have implemented binary trees, one of the first utilities one writes is a visualization function that given a tree prints it to the screen.</p>
  
  <p>Using cout function to print it every time like a stack is a problem for me, I can't represent the value of my job.</p>
  
  <p>Printing trees properly in ASCII is quite difficult to understand. Meanwhile, it can't represent your tree and your operations in clear view.</p>
  
  <p>With some research I found a tool named Graphviz – Graph Visualization Software – which uses a language (called DOT) and a set of tools for automatically generating visualizations of graphs. Graphviz is a tool for drawing graphs, not trees, so I can't use it; and implementing the C++ code for this is very difficult.</p>
  
  <p>I'm searching for some code, algorithm or method to show my tree. I'm thinking to use some libraries like GTK, QT, STL or WPF, becase I'm working with Visual Studio C++.</p>
  
  <p>Is it possible to use them? Which is best suited?</p>