]> git.mxchange.org Git - flightgear.git/commitdiff
apply custom widget fonts also to the legend, so that they show
authormfranz <mfranz>
Fri, 9 Jan 2009 11:58:28 +0000 (11:58 +0000)
committerTim Moore <timoore@redhat.com>
Fri, 9 Jan 2009 23:07:15 +0000 (00:07 +0100)
up in list/textbox etc. (This should really be separately settable
via style definition, but it's very rarely used and a change now
is probably not worth it as we'll probably switch to osgWidget,
anyway.)

src/GUI/dialog.cxx

index f540bfec914020c7659d4ff3d15c391a3f37d01a..41a967aa19dbc4725e1ac32f749474fed89d8c92 100644 (file)
@@ -711,10 +711,11 @@ FGDialog::setupObject (puObject * object, SGPropertyNode * props)
     if (props->hasValue("border"))
         object->setBorderThickness( props->getIntValue("border", 2) );
 
-    if ( SGPropertyNode *nft = props->getNode("font", false) ) {
+    if (SGPropertyNode *nft = props->getNode("font", false)) {
        FGFontCache *fc = globals->get_fontcache();
        puFont *lfnt = fc->get(nft);
        object->setLabelFont(*lfnt);
+       object->setLegendFont(*lfnt);
     } else {
        object->setLabelFont(*_font);
     }