]> git.saurik.com Git - wxWidgets.git/commitdiff
Document that setting colours for native controls might not work.
authorVadim Zeitlin <vadim@wxwidgets.org>
Sun, 11 Dec 2011 23:51:14 +0000 (23:51 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Sun, 11 Dec 2011 23:51:14 +0000 (23:51 +0000)
Changing colours of the native controls can't be relied on.

See #13745.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69986 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

interface/wx/window.h

index 192ce514f6a40902a3a5b81b6afbc8836202d3bb..dff00d556013b4aec7b3b85226ff009ec4ac4585 100644 (file)
@@ -1697,13 +1697,18 @@ public:
 
     /**
         Sets the background colour of the window.
 
     /**
         Sets the background colour of the window.
+
+        Notice that as with SetForegroundColour(), setting the background
+        colour of a native control may not affect the entire control and could
+        be not supported at all depending on the control and platform.
+
         Please see InheritAttributes() for explanation of the difference between
         this method and SetOwnBackgroundColour().
 
         @param colour
             The colour to be used as the background colour; pass
             wxNullColour to reset to the default colour.
         Please see InheritAttributes() for explanation of the difference between
         this method and SetOwnBackgroundColour().
 
         @param colour
             The colour to be used as the background colour; pass
             wxNullColour to reset to the default colour.
-            Note that you may want to use wxSystemSettings::GetColour() to retrieve 
+            Note that you may want to use wxSystemSettings::GetColour() to retrieve
             a suitable colour to use rather than setting an hard-coded one.
 
         @remarks The background colour is usually painted by the default
             a suitable colour to use rather than setting an hard-coded one.
 
         @remarks The background colour is usually painted by the default
@@ -1780,6 +1785,13 @@ public:
 
     /**
         Sets the foreground colour of the window.
 
     /**
         Sets the foreground colour of the window.
+
+        The meaning of foreground colour varies according to the window class;
+        it may be the text colour or other colour, or it may not be used at
+        all. Additionally, not all native controls support changing their
+        foreground colour so this method may change their colour only partially
+        or even not at all.
+
         Please see InheritAttributes() for explanation of the difference between
         this method and SetOwnForegroundColour().
 
         Please see InheritAttributes() for explanation of the difference between
         this method and SetOwnForegroundColour().
 
@@ -1787,9 +1799,6 @@ public:
             The colour to be used as the foreground colour; pass
             wxNullColour to reset to the default colour.
 
             The colour to be used as the foreground colour; pass
             wxNullColour to reset to the default colour.
 
-        @remarks The meaning of foreground colour varies according to the window class;
-                 it may be the text colour or other colour, or it may not be used at all.
-
         @return @true if the colour was really changed, @false if it was already set
                 to this colour and nothing was done.
 
         @return @true if the colour was really changed, @false if it was already set
                 to this colour and nothing was done.