diff --git a/docs/latex/wx/frame.tex b/docs/latex/wx/frame.tex index e6ec525ca4..25d5c3b519 100644 --- a/docs/latex/wx/frame.tex +++ b/docs/latex/wx/frame.tex @@ -24,25 +24,29 @@ application windows. \twocolwidtha{5cm} \begin{twocollist}\itemsep=0pt +\twocolitem{\windowstyle{wxDEFAULT\_FRAME\_STYLE}}{Defined as {\bf wxMINIMIZE\_BOX \pipe wxMAXIMIZE\_BOX \pipe wxRESIZE\_BOX \pipe wxSYSTEM\_MENU \pipe wxCAPTION}.} \twocolitem{\windowstyle{wxICONIZE}}{Display the frame iconized (minimized). Windows only. } \twocolitem{\windowstyle{wxCAPTION}}{Puts a caption on the frame.} -\twocolitem{\windowstyle{wxDEFAULT\_FRAME\_STYLE}}{Defined as {\bf wxMINIMIZE\_BOX \pipe wxMAXIMIZE\_BOX \pipe wxTHICK\_FRAME \pipe wxSYSTEM\_MENU \pipe wxCAPTION}.} \twocolitem{\windowstyle{wxMINIMIZE}}{Identical to {\bf wxICONIZE}. Windows only. } \twocolitem{\windowstyle{wxMINIMIZE\_BOX}}{Displays a minimize box on the frame. } \twocolitem{\windowstyle{wxMAXIMIZE}}{Displays the frame maximized. Windows only. } \twocolitem{\windowstyle{wxMAXIMIZE\_BOX}}{Displays a maximize box on the frame. } \twocolitem{\windowstyle{wxSTAY\_ON\_TOP}}{Stay on top of other windows. Windows only. } \twocolitem{\windowstyle{wxSYSTEM\_MENU}}{Displays a system menu. } -\twocolitem{\windowstyle{wxTHICK\_FRAME}}{Displays a thick frame around the window. Windows and Motif only.} \twocolitem{\windowstyle{wxSIMPLE\_BORDER}}{Displays no border or decorations. GTK and Windows only (?). } \twocolitem{\windowstyle{wxRESIZE\_BORDER}}{Displays a resizeable border around the window (Unix only).} \twocolitem{\windowstyle{wxFRAME\_FLOAT\_ON\_PARENT}}{Causes the frame to be above the parent window in the z-order and not shown in the taskbar. Without this style, frames are created as top-level windows that may be obscured by the parent window, and frame titles are shown in the taskbar. Windows and GTK. } \twocolitem{\windowstyle{wxFRAME\_TOOL\_WINDOW}}{Causes a frame with a small titlebar to be created; -the frame title does not appear in the taskbar. Windows only. } +the frame title does not appear in the taskbar. Windows only.} \end{twocollist} +The default frame style is for normal, resizeable frames. To create a frame +which can not be resized by user, you may use the following combination of +styles: {\tt wxDEFAULT\_FRAME\_STYLE \& \~(wxRESIZE\_BORDER \pipe wxRESIZE\_BOX +\pipe wxMAXIMIZE\_BOX)}. + See also \helpref{window styles overview}{windowstyles}. \wxheading{Remarks} diff --git a/include/wx/defs.h b/include/wx/defs.h index 1eeb5d50ef..64eee1e849 100644 --- a/include/wx/defs.h +++ b/include/wx/defs.h @@ -892,16 +892,21 @@ enum wxStretch #define wxICONIZE 0x4000 #define wxMINIMIZE wxICONIZE #define wxMAXIMIZE 0x2000 -#define wxTHICK_FRAME 0x1000 +// free value: 0x1000 #define wxSYSTEM_MENU 0x0800 #define wxMINIMIZE_BOX 0x0400 #define wxMAXIMIZE_BOX 0x0200 #define wxTINY_CAPTION_HORIZ 0x0100 #define wxTINY_CAPTION_VERT 0x0080 -#define wxRESIZE_BOX wxMAXIMIZE_BOX #define wxRESIZE_BORDER 0x0040 + +// deprecated versions defined for compatibility reasons +#define wxRESIZE_BOX wxMAXIMIZE_BOX +#define wxTHICK_FRAME wxRESIZE_BORDER + #define wxDIALOG_MODAL 0x0020 #define wxDIALOG_MODELESS 0x0000 + // Add for normal Windows frame behaviour #define wxFRAME_FLOAT_ON_PARENT 0x0020 diff --git a/src/msw/frame.cpp b/src/msw/frame.cpp index bbf1b76ccd..affc9f7a81 100644 --- a/src/msw/frame.cpp +++ b/src/msw/frame.cpp @@ -643,7 +643,7 @@ bool wxFrame::MSWCreate(int id, wxWindow *parent, const wxChar *wclass, wxWindow msflags |= WS_THICKFRAME; if (style & wxSYSTEM_MENU) msflags |= WS_SYSMENU; - if ((style & wxMINIMIZE) || (style & wxICONIZE)) + if ( style & wxMINIMIZE ) msflags |= WS_MINIMIZE; if (style & wxMAXIMIZE) msflags |= WS_MAXIMIZE;