docutil/docsvg.py
changeset 1872 866fb3ab8778
parent 1832 0f1081928d65
child 1876 995df4804221
equal deleted inserted replaced
1871:933fbe9a5e2c 1872:866fb3ab8778
    31     """ Return the Inkscape path """
    31     """ Return the Inkscape path """
    32     import _winreg
    32     import _winreg
    33     try:
    33     try:
    34         svgexepath = _winreg.QueryValue(_winreg.HKEY_LOCAL_MACHINE,
    34         svgexepath = _winreg.QueryValue(_winreg.HKEY_LOCAL_MACHINE,
    35                                         'Software\\Classes\\svgfile\\shell\\Inkscape\\command')
    35                                         'Software\\Classes\\svgfile\\shell\\Inkscape\\command')
    36     except WindowsError:
    36     except OSError:
    37         svgexepath = _winreg.QueryValue(_winreg.HKEY_LOCAL_MACHINE,
    37         svgexepath = _winreg.QueryValue(_winreg.HKEY_LOCAL_MACHINE,
    38                                         'Software\\Classes\\inkscape.svg\\shell\\open\\command')
    38                                         'Software\\Classes\\inkscape.svg\\shell\\open\\command')
    39     svgexepath = svgexepath.replace('"%1"', '')
    39     svgexepath = svgexepath.replace('"%1"', '')
    40     return svgexepath.replace('"', '')
    40     return svgexepath.replace('"', '')
    41 
    41