[GRASS-dev] [GRASS GIS] #2450: Grass7: improve font selection dialog in GUI option for map display

#2450: Grass7: improve font selection dialog in GUI option for map display
-------------------------+--------------------------------------------------
Reporter: hellik | Owner: grass-dev@…
     Type: enhancement | Status: new
Priority: normal | Milestone: 7.0.0
Component: wxGUI | Version: unspecified
Keywords: fonts | Platform: Unspecified
      Cpu: Unspecified |
-------------------------+--------------------------------------------------
in the GUI options there are 2 tabs where you can choose fonts:

(1) fonts in command output
(2) fonts for map display

in (1) there is a nice dialog, for (2) the dialogue is rudimentary (see
screenshot attached).

fontcap file content:

{{{
[...]
cordiaub|CordiaUPC Bold|1|C:\Windows\Fonts\cordiaub.ttf|0|utf-8|
cordiaui|CordiaUPC Italic|1|C:\Windows\Fonts\cordiaui.ttf|0|utf-8|
cordiauz|CordiaUPC Bold Italic|1|C:\Windows\Fonts\cordiauz.ttf|0|utf-8|
cordiaz|Cordia New Bold Italic|1|C:\Windows\Fonts\cordiaz.ttf|0|utf-8|
cour|Courier New Regular|1|C:\Windows\Fonts\cour.ttf|0|utf-8|
courbd|Courier New Bold|1|C:\Windows\Fonts\courbd.ttf|0|utf-8|
courbi|Courier New Bold Italic|1|C:\Windows\Fonts\courbi.ttf|0|utf-8|
couri|Courier New Italic|1|C:\Windows\Fonts\couri.ttf|0|utf-8|
[...]
}}}

in (2) only the font acronym is displayed.

maybe the nice dialog of (1) could be added to (2)?

maybe it's also possible to add a font selection dialog to e.g. the d.vect
font=string option?

--
Ticket URL: <http://trac.osgeo.org/grass/ticket/2450&gt;
GRASS GIS <http://grass.osgeo.org>

#2450: Grass7: improve font selection dialog in GUI option for map display
-------------------------+--------------------------------------------------
Reporter: hellik | Owner: grass-dev@…
     Type: enhancement | Status: new
Priority: normal | Milestone: 7.0.0
Component: wxGUI | Version: unspecified
Keywords: fonts | Platform: Unspecified
      Cpu: Unspecified |
-------------------------+--------------------------------------------------

Comment(by annakrat):

I would definitely agree, I just don't understand where d.fontlist takes
the fonts and if they are always the same as in the other dialog.

--
Ticket URL: <http://trac.osgeo.org/grass/ticket/2450#comment:1&gt;
GRASS GIS <http://grass.osgeo.org>

#2450: Grass7: improve font selection dialog in GUI option for map display
-------------------------+--------------------------------------------------
Reporter: hellik | Owner: grass-dev@…
     Type: enhancement | Status: new
Priority: normal | Milestone: 7.0.0
Component: wxGUI | Version: unspecified
Keywords: fonts | Platform: Unspecified
      Cpu: Unspecified |
-------------------------+--------------------------------------------------

Comment(by hellik):

Replying to [comment:1 annakrat]:
> I would definitely agree, I just don't understand where d.fontlist takes
the fonts

probably from this file
''C:\OSGeo4W\apps\grass\grass-7.1.svn\etc\fontcap''

--
Ticket URL: <http://trac.osgeo.org/grass/ticket/2450#comment:2&gt;
GRASS GIS <http://grass.osgeo.org>

#2450: Grass7: improve font selection dialog in GUI option for map display
-------------------------+--------------------------------------------------
Reporter: hellik | Owner: grass-dev@…
     Type: enhancement | Status: new
Priority: normal | Milestone: 7.0.0
Component: wxGUI | Version: unspecified
Keywords: fonts | Platform: Unspecified
      Cpu: Unspecified |
-------------------------+--------------------------------------------------

Comment(by glynn):

Replying to [comment:1 annakrat]:
> I would definitely agree, I just don't understand where d.fontlist takes
the fonts
d.fontlist gets the list via D_font_list(), which calls COM_Font_list(),
which first reads the fonts from the file specified by $GRASS_FONT_CAP
(falling back to $GISBASE/etc/fontcap), then adds any fonts obtained by
the driver's Font_list method if provided (currently, only the cairo
driver implements this method).

--
Ticket URL: <http://trac.osgeo.org/grass/ticket/2450#comment:3&gt;
GRASS GIS <http://grass.osgeo.org>