Change from using ".dot" to ".gv" for Graphviz files. ".dot" is recognized as MS Word Template file on some systems.
svn: r11782
This commit is contained in:
parent
3259b393da
commit
bd966adafd
@ -354,15 +354,15 @@ class GVDocBase(BaseDoc.BaseDoc, BaseDoc.GVDoc):
|
|||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------------
|
#-------------------------------------------------------------------------------
|
||||||
class GVDotDoc(GVDocBase):
|
class GVDotDoc(GVDocBase):
|
||||||
""" GVDoc implementation that generates a .dot text file. """
|
""" GVDoc implementation that generates a .gv text file. """
|
||||||
|
|
||||||
def close(self):
|
def close(self):
|
||||||
""" Implements GVDocBase.close() """
|
""" Implements GVDocBase.close() """
|
||||||
GVDocBase.close(self)
|
GVDocBase.close(self)
|
||||||
|
|
||||||
# Make sure the extension is correct
|
# Make sure the extension is correct
|
||||||
if self._filename[-4:] != ".dot":
|
if self._filename[-4:] != ".gv":
|
||||||
self._filename += ".dot"
|
self._filename += ".gv"
|
||||||
|
|
||||||
_run_long_process_in_thread(self.__generate, self._filename)
|
_run_long_process_in_thread(self.__generate, self._filename)
|
||||||
|
|
||||||
@ -410,7 +410,7 @@ class GVPsDoc(GVDocBase):
|
|||||||
application does not appear to hang.
|
application does not appear to hang.
|
||||||
"""
|
"""
|
||||||
# Create a temporary dot file
|
# Create a temporary dot file
|
||||||
(handle, tmp_dot) = tempfile.mkstemp(".dot" )
|
(handle, tmp_dot) = tempfile.mkstemp(".gv" )
|
||||||
dotfile = os.fdopen(handle,"w")
|
dotfile = os.fdopen(handle,"w")
|
||||||
dotfile.write(self._dot.getvalue())
|
dotfile.write(self._dot.getvalue())
|
||||||
dotfile.close()
|
dotfile.close()
|
||||||
@ -456,7 +456,7 @@ class GVSvgDoc(GVDocBase):
|
|||||||
application does not appear to hang.
|
application does not appear to hang.
|
||||||
"""
|
"""
|
||||||
# Create a temporary dot file
|
# Create a temporary dot file
|
||||||
(handle, tmp_dot) = tempfile.mkstemp(".dot" )
|
(handle, tmp_dot) = tempfile.mkstemp(".gv" )
|
||||||
dotfile = os.fdopen(handle,"w")
|
dotfile = os.fdopen(handle,"w")
|
||||||
dotfile.write(self._dot.getvalue())
|
dotfile.write(self._dot.getvalue())
|
||||||
dotfile.close()
|
dotfile.close()
|
||||||
@ -502,7 +502,7 @@ class GVSvgzDoc(GVDocBase):
|
|||||||
application does not appear to hang.
|
application does not appear to hang.
|
||||||
"""
|
"""
|
||||||
# Create a temporary dot file
|
# Create a temporary dot file
|
||||||
(handle, tmp_dot) = tempfile.mkstemp(".dot" )
|
(handle, tmp_dot) = tempfile.mkstemp(".gv" )
|
||||||
dotfile = os.fdopen(handle,"w")
|
dotfile = os.fdopen(handle,"w")
|
||||||
dotfile.write(self._dot.getvalue())
|
dotfile.write(self._dot.getvalue())
|
||||||
dotfile.close()
|
dotfile.close()
|
||||||
@ -548,7 +548,7 @@ class GVPngDoc(GVDocBase):
|
|||||||
application does not appear to hang.
|
application does not appear to hang.
|
||||||
"""
|
"""
|
||||||
# Create a temporary dot file
|
# Create a temporary dot file
|
||||||
(handle, tmp_dot) = tempfile.mkstemp(".dot" )
|
(handle, tmp_dot) = tempfile.mkstemp(".gv" )
|
||||||
dotfile = os.fdopen(handle,"w")
|
dotfile = os.fdopen(handle,"w")
|
||||||
dotfile.write(self._dot.getvalue())
|
dotfile.write(self._dot.getvalue())
|
||||||
dotfile.close()
|
dotfile.close()
|
||||||
@ -594,7 +594,7 @@ class GVJpegDoc(GVDocBase):
|
|||||||
application does not appear to hang.
|
application does not appear to hang.
|
||||||
"""
|
"""
|
||||||
# Create a temporary dot file
|
# Create a temporary dot file
|
||||||
(handle, tmp_dot) = tempfile.mkstemp(".dot" )
|
(handle, tmp_dot) = tempfile.mkstemp(".gv" )
|
||||||
dotfile = os.fdopen(handle,"w")
|
dotfile = os.fdopen(handle,"w")
|
||||||
dotfile.write(self._dot.getvalue())
|
dotfile.write(self._dot.getvalue())
|
||||||
dotfile.close()
|
dotfile.close()
|
||||||
@ -640,7 +640,7 @@ class GVGifDoc(GVDocBase):
|
|||||||
application does not appear to hang.
|
application does not appear to hang.
|
||||||
"""
|
"""
|
||||||
# Create a temporary dot file
|
# Create a temporary dot file
|
||||||
(handle, tmp_dot) = tempfile.mkstemp(".dot" )
|
(handle, tmp_dot) = tempfile.mkstemp(".gv" )
|
||||||
dotfile = os.fdopen(handle,"w")
|
dotfile = os.fdopen(handle,"w")
|
||||||
dotfile.write(self._dot.getvalue())
|
dotfile.write(self._dot.getvalue())
|
||||||
dotfile.close()
|
dotfile.close()
|
||||||
@ -689,7 +689,7 @@ class GVPdfGvDoc(GVDocBase):
|
|||||||
application does not appear to hang.
|
application does not appear to hang.
|
||||||
"""
|
"""
|
||||||
# Create a temporary dot file
|
# Create a temporary dot file
|
||||||
(handle, tmp_dot) = tempfile.mkstemp(".dot" )
|
(handle, tmp_dot) = tempfile.mkstemp(".gv" )
|
||||||
dotfile = os.fdopen(handle,"w")
|
dotfile = os.fdopen(handle,"w")
|
||||||
dotfile.write(self._dot.getvalue())
|
dotfile.write(self._dot.getvalue())
|
||||||
dotfile.close()
|
dotfile.close()
|
||||||
@ -733,7 +733,7 @@ class GVPdfGsDoc(GVDocBase):
|
|||||||
application does not appear to hang.
|
application does not appear to hang.
|
||||||
"""
|
"""
|
||||||
# Create a temporary dot file
|
# Create a temporary dot file
|
||||||
(handle, tmp_dot) = tempfile.mkstemp(".dot" )
|
(handle, tmp_dot) = tempfile.mkstemp(".gv" )
|
||||||
dotfile = os.fdopen(handle,"w")
|
dotfile = os.fdopen(handle,"w")
|
||||||
dotfile.write(self._dot.getvalue())
|
dotfile.write(self._dot.getvalue())
|
||||||
dotfile.close()
|
dotfile.close()
|
||||||
@ -823,7 +823,7 @@ if _DOT_FOUND:
|
|||||||
|
|
||||||
_FORMATS += [{ 'type' : "dot",
|
_FORMATS += [{ 'type' : "dot",
|
||||||
'ext' : "dot",
|
'ext' : "dot",
|
||||||
'descr': _("Graphviz Dot File"),
|
'descr': _("Graphviz File"),
|
||||||
'mime' : "text/x-graphviz",
|
'mime' : "text/x-graphviz",
|
||||||
'class': GVDotDoc }]
|
'class': GVDotDoc }]
|
||||||
|
|
||||||
|
@ -757,7 +757,8 @@ class FamilyLinesReport(Report):
|
|||||||
|
|
||||||
self.doc.add_comment('')
|
self.doc.add_comment('')
|
||||||
|
|
||||||
# if we're going to attempt to include images, then use the HTML style of .dot file
|
# If we're going to attempt to include images, then use the HTML style
|
||||||
|
# of .gv file.
|
||||||
bUseHtmlOutput = False
|
bUseHtmlOutput = False
|
||||||
if self._incimages:
|
if self._incimages:
|
||||||
bUseHtmlOutput = True
|
bUseHtmlOutput = True
|
||||||
|
Loading…
Reference in New Issue
Block a user