* src/RelImage.py: replace system call with Utils.search_for
* src/Utils.py: added search_for to look for an executable in the current path * FAQ: removed question 18 (how fast is GRAMPS) * src/PeopleStore.py: set sort data for top level nodes. Allows the first and last nodes to be sorted properly. svn: r2374
This commit is contained in:
@ -586,6 +586,13 @@ def gformat(val):
|
||||
decimal_point = locale.localeconv()['decimal_point']
|
||||
return_val = "%.3f" % val
|
||||
return return_val.replace(decimal_point,'.')
|
||||
|
||||
def search_for(name):
|
||||
for i in os.environ['PATH'].split(':'):
|
||||
fname = os.path.join(i,name)
|
||||
if os.access(fname,os.X_OK):
|
||||
return 1
|
||||
return 0
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
|
Reference in New Issue
Block a user