[GRASS-dev] Re: [GRASS GIS] #1441: Hard Copy Map Utility (wxPython
wrapper for ps.map) text overlay is broken
GRASS GIS
trac at osgeo.org
Wed Sep 7 03:48:04 EDT 2011
#1441: Hard Copy Map Utility (wxPython wrapper for ps.map) text overlay is broken
-------------------------------------------+--------------------------------
Reporter: cmbarton | Owner: grass-dev@…
Type: defect | Status: new
Priority: normal | Milestone: 6.4.2
Component: wxGUI | Version: svn-trunk
Keywords: hard copy map utility, ps.map | Platform: Unspecified
Cpu: Unspecified |
-------------------------------------------+--------------------------------
Comment(by cmbarton):
I see now why a custom font dialog is being used--to match the font
commands of ps.map. I've managed to fix the original problem in this
report, but now there is a further related problem.
ps.map seems to use special font names like "Times-Roman" that are
perfectly understandable but which do not match the relevant font name in
wxPython. These are listed in the ps.map manual and hard coded into
psmap.py. For example, the font "Times-Roman" is one of the fonts listed
in the ps.map manual but this is not the way this font face is referred to
in wxPython. On the Mac, this font is called "Times New Roman" (with the
word "New" and lacking hyphens).
If we are supposed to use real font names (i.e., those appropriate for a
given platform) and those in the manual are just generic suggestions, they
we can use wx.FontDialog with some translation of font attributes like
color and pointsize. But if the font names listed in the ps.map manual are
the only forms that are recognized, we need to somehow map between these
hard coded font names in the ps.map module and their equivalents in
wxPython across all 3 major platforms.
Michael
--
Ticket URL: <http://trac.osgeo.org/grass/ticket/1441#comment:2>
GRASS GIS <http://grass.osgeo.org>
More information about the grass-dev
mailing list