theming (some applications look bad without 3D borders)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@26064
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
+All:
+
+All (GUI):
+
+- wxHtmlWindow now delays image scaling until rendering,
+ resulting in much better display of scaled images
+
- wxWindow::Freeze()/Thaw() can now be nested
- wxWindow::Freeze()/Thaw() can now be nested
+- Added wxSP_NO_XP_THEME style to wxSplitterWindow to switch off
+ XP theming (some applications look bad without 3D borders)
split into two programmatically (perhaps from a menu command), and unsplit
either programmatically or via the wxSplitterWindow user interface.
split into two programmatically (perhaps from a menu command), and unsplit
either programmatically or via the wxSplitterWindow user interface.
-Appropriate 3D shading for the Windows 95 user interface is an option -
-this is also recommended for GTK. Optionally, the sash can be made to
-look more like the native control under MacOS X.
-
\wxheading{Window styles}
\begin{twocollist}\itemsep=0pt
\wxheading{Window styles}
\begin{twocollist}\itemsep=0pt
\twocolitem{\windowstyle{wxSP\_3DBORDER}}{Synonym for wxSP\_BORDER.}
\twocolitem{\windowstyle{wxSP\_BORDER}}{Draws a standard border.}
\twocolitem{\windowstyle{wxSP\_NOBORDER}}{No border (default).}
\twocolitem{\windowstyle{wxSP\_3DBORDER}}{Synonym for wxSP\_BORDER.}
\twocolitem{\windowstyle{wxSP\_BORDER}}{Draws a standard border.}
\twocolitem{\windowstyle{wxSP\_NOBORDER}}{No border (default).}
+\twocolitem{\windowstyle{wxSP\_NO\_XP\_THEME}}{Under Windows XP, switches off the attempt to draw the
+splitter using Windows XP theming, so the borders and sash will take on the pre-XP look.}
\twocolitem{\windowstyle{wxSP\_PERMIT\_UNSPLIT}}{Always allow to
unsplit, even with the minimum pane size other than zero.}
\twocolitem{\windowstyle{wxSP\_LIVE\_UPDATE}}{Don't draw XOR line but resize the child windows immediately.}
\twocolitem{\windowstyle{wxSP\_PERMIT\_UNSPLIT}}{Always allow to
unsplit, even with the minimum pane size other than zero.}
\twocolitem{\windowstyle{wxSP\_LIVE\_UPDATE}}{Don't draw XOR line but resize the child windows immediately.}
#define wxSP_LIVE_UPDATE 0x0080
#define wxSP_3DSASH 0x0100
#define wxSP_3DBORDER 0x0200
#define wxSP_LIVE_UPDATE 0x0080
#define wxSP_3DSASH 0x0100
#define wxSP_3DBORDER 0x0200
+#define wxSP_NO_XP_THEME 0x0400
#define wxSP_BORDER wxSP_3DBORDER
#define wxSP_3D (wxSP_3DBORDER | wxSP_3DSASH)
#define wxSP_BORDER wxSP_3DBORDER
#define wxSP_3D (wxSP_3DBORDER | wxSP_3DSASH)
MySplitterWindow::MySplitterWindow(wxFrame *parent)
: wxSplitterWindow(parent, -1,
wxDefaultPosition, wxDefaultSize,
MySplitterWindow::MySplitterWindow(wxFrame *parent)
: wxSplitterWindow(parent, -1,
wxDefaultPosition, wxDefaultSize,
- 0x700| wxSP_LIVE_UPDATE | wxCLIP_CHILDREN)
+ wxSP_3D | wxSP_LIVE_UPDATE |
+ wxCLIP_CHILDREN /* | wxSP_NO_XP_THEME */ )
#include "wx/dc.h"
#endif //WX_PRECOMP
#include "wx/dc.h"
#endif //WX_PRECOMP
+#include "wx/splitter.h"
#include "wx/msw/uxtheme.h"
// ----------------------------------------------------------------------------
#include "wx/msw/uxtheme.h"
// ----------------------------------------------------------------------------
static const wxCoord SASH_WIDTH = 4;
wxSplitterRenderParams
static const wxCoord SASH_WIDTH = 4;
wxSplitterRenderParams
-wxRendererXP::GetSplitterParams(const wxWindow * WXUNUSED(win))
+wxRendererXP::GetSplitterParams(const wxWindow * win)
- return wxSplitterRenderParams(SASH_WIDTH, 0, false);
+ if (win->GetWindowStyle() & wxSP_NO_XP_THEME)
+ return m_rendererNative.GetSplitterParams(win);
+ else
+ return wxSplitterRenderParams(SASH_WIDTH, 0, false);
-wxRendererXP::DrawSplitterBorder(wxWindow * WXUNUSED(win),
- wxDC& WXUNUSED(dc),
- const wxRect& WXUNUSED(rect),
- int WXUNUSED(flags))
+wxRendererXP::DrawSplitterBorder(wxWindow * win,
+ wxDC& dc,
+ const wxRect& rect,
+ int flags)
+ if (win->GetWindowStyle() & wxSP_NO_XP_THEME)
+ {
+ m_rendererNative.DrawSplitterBorder(win, dc, rect, flags);
+ }
const wxSize& size,
wxCoord position,
wxOrientation orient,
const wxSize& size,
wxCoord position,
wxOrientation orient,
+ if (win->GetWindowStyle() & wxSP_NO_XP_THEME)
+ {
+ m_rendererNative.DrawSplitterSash(
+ win, dc, size, position, orient, flags);
+ return;
+ }
+
// I don't know if it is correct to use the rebar background for the
// splitter but it least this works ok in the default theme
wxUxThemeHandle hTheme(win, L"REBAR");
// I don't know if it is correct to use the rebar background for the
// splitter but it least this works ok in the default theme
wxUxThemeHandle hTheme(win, L"REBAR");