Opened 9 years ago
Closed 9 years ago
#2870 closed defect (fixed)
d.fontlist crashes on Windows
Reported by: | annakrat | Owned by: | martinl |
---|---|---|---|
Priority: | blocker | Milestone: | 7.0.3 |
Component: | Display | Version: | svn-releasebranch70 |
Keywords: | d.fontlist, font, wingrass | Cc: | grass-dev@… |
CPU: | Unspecified | Platform: | MSWindows 8 |
Description
When changing default font for display commands in GUI settings, the underlying command d.fontlist crashes. This is what I get when running d.fontlist from terminal (with d.mon wx0):
D1/5: G_set_program_name(): d.fontlist D2/5: G_file_name(): path = C:\Users\akratoc\grassdata/nc_spm_08_grass7/user1 D1/5: D_open_driver(): D1/5: cairo: GRASS_RENDER_TRANSPARENT=FALSE D1/5: cairo: GRASS_RENDER_ANTIALIAS=FALSE D1/5: cairo: GRASS_RENDER_FILE=map.png D1/5: cairo: file type=3 D1/5: cairo: GRASS_RENDER_FILE_MAPPED=0 D1/5: cairo: GRASS_RENDER_FILE_READ=0 D1/5: init_cairo D1/5: Cairo_Erase D1/5: Cairo_Set_window: 0.000000 480.000000 0.000000 640.000000 Fontconfig error: Cannot load default config file Fontconfig error: Cannot load default config file
Happens with cairo and png driver. tested on several computers with Windows 8 and 10. This works in 7.0.2.
Change History (19)
comment:1 by , 9 years ago
Keywords: | wingrass added |
---|
follow-up: 4 comment:2 by , 9 years ago
comment:4 by , 9 years ago
Replying to martinl:
Confirmed on my Windows 7 machine.
here also in OSGeo4W-g7
System Info GRASS version: 7.0.3RC1 GRASS SVN Revision: 67443 Build Date: 2015-12-31 Build Platform: x86_64-w64-mingw32 GDAL/OGR: 1.11.3 PROJ.4: 4.9.2 GEOS: 3.5.0 SQLite: 3.7.17 Python: 2.7.5 wxPython: 2.8.12.1 Platform: Windows-7-6.1.7601-SP1 (OSGeo4W)
comment:6 by , 9 years ago
Replying to annakrat:
Could it be related to any changes done for #2448?
I can't see this connex, as it also fails in OSGeo4W-g7 (see above); changes done for #2448 doesn't do anything in OSGeo4W-g7.
Fontconfig error: Cannot load default config file
any idea in the code where this default config file is searched
follow-up: 8 comment:7 by , 9 years ago
Replying to annakrat:
Could it be related to any changes done for #2448?
trying here:
g.mkfontcap -s cyrilc|Cyrillic|0|C:\OSGEO4~1\apps\grass\grass-7.0.3RC1\fonts\cyrilc.hmp|0|utf-8| gothgbt|Gothic Great Britain triplex|0|C:\OSGEO4~1\apps\grass\grass-7.0.3RC1\fonts\gothgbt.hmp|0|utf-8| gothgrt|Gothic German triplex|0|C:\OSGEO4~1\apps\grass\grass-7.0.3RC1\fonts\gothgrt.hmp|0|utf-8| gothitt|Gothic Italian triplex|0|C:\OSGEO4~1\apps\grass\grass-7.0.3RC1\fonts\gothitt.hmp|0|utf-8| [...]
so correctly updated fontcap file is found here by g.mkfontcap.
the question is if the fontcap file is the same as the default config file?
comment:8 by , 9 years ago
Replying to hellik:
Replying to annakrat:
Could it be related to any changes done for #2448?
trying here:
g.mkfontcap -s cyrilc|Cyrillic|0|C:\OSGEO4~1\apps\grass\grass-7.0.3RC1\fonts\cyrilc.hmp|0|utf-8| gothgbt|Gothic Great Britain triplex|0|C:\OSGEO4~1\apps\grass\grass-7.0.3RC1\fonts\gothgbt.hmp|0|utf-8| gothgrt|Gothic German triplex|0|C:\OSGEO4~1\apps\grass\grass-7.0.3RC1\fonts\gothgrt.hmp|0|utf-8| gothitt|Gothic Italian triplex|0|C:\OSGEO4~1\apps\grass\grass-7.0.3RC1\fonts\gothitt.hmp|0|utf-8| [...]so correctly updated fontcap file is found here by g.mkfontcap.
the question is if the fontcap file is the same as the default config file?
tested with font types listes by g.mkfontcap -s, all vector labels are displayed correctly; e.g.:
d.vect map=firestations@PERMANENT width=1 attribute_column=CITY font=georgiab d.vect map=firestations@PERMANENT width=1 attribute_column=CITY font=FRADMCN
comment:9 by , 9 years ago
The programs crashes at source:grass/trunk/lib/driver/font.c#L151
Any idea?
comment:11 by , 9 years ago
Cc: | added |
---|---|
Owner: | changed from | to
Priority: | major → blocker |
Status: | new → assigned |
follow-up: 13 comment:12 by , 9 years ago
Replying to martinl:
Hopefully fixed in r67630. Will check next build.
tested here locally by copying
C:\OSGeo4W\etc\fonts\fonts.conf
to
C:\OSGeo4W64\apps\grass\grass-7.0.3RC1\etc
and by adding
set FONTCONFIG_FILE=%GISBASE%\etc\fonts.conf
in the winGRASS windows console.
C:\>d.fontlist -l Unable to update the static FcBlanks: 0x0600 Unable to update the static FcBlanks: 0x0601 Unable to update the static FcBlanks: 0x0602 Unable to update the static FcBlanks: 0x0603 Unable to update the static FcBlanks: 0x06dd Unable to update the static FcBlanks: 0x070f Unable to update the static FcBlanks: 0x2028 Unable to update the static FcBlanks: 0x2029 Unable to update the static FcBlanks: 0xfff9 Unable to update the static FcBlanks: 0xfffa Unable to update the static FcBlanks: 0xfffb cyrilc gothgbt gothgrt gothitt greekc greekcs greekp greeks italicc italiccs italict romanc romancs romand romans romant scriptc scripts AGENCYB [...]
basically it seems to work, though some error messages.
so let's test next build.
follow-up: 14 comment:13 by , 9 years ago
Replying to hellik:
basically it seems to work, though some error messages.
so let's test next build.
Please try the last build (no.53 64bit or no.216 32bit)
follow-up: 15 comment:14 by , 9 years ago
Replying to martinl:
Replying to hellik:
basically it seems to work, though some error messages.
so let's test next build.
Please try the last build (no.53 64bit or no.216 32bit). Do you still see error messages?
tested with
System Info GRASS version: 7.1.svn GRASS SVN revision: 67634 Build date: 2016-01-23 Build platform: x86_64-w64-mingw32 GDAL: 1.11.3 PROJ.4: 4.9.2 GEOS: 3.5.0 SQLite: 3.7.17 Python: 2.7.5 wxPython: 2.8.12.1 Platform: Windows-7-6.1.7601-SP1 (OSGeo4W)
C:\>d.fontlist -l cyrilc gothgbt gothgrt gothitt greekc greekcs greekp greeks italicc italiccs italict romanc romancs romand romans romant scriptc scripts AGENCYB AGENCYR ahronbd [...]
d.fontlist and change preferences within wxGUI works now. ready for backporting.
follow-up: 19 comment:15 by , 9 years ago
comment:16 by , 9 years ago
Thanks for working on this. Do we have an idea how did this bug happen? If yes, it would be good to have it documented here.
follow-up: 18 comment:17 by , 9 years ago
GRASS OSGeo4W package since 7.0.3 doesn't depend on msys
package. WinGRASS is built using completely fresh environment based on msys2 which is not shipped in osgeo4w framework. So the fontconfing file was just missing.
comment:18 by , 9 years ago
Replying to martinl:
GRASS OSGeo4W package since 7.0.3 doesn't depend on
msys
package. WinGRASS is built using completely fresh environment based on msys2 which is not shipped in osgeo4w framework. So the fontconfing file was just missing.
Thanks for clarifying!
comment:19 by , 9 years ago
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Confirmed on my Windows 7 machine.