]> git.saurik.com Git - wxWidgets.git/commitdiff
added wxSYS_ICONTITLE_FONT (patch 816026)
authorVadim Zeitlin <vadim@wxwidgets.org>
Thu, 16 Oct 2003 11:17:38 +0000 (11:17 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Thu, 16 Oct 2003 11:17:38 +0000 (11:17 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@24200 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

docs/changes.txt
docs/latex/wx/settings.tex
include/wx/settings.h
src/msw/settings.cpp

index 76829f19d7f5dfd49e72deef8612319f1622873e..2a3a55e613dab5eed403c684ca00079c5acf9d05 100644 (file)
@@ -98,6 +98,7 @@ wxMSW:
 - make it possible to give focus to the notebook tabs (Hajo Kirchhoff)
 - MDI child frames are not always resizeable any more (Andrei Fortuna)
 - fixed enumerating of entries/groups under '/' in wxRegConfig
+- added wxSYS_ICONTITLE_FONT (Andreas Pflug)
 
 wxGTK:
 
index c9f5edfe155ed299ec9902ae382c9830a827f4f2..4fe7dc5e30b6625f3c055594efece83de54b538e 100644 (file)
@@ -86,8 +86,10 @@ Returns a system font.
 \twocolitem{{\bf wxSYS\_ANSI\_VAR\_FONT}}{Windows variable-pitch (proportional) font.}
 \twocolitem{{\bf wxSYS\_SYSTEM\_FONT}}{System font.}
 \twocolitem{{\bf wxSYS\_DEVICE\_DEFAULT\_FONT}}{Device-dependent font (Windows NT only).}
-\twocolitem{{\bf wxSYS\_DEFAULT\_GUI\_FONT}}{Default font for user interface objects such as menus and dialog boxes.
-Not available in versions of Windows earlier than Windows 95 or Windows NT 4.0.}
+\twocolitem{{\bf wxSYS\_DEFAULT\_GUI\_FONT}}{Default font for user interface
+objects such as menus and dialog boxes.}
+\twocolitem{{\bf wxSYS\_ICONTITLE\_FONT}}{Font for the icon titles (Windows
+only, same as default GUI font on other platforms}
 \end{twocollist}
 
 \pythonnote{This static method is implemented in Python as a
index 168db483f2b362616872d682b1e34206c4cf66aa..4d4f6804578d4741611a9faa0b2323a26c8ab5cc 100644 (file)
@@ -28,7 +28,11 @@ enum wxSystemFont
     wxSYS_DEVICE_DEFAULT_FONT,
     wxSYS_DEFAULT_PALETTE,
     wxSYS_SYSTEM_FIXED_FONT,
-    wxSYS_DEFAULT_GUI_FONT
+    wxSYS_DEFAULT_GUI_FONT,
+    wxSYS_ICONTITLE_FONT
+#ifndef __WXMSW__
+    = wxSYS_DEFAULT_GUI_FONT
+#endif
 };
 
 // possible values for wxSystemSettings::GetColour() parameter
index 9ba29bc069f33617f7b15b8df470adc93422525b..6087406cf4c25b4fd21baeb5bed31927b2286abc 100644 (file)
@@ -250,6 +250,14 @@ wxFont wxCreateFontFromStockObject(int index)
 
 wxFont wxSystemSettingsNative::GetFont(wxSystemFont index)
 {
+    // this one is special: we don't get it from GetStockObject()
+    if ( index == wxSYS_ICONTITLE_FONT )
+    {
+        LOGFONT lf;
+        SystemParametersInfo(SPI_GETICONTITLELOGFONT, sizeof(lf), &lf, 0);
+        return wxCreateFontFromLogFont(&lf);
+    }
+
     // wxWindow ctor calls GetSystemFont(wxSYS_DEFAULT_GUI_FONT) so we're
     // called fairly often - this is why we cache this particular font
     bool isDefaultRequested = index == wxSYS_DEFAULT_GUI_FONT;