Skip to content

Commit

Permalink
wx.metadata/mdlib: fix pdf doc logo path
Browse files Browse the repository at this point in the history
  • Loading branch information
tmszi committed Jul 2, 2020
1 parent 0a6f789 commit 4f93b3e
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions grass7/gui/wxpython/wx.metadata/mdlib/mdpdffactory.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,9 @@
except:
sys.exit('owslib library is missing. Check requirements on the manual page < https://grasswiki.osgeo.org/wiki/ISO/INSPIRE_Metadata_Support >')
import tempfile, sys, os
from grass.pygrass.utils import set_path,get_lib_path
from grass.pygrass.utils import set_path
from grass.script import core as grass
from grass.script.utils import get_lib_path
from core.gcmd import GError, GMessage, GWarning

set_path(modulename='wx.metadata', dirname='mdlib')
Expand Down Expand Up @@ -136,8 +137,10 @@ def createPDF(self, save=True):

self.doc.set_theme(MyTheme)

logo_path = get_lib_path("wx.metadata",'config')
logo_path = os.path.join(logo_path,'logo_variant_bg.png')
lib_name = 'config'
logo_path = get_lib_path("wx.metadata", lib_name)

logo_path = os.path.join(logo_path, lib_name, 'logo_variant_bg.png')
self.doc.add_image(logo_path, 57, 73, LEFT)

if self.map is None:
Expand Down Expand Up @@ -641,4 +644,3 @@ def CalcBoundsFromPoints(self, lats, lngs):
north = max(flats)
south = min(flats)
return [[south, west], [north, east]]

0 comments on commit 4f93b3e

Please sign in to comment.