Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[processing] some fixes in help system
  • Loading branch information
volaya committed Apr 24, 2014
1 parent d2b1c82 commit 79757fa
Show file tree
Hide file tree
Showing 7 changed files with 10 additions and 8 deletions.
4 changes: 2 additions & 2 deletions python/plugins/processing/algs/grass7/Grass7Algorithm.py
Expand Up @@ -91,8 +91,8 @@ def getCopy(self):
def getIcon(self):
return QIcon(os.path.dirname(__file__) + '/../../images/grass.png')

def helpFile(self):
return 'http://grass.osgeo.org/grass70/manuals/' + self.grassName \
def help(self):
return False, 'http://grass.osgeo.org/grass70/manuals/' + self.grassName \
+ '.html'

def getParameterDescriptions(self):
Expand Down
2 changes: 1 addition & 1 deletion python/plugins/processing/algs/r/RAlgorithm.py
Expand Up @@ -406,7 +406,7 @@ def help(self):
if os.path.exists(helpfile):
return True, getHtmlFromHelpFile(self, helpfile)
else:
return None
return False, None

def checkBeforeOpeningParametersDialog(self):
msg = RUtils.checkRIsInstalled()
Expand Down
2 changes: 1 addition & 1 deletion python/plugins/processing/algs/saga/SplitRGBBands.py
Expand Up @@ -42,7 +42,7 @@ class SplitRGBBands(GeoAlgorithm):
B = 'B'

def getIcon(self):
return QtGui.QIcon(os.path.dirname(__file__) + '/../images/saga.png')
return QtGui.QIcon(os.path.dirname(__file__) + '/../../images/saga.png')

def defineCharacteristics(self):
self.name = 'Split RGB bands'
Expand Down
Expand Up @@ -60,7 +60,7 @@ def getName(self):
return 'taudem'

def getIcon(self):
return QIcon(os.path.dirname(__file__) + '/../images/taudem.png')
return QIcon(os.path.dirname(__file__) + '/../../images/taudem.png')

def initializeSettings(self):
AlgorithmProvider.initializeSettings(self)
Expand Down
2 changes: 2 additions & 0 deletions python/plugins/processing/gui/Help2Html.py
Expand Up @@ -44,6 +44,8 @@


def getHtmlFromRstFile(rst):
if not os.path.exists(rst):
return ''
with open(rst) as f:
lines = f.readlines()
s = "".join(lines)
Expand Down
2 changes: 1 addition & 1 deletion python/plugins/processing/modeler/ModelerAlgorithm.py
Expand Up @@ -741,7 +741,7 @@ def help(self):
if os.path.exists(helpfile):
return True, getHtmlFromHelpFile(self, helpfile)
else:
return None
return False, None


class AlgorithmAndParameter:
Expand Down
4 changes: 2 additions & 2 deletions python/plugins/processing/script/ScriptAlgorithm.py
Expand Up @@ -257,9 +257,9 @@ def processAlgorithm(self, progress):

def help(self):
if self.descriptionFile is None:
return None
return False, None
helpfile = self.descriptionFile + '.help'
if os.path.exists(helpfile):
return True, getHtmlFromHelpFile(self, helpfile)
else:
return None
return False, None

0 comments on commit 79757fa

Please sign in to comment.