Browse code

Fix most flake8 errors

Peter Hill authored on 02/07/2016 10:27:27 • Jose Fonseca committed on 10/07/2016 08:40:15
Showing 1 changed files
1 1
deleted file mode 100644
... ...
@@ -1,129 +0,0 @@
1
-About _xdot.py_
2
-=================
3
-
4
-_xdot.py_ is an interactive viewer for graphs written in [Graphviz](http://www.graphviz.org/)'s [dot language](http://www.graphviz.org/doc/info/lang.html).
5
-
6
-It uses internally the GraphViz's [xdot output format](http://www.graphviz.org/doc/info/output.html#d:xdot) as an intermediate format, and [PyGTK](http://www.pygtk.org/) and [Cairo](http://cairographics.org/) for rendering.
7
-
8
-_xdot.py_ can be used either as a standalone application from command line, or as a library embedded in your Python application.
9
-
10
-Status
11
-======
12
-
13
-_xdot.py_ script became much more popular than I ever anticipated, and there are several interested in improving it further.  However, for several years now, _xdot.py_ already meets my own needs, and unfortunately I don't have much time for maintaing it myself.
14
-
15
-So I'm looking into transition _xdot.py_ maitenance to [others](https://github.com/jrfonseca/xdot.py/wiki/Forks): either hand over the maintenance _xdot.py_ to a community or indicate an official fork of _xdot.py_.
16
-
17
-I encourage people interested in development of _xdot.py_ to fork the [GitHub repository](https://github.com/jrfonseca/xdot.py), and join the new [mailing list](https://groups.google.com/d/forum/xdot-py).
18
-
19
-Features
20
-========
21
-
22
- * Since it doesn't use bitmaps it is fast and has a small memory footprint.
23
- * Arbitrary zoom.
24
- * Keyboard/mouse navigation.
25
- * Supports events on the nodes with URLs.
26
- * Animated jumping between nodes.
27
- * Highlights node/edge under mouse.
28
-
29
-Known Issues
30
-============
31
-
32
- * Not all xdot attributes are supported or correctly rendered yet. It works well for my applications but YMMV.
33
-
34
- * Text doesn't scale properly to large sizes if font hinting is enabled. I haven't found a reliable way to disable font hinting during rendering yet.
35
-
36
-See also:
37
-
38
-  * [github issue tracker](https://github.com/jrfonseca/xdot.py/issues)
39
-
40
-Screenshots
41
-===========
42
-
43
-[![Profile 1 Screenshot](https://raw.github.com/wiki/jrfonseca/xdot.py/xdot-profile1_small.png)](https://raw.github.com/wiki/jrfonseca/xdot.py/xdot-profile1.png)
44
-[![Profile 2 Screenshot](https://raw.github.com/wiki/jrfonseca/xdot.py/xdot-profile2_small.png)](https://raw.github.com/wiki/jrfonseca/xdot.py/xdot-profile2.png)
45
-[![Control Flow Graph](https://raw.github.com/wiki/jrfonseca/xdot.py/xdot-cfg_small.png)](https://raw.github.com/wiki/jrfonseca/xdot.py/xdot-cfg.png)
46
-
47
-Requirements
48
-============
49
-
50
- * [Python 3](http://www.python.org/download/)
51
-
52
- * [PyGObject bindings for GTK3](https://wiki.gnome.org/action/show/Projects/PyGObject)
53
-
54
- * [Graphviz](http://www.graphviz.org/Download.php)
55
-
56
-Windows users
57
-
58
-Download and install:
59
-
60
- * [Python for Windows](http://www.python.org/download/)
61
-
62
- * [PyGObject bindings for GTK3](https://wiki.gnome.org/action/show/Projects/PyGObject)
63
-
64
- * [Graphviz for Windows](http://www.graphviz.org/Download_windows.php)
65
-
66
-Debian/Ubuntu users
67
-
68
-Run:
69
-
70
-    apt-get install gir1.2-gtk-3.0 python3-gi python3-gi-cairo graphviz
71
-
72
-Usage
73
-=====
74
-
75
-Command Line
76
-
77
-    Usage: 
78
-    	xdot.py [file]
79
-    
80
-    Options:
81
-      -h, --help            show this help message and exit
82
-      -f FILTER, --filter=FILTER
83
-                            graphviz filter: dot, neato, twopi, circo, or fdp
84
-                            [default: dot]
85
-      -n, --no-filter       assume input is already filtered into xdot format (use
86
-                            e.g. dot -Txdot)
87
-      -g GEOMETRY           default window size in form WxH
88
-    
89
-    Shortcuts:
90
-      Up, Down, Left, Right     scroll
91
-      PageUp, +, =              zoom in
92
-      PageDown, -               zoom out
93
-      R                         reload dot file
94
-      F                         find
95
-      Q                         quit
96
-      P                         print
97
-      Escape                    halt animation
98
-      Ctrl-drag                 zoom in/out
99
-      Shift-drag                zooms an area
100
-
101
-If no input file is given then it will read the dot graph from the standard input.
102
-
103
-Embedding
104
-
105
-See included `sample.py` script for an example of how to embedded _xdot.py_ into another application.
106
-
107
-[![Screenshot](https://raw.github.com/wiki/jrfonseca/xdot.py/xdot-sample_small.png)](https://raw.github.com/wiki/jrfonseca/xdot.py/xdot-sample.png)
108
-
109
-Download
110
-========
111
-
112
-  * https://pypi.python.org/pypi/xdot
113
-
114
-  * https://github.com/jrfonseca/xdot.py
115
-
116
-Links
117
-=====
118
-
119
- * [Graphviz homepage](http://www.graphviz.org/)
120
-
121
- * [ZGRViewer](http://zvtm.sourceforge.net/zgrviewer.html) -- another superb graphviz/dot viewer
122
-
123
- * [dot2tex](https://github.com/kjellmf/dot2tex) -- python script to convert xdot output from Graphviz to a series of PSTricks or PGF/TikZ commands.
124
-
125
- * The [PyPy project](http://pypy.org/) also includes an [interactive dot viewer based on graphviz's plain format and the pygame library](http://morepypy.blogspot.com/2008/01/visualizing-python-tokenizer.html).
Browse code

Update PyPy homepage URL.

Jose Fonseca authored on 27/06/2016 13:21:23
Showing 1 changed files
... ...
@@ -126,4 +126,4 @@ Links
126 126
 
127 127
  * [dot2tex](https://github.com/kjellmf/dot2tex) -- python script to convert xdot output from Graphviz to a series of PSTricks or PGF/TikZ commands.
128 128
 
129
- * The [pypy project](http://codespeak.net/pypy/) also includes an [interactive dot viewer based on graphviz's plain format and the pygame library](http://morepypy.blogspot.com/2008/01/visualizing-python-tokenizer.html).
129
+ * The [PyPy project](http://pypy.org/) also includes an [interactive dot viewer based on graphviz's plain format and the pygame library](http://morepypy.blogspot.com/2008/01/visualizing-python-tokenizer.html).
Browse code

Minor updates to the README.

Jose Fonseca authored on 16/05/2016 09:31:33
Showing 1 changed files
... ...
@@ -3,14 +3,14 @@ About _xdot.py_
3 3
 
4 4
 _xdot.py_ is an interactive viewer for graphs written in [Graphviz](http://www.graphviz.org/)'s [dot language](http://www.graphviz.org/doc/info/lang.html).
5 5
 
6
-It uses internally the graphviz's [xdot output format](http://www.graphviz.org/doc/info/output.html#d:xdot) as an intermediate format, and [PyGTK](http://www.pygtk.org/) and [Cairo](http://cairographics.org/) for rendering.
6
+It uses internally the GraphViz's [xdot output format](http://www.graphviz.org/doc/info/output.html#d:xdot) as an intermediate format, and [PyGTK](http://www.pygtk.org/) and [Cairo](http://cairographics.org/) for rendering.
7 7
 
8
-_xdot.py_ can be used either as a standalone application from command line, or as a library embedded in your python application.
8
+_xdot.py_ can be used either as a standalone application from command line, or as a library embedded in your Python application.
9 9
 
10 10
 Status
11 11
 ======
12 12
 
13
-_xdot.py_ script became much more popular than I ever anticipated, and there are several interested in improving it further. However, for several years now, _xdot.py_ already meets my own needs, and unfortunately I don't have much time for maintain it myself.
13
+_xdot.py_ script became much more popular than I ever anticipated, and there are several interested in improving it further.  However, for several years now, _xdot.py_ already meets my own needs, and unfortunately I don't have much time for maintaing it myself.
14 14
 
15 15
 So I'm looking into transition _xdot.py_ maitenance to [others](https://github.com/jrfonseca/xdot.py/wiki/Forks): either hand over the maintenance _xdot.py_ to a community or indicate an official fork of _xdot.py_.
16 16
 
... ...
@@ -31,14 +31,12 @@ Known Issues
31 31
 
32 32
  * Not all xdot attributes are supported or correctly rendered yet. It works well for my applications but YMMV.
33 33
 
34
- * Text doesn't scale properly to large sizes if font hinting is enabled. I haven't find a reliable way to disable font hinting during rendering yet.
34
+ * Text doesn't scale properly to large sizes if font hinting is enabled. I haven't found a reliable way to disable font hinting during rendering yet.
35 35
 
36 36
 See also:
37 37
 
38 38
   * [github issue tracker](https://github.com/jrfonseca/xdot.py/issues)
39 39
 
40
-  * [googlecode issue tracker](https://code.google.com/archive/p/jrfonseca/issues).
41
-
42 40
 Screenshots
43 41
 ===========
44 42
 
Browse code

Added -g option to set default window size.

Dan Fandrich authored on 04/01/2016 22:10:32 • Jose Fonseca committed on 29/04/2016 23:03:24
Showing 1 changed files
... ...
@@ -89,6 +89,7 @@ Command Line
89 89
                             [default: dot]
90 90
       -n, --no-filter       assume input is already filtered into xdot format (use
91 91
                             e.g. dot -Txdot)
92
+      -g GEOMETRY           default window size in form WxH
92 93
     
93 94
     Shortcuts:
94 95
       Up, Down, Left, Right     scroll
Browse code

Update apt-get command line.

Jose Fonseca authored on 14/02/2016 20:29:56
Showing 1 changed files
... ...
@@ -71,7 +71,7 @@ Debian/Ubuntu users
71 71
 
72 72
 Run:
73 73
 
74
-    apt-get install python3-gi-cairo graphviz
74
+    apt-get install gir1.2-gtk-3.0 python3-gi python3-gi-cairo graphviz
75 75
 
76 76
 Usage
77 77
 =====
Browse code

Update Google Code URLs.

Jose Fonseca authored on 01/12/2015 10:05:03
Showing 1 changed files
... ...
@@ -37,7 +37,7 @@ See also:
37 37
 
38 38
   * [github issue tracker](https://github.com/jrfonseca/xdot.py/issues)
39 39
 
40
-  * [googlecode issue tracker](https://code.google.com/p/jrfonseca/issues/list?q=xdot).
40
+  * [googlecode issue tracker](https://code.google.com/archive/p/jrfonseca/issues).
41 41
 
42 42
 Screenshots
43 43
 ===========
... ...
@@ -125,6 +125,6 @@ Links
125 125
 
126 126
  * [ZGRViewer](http://zvtm.sourceforge.net/zgrviewer.html) -- another superb graphviz/dot viewer
127 127
 
128
- * [dot2tex](http://code.google.com/p/dot2tex/) -- python script to convert xdot output from Graphviz to a series of PSTricks or PGF/TikZ commands.
128
+ * [dot2tex](https://github.com/kjellmf/dot2tex) -- python script to convert xdot output from Graphviz to a series of PSTricks or PGF/TikZ commands.
129 129
 
130 130
  * The [pypy project](http://codespeak.net/pypy/) also includes an [interactive dot viewer based on graphviz's plain format and the pygame library](http://morepypy.blogspot.com/2008/01/visualizing-python-tokenizer.html).
Browse code

Update instructions.

Jose Fonseca authored on 16/10/2015 23:43:13
Showing 1 changed files
... ...
@@ -49,9 +49,9 @@ Screenshots
49 49
 Requirements
50 50
 ============
51 51
 
52
- * [Python](http://www.python.org/download/) (2.6 or 2.7)
52
+ * [Python 3](http://www.python.org/download/)
53 53
 
54
- * [PyGTK](http://www.pygtk.org/downloads.html) (2.10 or greater)
54
+ * [PyGObject bindings for GTK3](https://wiki.gnome.org/action/show/Projects/PyGObject)
55 55
 
56 56
  * [Graphviz](http://www.graphviz.org/Download.php)
57 57
 
... ...
@@ -62,9 +62,7 @@ Download and install:
62 62
 
63 63
  * [Python for Windows](http://www.python.org/download/)
64 64
 
65
- * [GTK+ Runtime for Windows](http://www.gtk.org/download/win32.php)
66
-
67
- * [PyCairo, PyGobject, and PyGTK for Windows](http://www.pygtk.org/downloads.html)
65
+ * [PyGObject bindings for GTK3](https://wiki.gnome.org/action/show/Projects/PyGObject)
68 66
 
69 67
  * [Graphviz for Windows](http://www.graphviz.org/Download_windows.php)
70 68
 
... ...
@@ -73,7 +71,7 @@ Debian/Ubuntu users
73 71
 
74 72
 Run:
75 73
 
76
-    apt-get install python-gtk2 graphviz
74
+    apt-get install python3-gi-cairo graphviz
77 75
 
78 76
 Usage
79 77
 =====
Browse code

README: 'sample.py', not 'example.py'

Dov Feldstern authored on 25/06/2014 08:43:33 • José Fonseca committed on 01/07/2014 12:24:46
Showing 1 changed files
... ...
@@ -109,7 +109,7 @@ If no input file is given then it will read the dot graph from the standard inpu
109 109
 Embedding
110 110
 ---------
111 111
 
112
-See included `example.py` script for an example of how to embedded _xdot.py_ into another application.
112
+See included `sample.py` script for an example of how to embedded _xdot.py_ into another application.
113 113
 
114 114
 [![Screenshot](https://raw.github.com/wiki/jrfonseca/xdot.py/xdot-sample_small.png)](https://raw.github.com/wiki/jrfonseca/xdot.py/xdot-sample.png)
115 115
 
Browse code

Link to forks page.

José Fonseca authored on 12/05/2013 13:10:59
Showing 1 changed files
... ...
@@ -12,7 +12,7 @@ Status
12 12
 
13 13
 _xdot.py_ script became much more popular than I ever anticipated, and there are several interested in improving it further. However, for several years now, _xdot.py_ already meets my own needs, and unfortunately I don't have much time for maintain it myself.
14 14
 
15
-So I'm looking into transition _xdot.py_ maitenance to others: either hand over the maintenance _xdot.py_ to a community or indicate an official fork of _xdot.py_.
15
+So I'm looking into transition _xdot.py_ maitenance to [others](https://github.com/jrfonseca/xdot.py/wiki/Forks): either hand over the maintenance _xdot.py_ to a community or indicate an official fork of _xdot.py_.
16 16
 
17 17
 I encourage people interested in development of _xdot.py_ to fork the [GitHub repository](https://github.com/jrfonseca/xdot.py), and join the new [mailing list](https://groups.google.com/d/forum/xdot-py).
18 18
 
Browse code

Drop changelog.

Just duplicates the info on github.

José Fonseca authored on 12/05/2013 12:51:10
Showing 1 changed files
... ...
@@ -26,49 +26,6 @@ Features
26 26
  * Animated jumping between nodes.
27 27
  * Highlights node/edge under mouse.
28 28
 
29
-Changelog
30
-=========
31
-
32
- * **2013-05-12**: Text based node search (by Salva and ludw1g.m3i3r, issue 68)
33
-
34
- * **2012-11-24**: Printing support (by ludw1g.m3i3r, issue 74)
35
-
36
- * **2011-09-01**: Fix forward slash escaping (issue 61)
37
-
38
- * **2011-02-13**: Show dotted lines in xdot (by djs52uk, issue 50)
39
-
40
- * **2010-12-12**: Support images (thanks to Alberto Rodríguez)
41
-
42
- * **2010-01-32**: Add Quit key binding (from sk, issue #30)
43
-
44
- * **2009-09-30**: Add a reload button (fixes issue #22)
45
-
46
- * **2009-09-30**: Properly handle motion-notify-event (from lodatom, issue #24)
47
-
48
- * **2009-09-20**: Automatically reloads open file when it changes (from Robert Meerman, issue #21)
49
-
50
- * **2009-09-20**: Add support for [ColorBrewer Color Schemes](http://colorbrewer.org/) (from to michael.hliao, issue #23).
51
-
52
- * **2009-08-09**: Upload to [PyPi](http://pypi.python.org/pypi/xdot) (thanks to Marius Gedminas, issue #19)
53
-
54
- * **2009-05-24**: Reloads the file on the 'r' key (from peterbjorgensen).
55
-
56
- * **2009-04-09**: Render subgraphs correctly.
57
-
58
- * **2009-03-04**: Support filled bezier shapes.
59
-
60
- * **2009-01-29**: Check for unicode input; check subprocess returncode (from Jaap Karssenberg).
61
-
62
- * **2008-10-27**: Replace pydot and pyparsing by a much faster hand written lexer and parser (issue #9).
63
-
64
- * **2008-09-02**: Make mouse wheel zoom around the mouse cursor rather than center of window (from Marius Gedminas).
65
-
66
- * **2008-09-02**: Handle polylines. Handle ports in node names.
67
-
68
- * **2008-07-27**: Allow to specify the graphviz filter to use.
69
-
70
- * **2008-07-13**: Commit several enhancements done by [Marius Gedminas](http://mg.pov.lt/blog/europython2008-sprints-day-2.html), such as, animated jumping between nodes, highlighted node/edge under mouse, and support to more xdot language features.
71
-
72 29
 Known Issues
73 30
 ============
74 31
 
Browse code

Cleanup readme.

José Fonseca authored on 12/05/2013 12:17:22
Showing 1 changed files
... ...
@@ -1,20 +1,20 @@
1
-About **xdot.py**
1
+About _xdot.py_
2 2
 =================
3 3
 
4
-xdot.py is an interactive viewer for graphs written in [Graphviz](http://www.graphviz.org/)'s [dot language](http://www.graphviz.org/doc/info/lang.html).
4
+_xdot.py_ is an interactive viewer for graphs written in [Graphviz](http://www.graphviz.org/)'s [dot language](http://www.graphviz.org/doc/info/lang.html).
5 5
 
6 6
 It uses internally the graphviz's [xdot output format](http://www.graphviz.org/doc/info/output.html#d:xdot) as an intermediate format, and [PyGTK](http://www.pygtk.org/) and [Cairo](http://cairographics.org/) for rendering.
7 7
 
8
-xdot.py can be used either as a standalone application from command line, or as a library embedded in your python application.
8
+_xdot.py_ can be used either as a standalone application from command line, or as a library embedded in your python application.
9 9
 
10 10
 Status
11 11
 ======
12 12
 
13
-xdot.py script became much more popular than I ever anticipated, and there are several interested in improving it further. However, for several years now, xdot.py already meets my own needs, and unfortunately I don't have much time for maintain it myself.
13
+_xdot.py_ script became much more popular than I ever anticipated, and there are several interested in improving it further. However, for several years now, _xdot.py_ already meets my own needs, and unfortunately I don't have much time for maintain it myself.
14 14
 
15
-So I'm looking into transition xdot.py maitenance to others: either hand over the maintenance xdot.py to a community or indicate an official fork of xdot.py.
15
+So I'm looking into transition _xdot.py_ maitenance to others: either hand over the maintenance _xdot.py_ to a community or indicate an official fork of _xdot.py_.
16 16
 
17
-I encourage people interested in development of xdot.py to fork the (GitHub repository)[https://github.com/jrfonseca/xdot.py], and join the new (mailing list)[https://groups.google.com/d/forum/xdot-py].
17
+I encourage people interested in development of _xdot.py_ to fork the [GitHub repository](https://github.com/jrfonseca/xdot.py), and join the new [mailing list](https://groups.google.com/d/forum/xdot-py).
18 18
 
19 19
 Features
20 20
 ========
... ...
@@ -47,9 +47,9 @@ Changelog
47 47
 
48 48
  * **2009-09-20**: Automatically reloads open file when it changes (from Robert Meerman, issue #21)
49 49
 
50
- * **2009-09-20**: Add support for [ColorBrewer Color Schemes](http://colorbrewer.org/)(from to michael.hliao, issue #23).
50
+ * **2009-09-20**: Add support for [ColorBrewer Color Schemes](http://colorbrewer.org/) (from to michael.hliao, issue #23).
51 51
 
52
- * **2009-08-09**: Upload to [PyPi](http://pypi.python.org/pypi/xdot)(thanks to Marius Gedminas, issue #19)
52
+ * **2009-08-09**: Upload to [PyPi](http://pypi.python.org/pypi/xdot) (thanks to Marius Gedminas, issue #19)
53 53
 
54 54
  * **2009-05-24**: Reloads the file on the 'r' key (from peterbjorgensen).
55 55
 
... ...
@@ -152,7 +152,7 @@ If no input file is given then it will read the dot graph from the standard inpu
152 152
 Embedding
153 153
 ---------
154 154
 
155
-See included `example.py` script for an example of how to embedded xdot.py into another application.
155
+See included `example.py` script for an example of how to embedded _xdot.py_ into another application.
156 156
 
157 157
 [![Screenshot](https://raw.github.com/wiki/jrfonseca/xdot.py/xdot-sample_small.png)](https://raw.github.com/wiki/jrfonseca/xdot.py/xdot-sample.png)
158 158
 
Browse code

Update status.

José Fonseca authored on 12/05/2013 12:14:35
Showing 1 changed files
... ...
@@ -10,9 +10,11 @@ xdot.py can be used either as a standalone application from command line, or as
10 10
 Status
11 11
 ======
12 12
 
13
-xdot.py script became much more popular than I ever anticipated, and it there is potential for further enhancements.  However xdot.py already meets my own needs as it is now, and unfortunately I don't have much time for maintain it myself.
13
+xdot.py script became much more popular than I ever anticipated, and there are several interested in improving it further. However, for several years now, xdot.py already meets my own needs, and unfortunately I don't have much time for maintain it myself.
14 14
 
15
-If this version of xdot.py does not meet your needs then take a look at the [outstanding issues](https://code.google.com/p/jrfonseca/issues/list?q=xdot) or the comments below, for patches and links for other forks.  xdot.py is small and self contained, so feel free to include it in your own projects.
15
+So I'm looking into transition xdot.py maitenance to others: either hand over the maintenance xdot.py to a community or indicate an official fork of xdot.py.
16
+
17
+I encourage people interested in development of xdot.py to fork the (GitHub repository)[https://github.com/jrfonseca/xdot.py], and join the new (mailing list)[https://groups.google.com/d/forum/xdot-py].
16 18
 
17 19
 Features
18 20
 ========
... ...
@@ -74,7 +76,11 @@ Known Issues
74 76
 
75 77
  * Text doesn't scale properly to large sizes if font hinting is enabled. I haven't find a reliable way to disable font hinting during rendering yet.
76 78
 
77
-See also the [googlecode issue tracker](https://code.google.com/p/jrfonseca/issues/list?q=xdot).
79
+See also:
80
+
81
+  * [github issue tracker](https://github.com/jrfonseca/xdot.py/issues)
82
+
83
+  * [googlecode issue tracker](https://code.google.com/p/jrfonseca/issues/list?q=xdot).
78 84
 
79 85
 Screenshots
80 86
 ===========
... ...
@@ -86,7 +92,7 @@ Screenshots
86 92
 Requirements
87 93
 ============
88 94
 
89
- * [Python](http://www.python.org/download/) (2.4 or greater)
95
+ * [Python](http://www.python.org/download/) (2.6 or 2.7)
90 96
 
91 97
  * [PyGTK](http://www.pygtk.org/downloads.html) (2.10 or greater)
92 98
 
Browse code

Update images links.

José Fonseca authored on 12/05/2013 11:38:21
Showing 1 changed files
... ...
@@ -79,9 +79,9 @@ See also the [googlecode issue tracker](https://code.google.com/p/jrfonseca/issu
79 79
 Screenshots
80 80
 ===========
81 81
 
82
-[![Screenshot 1](http://wiki.jrfonseca.googlecode.com/git/xdot-profile1_small.png)](http://wiki.jrfonseca.googlecode.com/git/xdot-profile1.png)
83
-[![Screenshot 2](http://wiki.jrfonseca.googlecode.com/git/xdot-profile2_small.png)](http://wiki.jrfonseca.googlecode.com/git/xdot-profile2.png)
84
-[![Screenshot 3](http://wiki.jrfonseca.googlecode.com/git/xdot-cfg_small.png)](http://wiki.jrfonseca.googlecode.com/git/xdot-cfg.png)
82
+[![Profile 1 Screenshot](https://raw.github.com/wiki/jrfonseca/xdot.py/xdot-profile1_small.png)](https://raw.github.com/wiki/jrfonseca/xdot.py/xdot-profile1.png)
83
+[![Profile 2 Screenshot](https://raw.github.com/wiki/jrfonseca/xdot.py/xdot-profile2_small.png)](https://raw.github.com/wiki/jrfonseca/xdot.py/xdot-profile2.png)
84
+[![Control Flow Graph](https://raw.github.com/wiki/jrfonseca/xdot.py/xdot-cfg_small.png)](https://raw.github.com/wiki/jrfonseca/xdot.py/xdot-cfg.png)
85 85
 
86 86
 Requirements
87 87
 ============
... ...
@@ -148,7 +148,7 @@ Embedding
148 148
 
149 149
 See included `example.py` script for an example of how to embedded xdot.py into another application.
150 150
 
151
-[![Screenshot](http://wiki.jrfonseca.googlecode.com/git/xdot-sample_small.png)](http://wiki.jrfonseca.googlecode.com/git/xdot-sample.png)
151
+[![Screenshot](https://raw.github.com/wiki/jrfonseca/xdot.py/xdot-sample_small.png)](https://raw.github.com/wiki/jrfonseca/xdot.py/xdot-sample.png)
152 152
 
153 153
 Download
154 154
 ========
Browse code

Refer to example.py instead of duplicating the code.

José Fonseca authored on 12/05/2013 10:48:02
Showing 1 changed files
... ...
@@ -146,44 +146,7 @@ If no input file is given then it will read the dot graph from the standard inpu
146 146
 Embedding
147 147
 ---------
148 148
 
149
-    #!/usr/bin/env python
150
-    
151
-    import gtk
152
-    import gtk.gdk
153
-    
154
-    import xdot
155
-    
156
-    class MyDotWindow(xdot.DotWindow):
157
-    
158
-        def __init__(self):
159
-            xdot.DotWindow.__init__(self)
160
-            self.widget.connect('clicked', self.on_url_clicked)
161
-    
162
-        def on_url_clicked(self, widget, url, event):
163
-            dialog = gtk.MessageDialog(
164
-                    parent = self, 
165
-                    buttons = gtk.BUTTONS_OK,
166
-                    message_format="%s clicked" % url)
167
-            dialog.connect('response', lambda dialog, response: dialog.destroy())
168
-            dialog.run()
169
-            return True
170
-    
171
-    dotcode = """
172
-    digraph G {
173
-      Hello [URL="http://en.wikipedia.org/wiki/Hello"]
174
-      World [URL="http://en.wikipedia.org/wiki/World"]
175
-        Hello -> World
176
-    }
177
-    """
178
-    
179
-    def main():
180
-        window = MyDotWindow()
181
-        window.set_dotcode(dotcode)
182
-        window.connect('destroy', gtk.main_quit)
183
-        gtk.main()
184
-    
185
-    if __name__ == '__main__':
186
-        main()
149
+See included `example.py` script for an example of how to embedded xdot.py into another application.
187 150
 
188 151
 [![Screenshot](http://wiki.jrfonseca.googlecode.com/git/xdot-sample_small.png)](http://wiki.jrfonseca.googlecode.com/git/xdot-sample.png)
189 152
 
Browse code

Add README.

Based of wiki.

José Fonseca authored on 12/05/2013 10:40:36
Showing 1 changed files
1 1
new file mode 100644
... ...
@@ -0,0 +1,206 @@
1
+About **xdot.py**
2
+=================
3
+
4
+xdot.py is an interactive viewer for graphs written in [Graphviz](http://www.graphviz.org/)'s [dot language](http://www.graphviz.org/doc/info/lang.html).
5
+
6
+It uses internally the graphviz's [xdot output format](http://www.graphviz.org/doc/info/output.html#d:xdot) as an intermediate format, and [PyGTK](http://www.pygtk.org/) and [Cairo](http://cairographics.org/) for rendering.
7
+
8
+xdot.py can be used either as a standalone application from command line, or as a library embedded in your python application.
9
+
10
+Status
11
+======
12
+
13
+xdot.py script became much more popular than I ever anticipated, and it there is potential for further enhancements.  However xdot.py already meets my own needs as it is now, and unfortunately I don't have much time for maintain it myself.
14
+
15
+If this version of xdot.py does not meet your needs then take a look at the [outstanding issues](https://code.google.com/p/jrfonseca/issues/list?q=xdot) or the comments below, for patches and links for other forks.  xdot.py is small and self contained, so feel free to include it in your own projects.
16
+
17
+Features
18
+========
19
+
20
+ * Since it doesn't use bitmaps it is fast and has a small memory footprint.
21
+ * Arbitrary zoom.
22
+ * Keyboard/mouse navigation.
23
+ * Supports events on the nodes with URLs.
24
+ * Animated jumping between nodes.
25
+ * Highlights node/edge under mouse.
26
+
27
+Changelog
28
+=========
29
+
30
+ * **2013-05-12**: Text based node search (by Salva and ludw1g.m3i3r, issue 68)
31
+
32
+ * **2012-11-24**: Printing support (by ludw1g.m3i3r, issue 74)
33
+
34
+ * **2011-09-01**: Fix forward slash escaping (issue 61)
35
+
36
+ * **2011-02-13**: Show dotted lines in xdot (by djs52uk, issue 50)
37
+
38
+ * **2010-12-12**: Support images (thanks to Alberto Rodríguez)
39
+
40
+ * **2010-01-32**: Add Quit key binding (from sk, issue #30)
41
+
42
+ * **2009-09-30**: Add a reload button (fixes issue #22)
43
+
44
+ * **2009-09-30**: Properly handle motion-notify-event (from lodatom, issue #24)
45
+
46
+ * **2009-09-20**: Automatically reloads open file when it changes (from Robert Meerman, issue #21)
47
+
48
+ * **2009-09-20**: Add support for [ColorBrewer Color Schemes](http://colorbrewer.org/)(from to michael.hliao, issue #23).
49
+
50
+ * **2009-08-09**: Upload to [PyPi](http://pypi.python.org/pypi/xdot)(thanks to Marius Gedminas, issue #19)
51
+
52
+ * **2009-05-24**: Reloads the file on the 'r' key (from peterbjorgensen).
53
+
54
+ * **2009-04-09**: Render subgraphs correctly.
55
+
56
+ * **2009-03-04**: Support filled bezier shapes.
57
+
58
+ * **2009-01-29**: Check for unicode input; check subprocess returncode (from Jaap Karssenberg).
59
+
60
+ * **2008-10-27**: Replace pydot and pyparsing by a much faster hand written lexer and parser (issue #9).
61
+
62
+ * **2008-09-02**: Make mouse wheel zoom around the mouse cursor rather than center of window (from Marius Gedminas).
63
+
64
+ * **2008-09-02**: Handle polylines. Handle ports in node names.
65
+
66
+ * **2008-07-27**: Allow to specify the graphviz filter to use.
67
+
68
+ * **2008-07-13**: Commit several enhancements done by [Marius Gedminas](http://mg.pov.lt/blog/europython2008-sprints-day-2.html), such as, animated jumping between nodes, highlighted node/edge under mouse, and support to more xdot language features.
69
+
70
+Known Issues
71
+============
72
+
73
+ * Not all xdot attributes are supported or correctly rendered yet. It works well for my applications but YMMV.
74
+
75
+ * Text doesn't scale properly to large sizes if font hinting is enabled. I haven't find a reliable way to disable font hinting during rendering yet.
76
+
77
+See also the [googlecode issue tracker](https://code.google.com/p/jrfonseca/issues/list?q=xdot).
78
+
79
+Screenshots
80
+===========
81
+
82
+[![Screenshot 1](http://wiki.jrfonseca.googlecode.com/git/xdot-profile1_small.png)](http://wiki.jrfonseca.googlecode.com/git/xdot-profile1.png)
83
+[![Screenshot 2](http://wiki.jrfonseca.googlecode.com/git/xdot-profile2_small.png)](http://wiki.jrfonseca.googlecode.com/git/xdot-profile2.png)
84
+[![Screenshot 3](http://wiki.jrfonseca.googlecode.com/git/xdot-cfg_small.png)](http://wiki.jrfonseca.googlecode.com/git/xdot-cfg.png)
85
+
86
+Requirements
87
+============
88
+
89
+ * [Python](http://www.python.org/download/) (2.4 or greater)
90
+
91
+ * [PyGTK](http://www.pygtk.org/downloads.html) (2.10 or greater)
92
+
93
+ * [Graphviz](http://www.graphviz.org/Download.php)
94
+
95
+Windows users
96
+-------------
97
+
98
+Download and install:
99
+
100
+ * [Python for Windows](http://www.python.org/download/)
101
+
102
+ * [GTK+ Runtime for Windows](http://www.gtk.org/download/win32.php)
103
+
104
+ * [PyCairo, PyGobject, and PyGTK for Windows](http://www.pygtk.org/downloads.html)
105
+
106
+ * [Graphviz for Windows](http://www.graphviz.org/Download_windows.php)
107
+
108
+Debian/Ubuntu users
109
+-------------------
110
+
111
+Run:
112
+
113
+    apt-get install python-gtk2 graphviz
114
+
115
+Usage
116
+=====
117
+
118
+Command Line
119
+------------
120
+
121
+    Usage: 
122
+    	xdot.py [file]
123
+    
124
+    Options:
125
+      -h, --help            show this help message and exit
126
+      -f FILTER, --filter=FILTER
127
+                            graphviz filter: dot, neato, twopi, circo, or fdp
128
+                            [default: dot]
129
+      -n, --no-filter       assume input is already filtered into xdot format (use
130
+                            e.g. dot -Txdot)
131
+    
132
+    Shortcuts:
133
+      Up, Down, Left, Right     scroll
134
+      PageUp, +, =              zoom in
135
+      PageDown, -               zoom out
136
+      R                         reload dot file
137
+      F                         find
138
+      Q                         quit
139
+      P                         print
140
+      Escape                    halt animation
141
+      Ctrl-drag                 zoom in/out
142
+      Shift-drag                zooms an area
143
+
144
+If no input file is given then it will read the dot graph from the standard input.
145
+
146
+Embedding
147
+---------
148
+
149
+    #!/usr/bin/env python
150
+    
151
+    import gtk
152
+    import gtk.gdk
153
+    
154
+    import xdot
155
+    
156
+    class MyDotWindow(xdot.DotWindow):
157
+    
158
+        def __init__(self):
159
+            xdot.DotWindow.__init__(self)
160
+            self.widget.connect('clicked', self.on_url_clicked)
161
+    
162
+        def on_url_clicked(self, widget, url, event):
163
+            dialog = gtk.MessageDialog(
164
+                    parent = self, 
165
+                    buttons = gtk.BUTTONS_OK,
166
+                    message_format="%s clicked" % url)
167
+            dialog.connect('response', lambda dialog, response: dialog.destroy())
168
+            dialog.run()
169
+            return True
170
+    
171
+    dotcode = """
172
+    digraph G {
173
+      Hello [URL="http://en.wikipedia.org/wiki/Hello"]
174
+      World [URL="http://en.wikipedia.org/wiki/World"]
175
+        Hello -> World
176
+    }
177
+    """
178
+    
179
+    def main():
180
+        window = MyDotWindow()
181
+        window.set_dotcode(dotcode)
182
+        window.connect('destroy', gtk.main_quit)
183
+        gtk.main()
184
+    
185
+    if __name__ == '__main__':
186
+        main()
187
+
188
+[![Screenshot](http://wiki.jrfonseca.googlecode.com/git/xdot-sample_small.png)](http://wiki.jrfonseca.googlecode.com/git/xdot-sample.png)
189
+
190
+Download
191
+========
192
+
193
+  * https://pypi.python.org/pypi/xdot
194
+
195
+  * https://github.com/jrfonseca/xdot.py
196
+
197
+Links
198
+=====
199
+
200
+ * [Graphviz homepage](http://www.graphviz.org/)
201
+
202
+ * [ZGRViewer](http://zvtm.sourceforge.net/zgrviewer.html) -- another superb graphviz/dot viewer
203
+
204
+ * [dot2tex](http://code.google.com/p/dot2tex/) -- python script to convert xdot output from Graphviz to a series of PSTricks or PGF/TikZ commands.
205
+
206
+ * The [pypy project](http://codespeak.net/pypy/) also includes an [interactive dot viewer based on graphviz's plain format and the pygame library](http://morepypy.blogspot.com/2008/01/visualizing-python-tokenizer.html).