From 0e528b997e87057723d1b823dd86e3f69ebb672b Mon Sep 17 00:00:00 2001
From: Julian Smart <julian@anthemion.co.uk>
Date: Sat, 6 Nov 1999 17:12:10 +0000
Subject: [PATCH] Added some makefiles, fixed a BC++ problem in controls.cpp;
 changed some class ordering for VC++ 1.5

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@4404 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
---
 distrib/msw/generic.rsp       | 12 +++++++
 distrib/msw/tmake/dos.t       | 42 +++++++++++++++-------
 docs/latex/wx/function.tex    | 67 +++++++++++++++++------------------
 docs/readme.txt               | 18 +++++++---
 include/wx/event.h            |  4 +++
 include/wx/menu.h             |  6 ++--
 include/wx/msw/private.h      |  4 +++
 include/wx/msw/setup0.h       |  6 ++++
 samples/controls/controls.cpp | 31 ++++++++--------
 samples/font/font.def         |  7 ++++
 samples/font/makefile.b32     | 16 +++++++++
 samples/font/makefile.bcc     | 19 ++++++++++
 samples/font/makefile.g95     | 16 +++++++++
 samples/font/makefile.wat     | 15 ++++++++
 samples/menu/makefile.b32     | 16 +++++++++
 samples/menu/makefile.bcc     | 19 ++++++++++
 samples/menu/makefile.g95     | 16 +++++++++
 samples/menu/makefile.vc      | 18 ++++++++++
 samples/menu/makefile.wat     | 15 ++++++++
 samples/menu/menu.def         |  7 ++++
 samples/menu/menu.rc          |  1 +
 samples/minimal/makefile.vc   |  2 +-
 src/makemsc.env               |  2 +-
 src/msw/fontutil.cpp          |  2 ++
 src/msw/makefile.dos          | 49 ++++++++++++++++++-------
 src/msw/menu.cpp              |  2 +-
 src/msw/spinbutt.cpp          |  6 ++++
 src/msw/spinctrl.cpp          |  6 ++++
 28 files changed, 340 insertions(+), 84 deletions(-)
 create mode 100644 samples/font/font.def
 create mode 100644 samples/font/makefile.b32
 create mode 100644 samples/font/makefile.bcc
 create mode 100644 samples/font/makefile.g95
 create mode 100644 samples/font/makefile.wat
 create mode 100644 samples/menu/makefile.b32
 create mode 100644 samples/menu/makefile.bcc
 create mode 100644 samples/menu/makefile.g95
 create mode 100644 samples/menu/makefile.vc
 create mode 100644 samples/menu/makefile.wat
 create mode 100644 samples/menu/menu.def
 create mode 100644 samples/menu/menu.rc

diff --git a/distrib/msw/generic.rsp b/distrib/msw/generic.rsp
index 697c671c3b..e55cb19893 100644
--- a/distrib/msw/generic.rsp
+++ b/distrib/msw/generic.rsp
@@ -1012,3 +1012,15 @@ samples/scrollsub/*.png
 samples/scrollsub/*.ico
 samples/scrollsub/*.txt
 
+samples/menu/*.cpp
+samples/menu/*.h
+samples/menu/makefile*
+samples/menu/*.rc
+samples/menu/*.def
+samples/menu/*.bmp
+samples/menu/*.xpm
+samples/menu/*.xbm
+samples/menu/*.png
+samples/menu/*.ico
+samples/menu/*.txt
+
diff --git a/distrib/msw/tmake/dos.t b/distrib/msw/tmake/dos.t
index f3e30fb933..592ab83d3e 100644
--- a/distrib/msw/tmake/dos.t
+++ b/distrib/msw/tmake/dos.t
@@ -32,7 +32,9 @@
         $isCFile = $file =~ /\.c$/;
         $file =~ s/cp?p?$/obj/;
         $obj = "\$(COMMDIR)\\" . $file . " ";
-        $project{"WXCOMMONOBJS"} .= $obj;
+        #! $project{"WXCOMMONOBJS"} .= $obj;
+        #! have to split lib in 2 halves because otherwise it's too big
+        $project{$file =~ "^[a-o]" ? "WXCOMMONOBJS1" : "WXCOMMONOBJS2"} .= $obj;
         $project{"WXCOBJS"} .= $obj if $isCFile;
     }
 
@@ -109,9 +111,13 @@ MSWDIR=.
 
 GENERICOBJS= #$ ExpandList("WXGENERICOBJS");
 
-COMMONOBJS = \
+# we can't have all objects in one list because the library becomes too big
+COMMONOBJS1 = \
 		$(COMMDIR)\y_tab.obj \
-		#$ ExpandList("WXCOMMONOBJS");
+		#$ ExpandList("WXCOMMONOBJS1");
+
+COMMONOBJS2 = \
+		#$ ExpandList("WXCOMMONOBJS2");
 
 # we can't have all objects in one list because the library becomes too big
 MSWOBJS1 = #$ ExpandList("WXMSWOBJS1");
@@ -122,46 +128,56 @@ MSWOBJS2 = #$ ExpandList("WXMSWOBJS2");
 #  $(OLEDIR)\xpmhand \
 #  $(OLEDIR)\pnghand \
 
-OBJECTS = $(COMMONOBJS) $(GENERICOBJS) $(MSWOBJS1) $(MSWOBJS2)
+OBJECTS = $(COMMONOBJS1) $(COMMONOBJS2) $(GENERICOBJS) $(MSWOBJS1) $(MSWOBJS2)
 
 # Normal, static library
-all:    $(DUMMYOBJ) $(WXDIR)\lib\wx1.lib $(WXDIR)\lib\wx2.lib $(WXDIR)\lib\wx3.lib $(WXDIR)\lib\wx4.lib
+all:    $(DUMMYOBJ) $(WXDIR)\lib\wx1.lib $(WXDIR)\lib\wx2.lib $(WXDIR)\lib\wx3.lib $(WXDIR)\lib\wx4.lib $(WXDIR)\lib\wx5.lib
 
-$(WXDIR)\lib\wx1.lib:      $(COMMONOBJS) $(PERIPH_LIBS)
+$(WXDIR)\lib\wx1.lib:      $(COMMONOBJS1) $(PERIPH_LIBS)
 	-erase $(WXDIR)\lib\wx1.lib
 	lib /PAGESIZE:128 @<<
 $(WXDIR)\lib\wx1.lib
 y
-$(COMMONOBJS) $(PERIPH_LIBS)
+$(COMMONOBJS1) $(PERIPH_LIBS)
 nul
 ;
 <<
 
-$(WXDIR)\lib\wx2.lib:      $(GENERICOBJS)
+$(WXDIR)\lib\wx2.lib:      $(COMMONOBJS2)
 	-erase $(WXDIR)\lib\wx2.lib
 	lib /PAGESIZE:128 @<<
 $(WXDIR)\lib\wx2.lib
 y
-$(GENERICOBJS)
+$(COMMONOBJS2)
 nul
 ;
 <<
 
-$(WXDIR)\lib\wx3.lib:      $(MSWOBJS1)
+$(WXDIR)\lib\wx3.lib:      $(GENERICOBJS)
 	-erase $(WXDIR)\lib\wx3.lib
 	lib /PAGESIZE:128 @<<
 $(WXDIR)\lib\wx3.lib
 y
-$(MSWOBJS1)
+$(GENERICOBJS)
 nul
 ;
 <<
 
-$(WXDIR)\lib\wx4.lib:      $(MSWOBJS2)
+$(WXDIR)\lib\wx4.lib:      $(MSWOBJS1)
 	-erase $(WXDIR)\lib\wx4.lib
 	lib /PAGESIZE:128 @<<
 $(WXDIR)\lib\wx4.lib
 y
+$(MSWOBJS1)
+nul
+;
+<<
+
+$(WXDIR)\lib\wx5.lib:      $(MSWOBJS2)
+	-erase $(WXDIR)\lib\wx5.lib
+	lib /PAGESIZE:128 @<<
+$(WXDIR)\lib\wx5.lib
+y
 $(MSWOBJS2)
 nul
 ;
@@ -184,7 +200,7 @@ $(CPPFLAGS) /YcWX/WXPREC.H /c /Tp $*.$(SRCSUFF)
 <<
 
 #${
-    $_ = $project{"WXMSWOBJS1"} . $project{"WXMSWOBJS2"} . $project{"WXCOMMONOBJS"} . $project{"WXGENERICOBJS"};
+    $_ = $project{"WXMSWOBJS1"} . $project{"WXMSWOBJS2"} . $project{"WXCOMMONOBJS1"} . $project{"WXCOMMONOBJS2"} . $project{"WXGENERICOBJS"};
     my @objs = split;
     foreach (@objs) {
         if ( $project{"WXCOBJS"} =~ / \Q$_\E / ) {
diff --git a/docs/latex/wx/function.tex b/docs/latex/wx/function.tex
index 66b72d8a8c..c091da2b8e 100644
--- a/docs/latex/wx/function.tex
+++ b/docs/latex/wx/function.tex
@@ -420,16 +420,15 @@ the front when the dialog box is popped up.
 
 \membersection{::wxCreateFileTipProvider}\label{wxcreatefiletipprovider}
 
-\func{wxTipProvider *}{wxCreateFileTipProvider}{
-    \param{const wxString\& }{filename},
-    \param{size\_t }{currentTip}}
+\func{wxTipProvider *}{wxCreateFileTipProvider}{\param{const wxString\& }{filename},
+ \param{size\_t }{currentTip}}
 
 This function creates a \helpref{wxTipProvider}{wxtipprovider} which may be
 used with \helpref{wxShowTip}{wxshowtip}.
 
 \docparam{filename}{The name of the file containing the tips, one per line}
 \docparam{currentTip}{The index of the first tip to show - normally this index
-    is remembered between the 2 program runs.}
+is remembered between the 2 program runs.}
 
 \wxheading{See also:}
 
@@ -442,9 +441,9 @@ used with \helpref{wxShowTip}{wxshowtip}.
 \membersection{::wxFileSelector}\label{wxfileselector}
 
 \func{wxString}{wxFileSelector}{\param{const wxString\& }{message}, \param{const wxString\& }{default\_path = ""},\\
-  \param{const wxString\& }{default\_filename = ""}, \param{const wxString\& }{default\_extension = ""},\\
-  \param{const wxString\& }{wildcard = ``*.*''}, \param{int }{flags = 0}, \param{wxWindow *}{parent = ""},\\
-  \param{int}{ x = -1}, \param{int}{ y = -1}}
+ \param{const wxString\& }{default\_filename = ""}, \param{const wxString\& }{default\_extension = ""},\\
+ \param{const wxString\& }{wildcard = ``*.*''}, \param{int }{flags = 0}, \param{wxWindow *}{parent = ""},\\
+ \param{int}{ x = -1}, \param{int}{ y = -1}}
 
 Pops up a file selector box. In Windows, this is the common file selector
 dialog. In X, this is a file selector box with somewhat less functionality.
@@ -485,14 +484,14 @@ if (s)
 \membersection{::wxGetNumberFromUser}\label{wxgetnumberfromuser}
 
 \func{long}{wxGetNumberFromUser}{
-    \param{const wxString\& }{message},
-    \param{const wxString\& }{prompt},
-    \param{const wxString\& }{caption},
-    \param{long }{value},
-    \param{long }{min = 0},
-    \param{long }{max = 100},
-    \param{wxWindow *}{parent = NULL},
-    \param{const wxPoint\& }{pos = wxDefaultPosition}}
+ \param{const wxString\& }{message},
+ \param{const wxString\& }{prompt},
+ \param{const wxString\& }{caption},
+ \param{long }{value},
+ \param{long }{min = 0},
+ \param{long }{max = 100},
+ \param{wxWindow *}{parent = NULL},
+ \param{const wxPoint\& }{pos = wxDefaultPosition}}
 
 Shows a dialog asking the user for numeric input. The dialogs title is set to 
 {\it caption}, it contains a (possibly) multiline {\it message} above the
@@ -512,8 +511,8 @@ Dialog is centered on its {\it parent} unless an explicit position is given in
 \membersection{::wxGetTextFromUser}\label{wxgettextfromuser}
 
 \func{wxString}{wxGetTextFromUser}{\param{const wxString\& }{message}, \param{const wxString\& }{caption = ``Input text"},\\
-  \param{const wxString\& }{default\_value = ``"}, \param{wxWindow *}{parent = NULL},\\
-  \param{int}{ x = -1}, \param{int}{ y = -1}, \param{bool}{ centre = TRUE}}
+ \param{const wxString\& }{default\_value = ``"}, \param{wxWindow *}{parent = NULL},\\
+ \param{int}{ x = -1}, \param{int}{ y = -1}, \param{bool}{ centre = TRUE}}
 
 Pop up a dialog box with title set to {\it caption}, message {\it message}, and a
 \rtfsp{\it default\_value}.  The user may type in text and press OK to return this text,
@@ -529,9 +528,9 @@ is centred; if FALSE, the message is left-justified.
 \membersection{::wxGetMultipleChoice}\label{wxgetmultiplechoice}
 
 \func{int}{wxGetMultipleChoice}{\param{const wxString\& }{message}, \param{const wxString\& }{caption}, \param{int}{ n}, \param{const wxString\& }{choices[]},\\
-  \param{int }{nsel}, \param{int *}{selection},
-  \param{wxWindow *}{parent = NULL}, \param{int}{ x = -1}, \param{int}{ y = -1},\\
-  \param{bool}{ centre = TRUE}, \param{int }{width=150}, \param{int }{height=200}}
+ \param{int }{nsel}, \param{int *}{selection},
+ \param{wxWindow *}{parent = NULL}, \param{int}{ x = -1}, \param{int}{ y = -1},\\
+ \param{bool}{ centre = TRUE}, \param{int }{width=150}, \param{int }{height=200}}
 
 Pops up a dialog box containing a message, OK/Cancel buttons and a multiple-selection
 listbox. The user may choose one or more item(s) and press OK or Cancel.
@@ -555,8 +554,8 @@ is centred; if FALSE, the message is left-justified.
 \membersection{::wxGetSingleChoice}\label{wxgetsinglechoice}
 
 \func{wxString}{wxGetSingleChoice}{\param{const wxString\& }{message}, \param{const wxString\& }{caption}, \param{int}{ n}, \param{const wxString\& }{choices[]},\\
-  \param{wxWindow *}{parent = NULL}, \param{int}{ x = -1}, \param{int}{ y = -1},\\
-  \param{bool}{ centre = TRUE}, \param{int }{width=150}, \param{int }{height=200}}
+ \param{wxWindow *}{parent = NULL}, \param{int}{ x = -1}, \param{int}{ y = -1},\\
+ \param{bool}{ centre = TRUE}, \param{int }{width=150}, \param{int }{height=200}}
 
 Pops up a dialog box containing a message, OK/Cancel buttons and a single-selection
 listbox. The user may choose an item and press OK to return a string or
@@ -574,8 +573,8 @@ is centred; if FALSE, the message is left-justified.
 \membersection{::wxGetSingleChoiceIndex}\label{wxgetsinglechoiceindex}
 
 \func{int}{wxGetSingleChoiceIndex}{\param{const wxString\& }{message}, \param{const wxString\& }{caption}, \param{int}{ n}, \param{const wxString\& }{choices[]},\\
-  \param{wxWindow *}{parent = NULL}, \param{int}{ x = -1}, \param{int}{ y = -1},\\
-  \param{bool}{ centre = TRUE}, \param{int }{width=150}, \param{int }{height=200}}
+ \param{wxWindow *}{parent = NULL}, \param{int}{ x = -1}, \param{int}{ y = -1},\\
+ \param{bool}{ centre = TRUE}, \param{int }{width=150}, \param{int }{height=200}}
 
 As {\bf wxGetSingleChoice} but returns the index representing the selected string.
 If the user pressed cancel, -1 is returned.
@@ -587,8 +586,8 @@ If the user pressed cancel, -1 is returned.
 \membersection{::wxGetSingleChoiceData}\label{wxgetsinglechoicedata}
 
 \func{wxString}{wxGetSingleChoiceData}{\param{const wxString\& }{message}, \param{const wxString\& }{caption}, \param{int}{ n}, \param{const wxString\& }{choices[]},\\
-  \param{const wxString\& }{client\_data[]}, \param{wxWindow *}{parent = NULL}, \param{int}{ x = -1},\\
-  \param{int}{ y = -1}, \param{bool}{ centre = TRUE}, \param{int }{width=150}, \param{int }{height=200}}
+ \param{const wxString\& }{client\_data[]}, \param{wxWindow *}{parent = NULL}, \param{int}{ x = -1},\\
+ \param{int}{ y = -1}, \param{bool}{ centre = TRUE}, \param{int }{width=150}, \param{int }{height=200}}
 
 As {\bf wxGetSingleChoice} but takes an array of client data pointers
 corresponding to the strings, and returns one of these pointers.
@@ -600,7 +599,7 @@ corresponding to the strings, and returns one of these pointers.
 \membersection{::wxMessageBox}\label{wxmessagebox}
 
 \func{int}{wxMessageBox}{\param{const wxString\& }{message}, \param{const wxString\& }{caption = ``Message"}, \param{int}{ style = wxOK \pipe wxCENTRE},\\
-  \param{wxWindow *}{parent = NULL}, \param{int}{ x = -1}, \param{int}{ y = -1}}
+ \param{wxWindow *}{parent = NULL}, \param{int}{ x = -1}, \param{int}{ y = -1}}
 
 General purpose message dialog.  {\it style} may be a bit list of the
 following identifiers:
@@ -645,22 +644,20 @@ The symbols are not shown when the generic function is used.
 
 \membersection{::wxShowTip}\label{wxshowtip}
 
-\func{bool}{wxShowTip}{
-    \param{wxWindow *}{parent},
-    \param{wxTipProvider *}{tipProvider},
-    \param{bool }{showAtStartup = TRUE}}
+\func{bool}{wxShowTip}{\param{wxWindow *}{parent},
+ \param{wxTipProvider *}{tipProvider},
+ \param{bool }{showAtStartup = TRUE}}
 
 This function shows a "startup tip" to the user.
 
 \docparam{parent}{The parent window for the modal dialog}
 
 \docparam{tipProvider}{An object which is used to get the text of the tips.
-    It may be created with 
-    \helpref{wxCreateFileTipProvider}{wxcreatefiletipprovider} function.}
+It may be created with the \helpref{wxCreateFileTipProvider}{wxcreatefiletipprovider} function.}
 
 \docparam{showAtStartup}{Should be TRUE if startup tips are shown, FALSE
-    otherwise. This is used as the initial value for "Show tips at startup"
-    checkbox which is shown in the tips dialog.}
+otherwise. This is used as the initial value for "Show tips at startup"
+checkbox which is shown in the tips dialog.}
 
 \wxheading{See also:}
 
diff --git a/docs/readme.txt b/docs/readme.txt
index a8b5870f96..6665ca3a1d 100644
--- a/docs/readme.txt
+++ b/docs/readme.txt
@@ -1,4 +1,4 @@
-wxWindows 2.1.10
+wxWindows 2.1.11
 ----------------
 
 Welcome to wxWindows 2, a sophisticated cross-platform C++
@@ -21,20 +21,30 @@ important documents and samples.
 Changes in this release
 -----------------------
 
-These are the major improvements:
+These are some of the major improvements:
 
-wxWindows 2.1.10
+wxWindows 2.1.11
 ================
 
 - Numerous bug fixes and consistency improvements.
 - Further samples.
 - Factoring out of some code into base classes, for easier
   maintenance.
+- Ability to compile library in console (non-GUI) mode.
 - Integration of wxHTML widget and help controller into
   wxWindows. wxHTML allows HTML viewing and printing.
 - New classes wxChrono, wxDialUpManager, wxFontEnumerator,
-  wxWizard, etc.
+  wxWizard, wxStaticLine, etc.
+- wxShowTip for showing 'startup tips' to the user.
 - wxSocket and wxThread classes rewritten.
+- New, consistent drag and drop API (not wxMotif).
+- Better-looking dialogs in wxGTK.
+- wxSizers reimplemented and used to specify window layout
+  for some generic dialogs.
+- New, more sophisticated wxGrid class (in beta). The old grid
+  class can still be used.
+- Text alignment options in wxStaticText.
+- wxImage class extended to read PCX and GIF files.
 - Documentation improvements.
 
 Platforms supported
diff --git a/include/wx/event.h b/include/wx/event.h
index 1a85931212..0d90ca6b44 100644
--- a/include/wx/event.h
+++ b/include/wx/event.h
@@ -613,6 +613,7 @@ public:
             *ypos = m_y;
     }
 
+#ifndef __WIN16__
     void GetPosition(long *xpos, long *ypos) const
     {
         if (xpos)
@@ -620,6 +621,7 @@ public:
         if (ypos)
             *ypos = (long)m_y;
     }
+#endif
 
     // Find the position of the event
     wxPoint GetPosition() const { return wxPoint(m_x, m_y); }
@@ -694,11 +696,13 @@ public:
         if (ypos) *ypos = m_y;
     }
 
+#ifndef __WIN16__
     void GetPosition(long *xpos, long *ypos) const
     {
         if (xpos) *xpos = (long)m_x; 
         if (ypos) *ypos = (long)m_y;
     }
+#endif
 
     wxPoint GetPosition() const
         { return wxPoint(m_x, m_y); }
diff --git a/include/wx/menu.h b/include/wx/menu.h
index 599326cb18..83576de1cf 100644
--- a/include/wx/menu.h
+++ b/include/wx/menu.h
@@ -57,9 +57,6 @@ public:
     // menu construction
     // -----------------
 
-    // append a separator to the menu
-    void AppendSeparator() { Append(wxID_SEPARATOR, wxEmptyString); }
-
     // append a normal item to the menu
     void Append(int id,
                 const wxString& text,
@@ -69,6 +66,9 @@ public:
         DoAppend(wxMenuItem::New((wxMenu *)this, id, text, help, isCheckable));
     }
 
+    // append a separator to the menu
+    void AppendSeparator() { Append(wxID_SEPARATOR, wxEmptyString); }
+
     // append a submenu
     void Append(int id,
                 const wxString& text,
diff --git a/include/wx/msw/private.h b/include/wx/msw/private.h
index a209ee9ca1..9d82cbe281 100644
--- a/include/wx/msw/private.h
+++ b/include/wx/msw/private.h
@@ -215,7 +215,11 @@ extern LONG APIENTRY _EXPORT
 // ---------------------------------------------------------------------------
 
 // a wrapper macro for ZeroMemory()
+#ifdef __WIN32__
 #define wxZeroMemory(obj)   ::ZeroMemory(&obj, sizeof(obj))
+#else
+#define wxZeroMemory(obj)   memset((void*) & obj, 0, sizeof(obj))
+#endif
 
 // make conversion from wxColour and COLORREF a bit less painful
 inline COLORREF wxColourToRGB(const wxColour& c)
diff --git a/include/wx/msw/setup0.h b/include/wx/msw/setup0.h
index 37e3cf4ccd..d853492a2b 100644
--- a/include/wx/msw/setup0.h
+++ b/include/wx/msw/setup0.h
@@ -420,6 +420,12 @@
 #undef wxUSE_TOOLTIPS
 #define wxUSE_TOOLTIPS 0
 
+#undef wxUSE_SPINCTRL
+#define wxUSE_SPINCTRL 0
+
+#undef wxUSE_SPINBTN
+#define wxUSE_SPINBTN 0
+
 #undef wxUSE_LIBPNG
 #define wxUSE_LIBPNG 0
 
diff --git a/samples/controls/controls.cpp b/samples/controls/controls.cpp
index 610d0f8a01..6bc15448f9 100644
--- a/samples/controls/controls.cpp
+++ b/samples/controls/controls.cpp
@@ -49,18 +49,21 @@
 
 #ifdef __WIN16__
     // Win16 doesn't have them
-    #undef wxUSE_SPINBUTTON
-    #define wxUSE_SPINBUTTON 0
+    #ifndef wxUSE_SPINBTN
+    #undef wxUSE_SPINBTN
+    #define wxUSE_SPINBTN 0
 #else
-    #if !defined(wxUSE_SPINBUTTON)
-        #define wxUSE_SPINBUTTON 1
+    #if !defined(wxUSE_SPINBTN)
+        #define wxUSE_SPINBTN 1
     #endif
 #endif // __WIN16__
 
 #include "wx/progdlg.h"
 
 // VZ: this is a temp. hack, will remove soon
+#ifndef wxUSE_SPINCTRL
 #define wxUSE_SPINCTRL 1
+#endif
 
 #if wxUSE_SPINCTRL
     #include "wx/spinctrl.h"
@@ -97,13 +100,13 @@ public:
     void OnPageChanging( wxNotebookEvent &event );
     void OnSliderUpdate( wxCommandEvent &event );
     void OnUpdateLabel( wxCommandEvent &event );
-#if wxUSE_SPINBUTTON
+#if wxUSE_SPINBTN
     void OnSpinUp( wxSpinEvent &event );
     void OnSpinDown( wxSpinEvent &event );
     void OnSpinUpdate( wxSpinEvent &event );
     void OnUpdateShowProgress( wxUpdateUIEvent& event );
     void OnShowProgress( wxCommandEvent &event );
-#endif // wxUSE_SPINBUTTON
+#endif // wxUSE_SPINBTN
 
 #if wxUSE_SPINCTRL
     void OnSpinCtrl(wxSpinEvent& event);
@@ -123,10 +126,10 @@ public:
     wxButton      *m_fontButton;
     wxButton      *m_lbSelectNum;
     wxButton      *m_lbSelectThis;
-#if wxUSE_SPINBUTTON
+#if wxUSE_SPINBTN
     wxSpinButton  *m_spinbutton;
     wxButton      *m_btnProgress;
-#endif // wxUSE_SPINBUTTON
+#endif // wxUSE_SPINBTN
 
 #if wxUSE_SPINCTRL
     wxSpinCtrl    *m_spinctrl;
@@ -344,13 +347,13 @@ EVT_BUTTON    (ID_RADIOBOX_FONT,        MyPanel::OnRadioButtons)
 EVT_CHECKBOX  (ID_RADIOBOX_ENABLE,      MyPanel::OnRadioButtons)
 EVT_BUTTON    (ID_SET_FONT,             MyPanel::OnSetFont)
 EVT_SLIDER    (ID_SLIDER,               MyPanel::OnSliderUpdate)
-#if wxUSE_SPINBUTTON
+#if wxUSE_SPINBTN
 EVT_SPIN      (ID_SPIN,                 MyPanel::OnSpinUpdate)
 EVT_SPIN_UP   (ID_SPIN,                 MyPanel::OnSpinUp)
 EVT_SPIN_DOWN (ID_SPIN,                 MyPanel::OnSpinDown)
 EVT_UPDATE_UI (ID_BTNPROGRESS,          MyPanel::OnUpdateShowProgress)
 EVT_BUTTON    (ID_BTNPROGRESS,          MyPanel::OnShowProgress)
-#endif // wxUSE_SPINBUTTON
+#endif // wxUSE_SPINBTN
 #if wxUSE_SPINCTRL
 EVT_SPIN      (ID_SPINCTRL,             MyPanel::OnSpinCtrl)
 #endif // wxUSE_SPINCTRL
@@ -547,14 +550,14 @@ MyPanel::MyPanel( wxFrame *frame, int x, int y, int w, int h )
     wxString s;
     s << initialSpinValue;
     m_spintext = new wxTextCtrl( panel, -1, s, wxPoint(20,160), wxSize(80,-1) );
-#if wxUSE_SPINBUTTON
+#if wxUSE_SPINBTN
     m_spinbutton = new wxSpinButton( panel, ID_SPIN, wxPoint(103,160), wxSize(80, -1) );
     m_spinbutton->SetRange(-10,30);
     m_spinbutton->SetValue(initialSpinValue);
 
     m_btnProgress = new wxButton( panel, ID_BTNPROGRESS, "Show progress dialog",
                                   wxPoint(300, 160) );
-#endif // wxUSE_SPINBUTTON
+#endif // wxUSE_SPINBTN
 
 #if wxUSE_SPINCTRL
     m_spinctrl = new wxSpinCtrl( panel, ID_SPINCTRL, "", wxPoint(200, 160), wxSize(80, -1) );
@@ -994,7 +997,7 @@ void MyPanel::OnSpinCtrl(wxSpinEvent& event)
 
 #endif // wxUSE_SPINCTRL
 
-#if wxUSE_SPINBUTTON
+#if wxUSE_SPINBTN
 void MyPanel::OnSpinUp( wxSpinEvent &event )
 {
     wxString value;
@@ -1087,7 +1090,7 @@ void MyPanel::OnShowProgress( wxCommandEvent& WXUNUSED(event) )
     }
 }
 
-#endif // wxUSE_SPINBUTTON
+#endif // wxUSE_SPINBTN
 
 MyPanel::~MyPanel()
 {
diff --git a/samples/font/font.def b/samples/font/font.def
new file mode 100644
index 0000000000..b57616de9e
--- /dev/null
+++ b/samples/font/font.def
@@ -0,0 +1,7 @@
+NAME         Font
+DESCRIPTION  'wxWindows font sample'
+EXETYPE      WINDOWS
+CODE         PRELOAD MOVEABLE DISCARDABLE
+DATA         PRELOAD MOVEABLE MULTIPLE
+HEAPSIZE     4048
+STACKSIZE    16000
diff --git a/samples/font/makefile.b32 b/samples/font/makefile.b32
new file mode 100644
index 0000000000..edad2ef162
--- /dev/null
+++ b/samples/font/makefile.b32
@@ -0,0 +1,16 @@
+#
+# File:		makefile.b32
+# Author:	Julian Smart
+# Created:	1999
+# Updated:	
+# Copyright:
+#
+# Makefile : Builds sample for 32-bit BC++
+
+WXDIR = $(WXWIN)
+
+TARGET=font
+OBJECTS = $(TARGET).obj
+
+!include $(WXDIR)\src\makeprog.b32
+
diff --git a/samples/font/makefile.bcc b/samples/font/makefile.bcc
new file mode 100644
index 0000000000..3b2b7a8f04
--- /dev/null
+++ b/samples/font/makefile.bcc
@@ -0,0 +1,19 @@
+#
+# File:		makefile.bcc
+# Author:	Julian Smart
+# Created:	1998
+# Updated:	
+#
+# Builds a BC++ 16-bit sample
+
+!if "$(WXWIN)" == ""
+!error You must define the WXWIN variable in autoexec.bat, e.g. WXWIN=c:\wx
+!endif
+
+WXDIR = $(WXWIN)
+
+TARGET=font
+OBJECTS=$(TARGET).obj
+
+!include $(WXDIR)\src\makeprog.bcc
+
diff --git a/samples/font/makefile.g95 b/samples/font/makefile.g95
new file mode 100644
index 0000000000..1483aaa476
--- /dev/null
+++ b/samples/font/makefile.g95
@@ -0,0 +1,16 @@
+#
+# File:         makefile.g95
+# Author:       Julian Smart
+# Created:      1999
+# Updated:
+# Copyright:    (c) Julian Smart, 1999
+#
+# Makefile for wxWindows sample (Cygwin/Mingw32).
+
+WXDIR = ../..
+
+TARGET=font
+OBJECTS = $(TARGET).o
+
+include $(WXDIR)\src\makeprog.g95
+
diff --git a/samples/font/makefile.wat b/samples/font/makefile.wat
new file mode 100644
index 0000000000..2668b9dc7f
--- /dev/null
+++ b/samples/font/makefile.wat
@@ -0,0 +1,15 @@
+#
+# Makefile for WATCOM
+#
+# Created by Julian Smart, January 1999
+# 
+#
+
+WXDIR = $(%WXWIN)
+
+PROGRAM = font
+OBJECTS = $(PROGRAM).obj
+
+!include $(WXDIR)\src\makeprog.wat
+
+
diff --git a/samples/menu/makefile.b32 b/samples/menu/makefile.b32
new file mode 100644
index 0000000000..999a6c02a8
--- /dev/null
+++ b/samples/menu/makefile.b32
@@ -0,0 +1,16 @@
+#
+# File:		makefile.b32
+# Author:	Julian Smart
+# Created:	1999
+# Updated:	
+# Copyright:
+#
+# Makefile : Builds sample for 32-bit BC++
+
+WXDIR = $(WXWIN)
+
+TARGET=menu
+OBJECTS = $(TARGET).obj
+
+!include $(WXDIR)\src\makeprog.b32
+
diff --git a/samples/menu/makefile.bcc b/samples/menu/makefile.bcc
new file mode 100644
index 0000000000..d70cde7e26
--- /dev/null
+++ b/samples/menu/makefile.bcc
@@ -0,0 +1,19 @@
+#
+# File:		makefile.bcc
+# Author:	Julian Smart
+# Created:	1998
+# Updated:	
+#
+# Builds a BC++ 16-bit sample
+
+!if "$(WXWIN)" == ""
+!error You must define the WXWIN variable in autoexec.bat, e.g. WXWIN=c:\wx
+!endif
+
+WXDIR = $(WXWIN)
+
+TARGET=menu
+OBJECTS=$(TARGET).obj
+
+!include $(WXDIR)\src\makeprog.bcc
+
diff --git a/samples/menu/makefile.g95 b/samples/menu/makefile.g95
new file mode 100644
index 0000000000..554be77f07
--- /dev/null
+++ b/samples/menu/makefile.g95
@@ -0,0 +1,16 @@
+#
+# File:         makefile.g95
+# Author:       Julian Smart
+# Created:      1999
+# Updated:
+# Copyright:    (c) Julian Smart, 1999
+#
+# Makefile for wxWindows sample (Cygwin/Mingw32).
+
+WXDIR = ../..
+
+TARGET=menu
+OBJECTS = $(TARGET).o
+
+include $(WXDIR)\src\makeprog.g95
+
diff --git a/samples/menu/makefile.vc b/samples/menu/makefile.vc
new file mode 100644
index 0000000000..89422c28f4
--- /dev/null
+++ b/samples/menu/makefile.vc
@@ -0,0 +1,18 @@
+#
+# File:		makefile.vc
+# Author:	Julian Smart
+# Created:	1999
+# Updated:	
+# Copyright:	(c) Julian Smart
+#
+# Makefile : Builds sample (VC++, WIN32)
+# Use FINAL=1 argument to nmake to build final version with no debug info.
+
+# Set WXDIR for your system
+WXDIR = $(WXWIN)
+
+PROGRAM=menu
+OBJECTS = $(PROGRAM).obj
+
+!include $(WXDIR)\src\makeprog.vc
+
diff --git a/samples/menu/makefile.wat b/samples/menu/makefile.wat
new file mode 100644
index 0000000000..f8a70f9ad5
--- /dev/null
+++ b/samples/menu/makefile.wat
@@ -0,0 +1,15 @@
+#
+# Makefile for WATCOM
+#
+# Created by Julian Smart, January 1999
+# 
+#
+
+WXDIR = $(%WXWIN)
+
+PROGRAM = menu
+OBJECTS = $(PROGRAM).obj
+
+!include $(WXDIR)\src\makeprog.wat
+
+
diff --git a/samples/menu/menu.def b/samples/menu/menu.def
new file mode 100644
index 0000000000..7d1641858d
--- /dev/null
+++ b/samples/menu/menu.def
@@ -0,0 +1,7 @@
+NAME         Menu
+DESCRIPTION  'Menu wxWindows sample'
+EXETYPE      WINDOWS
+CODE         PRELOAD MOVEABLE DISCARDABLE
+DATA         PRELOAD MOVEABLE MULTIPLE
+HEAPSIZE     4048
+STACKSIZE    16000
diff --git a/samples/menu/menu.rc b/samples/menu/menu.rc
new file mode 100644
index 0000000000..b86c4e2265
--- /dev/null
+++ b/samples/menu/menu.rc
@@ -0,0 +1 @@
+#include "wx/msw/wx.rc"
diff --git a/samples/minimal/makefile.vc b/samples/minimal/makefile.vc
index ae49d75668..35aefc474c 100644
--- a/samples/minimal/makefile.vc
+++ b/samples/minimal/makefile.vc
@@ -9,7 +9,7 @@
 # Use FINAL=1 argument to nmake to build final version with no debug info.
 
 # Set WXDIR for your system
-WXDIR = j:\dev\wx2\wxWindows
+WXDIR = $(WXWIN)
 
 PROGRAM=minimal
 OBJECTS = $(PROGRAM).obj
diff --git a/src/makemsc.env b/src/makemsc.env
index 07a591e0cd..70d41d4cf5 100644
--- a/src/makemsc.env
+++ b/src/makemsc.env
@@ -20,7 +20,7 @@
 WXDIR = $(WXWIN)
 WXINC = $(WXDIR)\include
 
-WXLIB=$(WXDIR)\lib\wx1.lib $(WXDIR)\lib\wx2.lib $(WXDIR)\lib\wx3.lib $(WXDIR)\lib\wx4.lib
+WXLIB=$(WXDIR)\lib\wx1.lib $(WXDIR)\lib\wx2.lib $(WXDIR)\lib\wx3.lib $(WXDIR)\lib\wx4.lib $(WXDIR)\lib\wx5.lib
 
 # Suffixes
 OBJSUFF=obj
diff --git a/src/msw/fontutil.cpp b/src/msw/fontutil.cpp
index 10e1d82f7e..87acd82949 100644
--- a/src/msw/fontutil.cpp
+++ b/src/msw/fontutil.cpp
@@ -397,6 +397,7 @@ wxFont wxCreateFontFromLogFont(const LOGFONT *logFont)
             fontEncoding = wxFONTENCODING_CP1252;
             break;
 
+#ifdef __WIN32__
         case EASTEUROPE_CHARSET:
             fontEncoding = wxFONTENCODING_CP1250;
             break;
@@ -424,6 +425,7 @@ wxFont wxCreateFontFromLogFont(const LOGFONT *logFont)
         case TURKISH_CHARSET:
             fontEncoding = wxFONTENCODING_CP1254;
             break;
+#endif
 
         case OEM_CHARSET:
             fontEncoding = wxFONTENCODING_CP437;
diff --git a/src/msw/makefile.dos b/src/msw/makefile.dos
index f99d610e1c..8ea80f61d2 100644
--- a/src/msw/makefile.dos
+++ b/src/msw/makefile.dos
@@ -1,4 +1,4 @@
-# This file was automatically generated by tmake at 00:24, 1999/10/28
+# This file was automatically generated by tmake at 11:56, 1999/11/06
 # DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE DOS.T!
 
 #
@@ -83,7 +83,8 @@ GENERICOBJS= $(GENDIR)\busyinfo.obj \
 		$(GENDIR)\treectrl.obj \
 		$(GENDIR)\wizard.obj
 
-COMMONOBJS = \
+# we can't have all objects in one list because the library becomes too big
+COMMONOBJS1 = \
 		$(COMMDIR)\y_tab.obj \
 		$(COMMDIR)\appcmn.obj \
 		$(COMMDIR)\choiccmn.obj \
@@ -111,6 +112,7 @@ COMMONOBJS = \
 		$(COMMDIR)\filefn.obj \
 		$(COMMDIR)\filesys.obj \
 		$(COMMDIR)\fontcmn.obj \
+		$(COMMDIR)\fontmap.obj \
 		$(COMMDIR)\framecmn.obj \
 		$(COMMDIR)\fs_inet.obj \
 		$(COMMDIR)\fs_zip.obj \
@@ -134,7 +136,9 @@ COMMONOBJS = \
 		$(COMMDIR)\mstream.obj \
 		$(COMMDIR)\object.obj \
 		$(COMMDIR)\objstrm.obj \
-		$(COMMDIR)\odbc.obj \
+		$(COMMDIR)\odbc.obj
+
+COMMONOBJS2 = \
 		$(COMMDIR)\paper.obj \
 		$(COMMDIR)\prntbase.obj \
 		$(COMMDIR)\resource.obj \
@@ -196,6 +200,7 @@ MSWOBJS1 = $(MSWDIR)\accel.obj \
 		$(MSWDIR)\filedlg.obj \
 		$(MSWDIR)\font.obj \
 		$(MSWDIR)\fontdlg.obj \
+		$(MSWDIR)\fontutil.obj \
 		$(MSWDIR)\frame.obj \
 		$(MSWDIR)\gaugemsw.obj \
 		$(MSWDIR)\gdiobj.obj \
@@ -246,46 +251,56 @@ MSWOBJS2 = $(MSWDIR)\palette.obj \
 #  $(OLEDIR)\xpmhand \
 #  $(OLEDIR)\pnghand \
 
-OBJECTS = $(COMMONOBJS) $(GENERICOBJS) $(MSWOBJS1) $(MSWOBJS2)
+OBJECTS = $(COMMONOBJS1) $(COMMONOBJS2) $(GENERICOBJS) $(MSWOBJS1) $(MSWOBJS2)
 
 # Normal, static library
-all:    $(DUMMYOBJ) $(WXDIR)\lib\wx1.lib $(WXDIR)\lib\wx2.lib $(WXDIR)\lib\wx3.lib $(WXDIR)\lib\wx4.lib
+all:    $(DUMMYOBJ) $(WXDIR)\lib\wx1.lib $(WXDIR)\lib\wx2.lib $(WXDIR)\lib\wx3.lib $(WXDIR)\lib\wx4.lib $(WXDIR)\lib\wx5.lib
 
-$(WXDIR)\lib\wx1.lib:      $(COMMONOBJS) $(PERIPH_LIBS)
+$(WXDIR)\lib\wx1.lib:      $(COMMONOBJS1) $(PERIPH_LIBS)
 	-erase $(WXDIR)\lib\wx1.lib
 	lib /PAGESIZE:128 @<<
 $(WXDIR)\lib\wx1.lib
 y
-$(COMMONOBJS) $(PERIPH_LIBS)
+$(COMMONOBJS1) $(PERIPH_LIBS)
 nul
 ;
 <<
 
-$(WXDIR)\lib\wx2.lib:      $(GENERICOBJS)
+$(WXDIR)\lib\wx2.lib:      $(COMMONOBJS2)
 	-erase $(WXDIR)\lib\wx2.lib
 	lib /PAGESIZE:128 @<<
 $(WXDIR)\lib\wx2.lib
 y
-$(GENERICOBJS)
+$(COMMONOBJS2)
 nul
 ;
 <<
 
-$(WXDIR)\lib\wx3.lib:      $(MSWOBJS1)
+$(WXDIR)\lib\wx3.lib:      $(GENERICOBJS)
 	-erase $(WXDIR)\lib\wx3.lib
 	lib /PAGESIZE:128 @<<
 $(WXDIR)\lib\wx3.lib
 y
-$(MSWOBJS1)
+$(GENERICOBJS)
 nul
 ;
 <<
 
-$(WXDIR)\lib\wx4.lib:      $(MSWOBJS2)
+$(WXDIR)\lib\wx4.lib:      $(MSWOBJS1)
 	-erase $(WXDIR)\lib\wx4.lib
 	lib /PAGESIZE:128 @<<
 $(WXDIR)\lib\wx4.lib
 y
+$(MSWOBJS1)
+nul
+;
+<<
+
+$(WXDIR)\lib\wx5.lib:      $(MSWOBJS2)
+	-erase $(WXDIR)\lib\wx5.lib
+	lib /PAGESIZE:128 @<<
+$(WXDIR)\lib\wx5.lib
+y
 $(MSWOBJS2)
 nul
 ;
@@ -462,6 +477,11 @@ $(MSWDIR)/fontdlg.obj:     $*.$(SRCSUFF)
 $(CPPFLAGS) /Fo$@ /c /Tp $*.$(SRCSUFF)
 <<
 
+$(MSWDIR)/fontutil.obj:     $*.$(SRCSUFF)
+        cl @<<
+$(CPPFLAGS) /Fo$@ /c /Tp $*.$(SRCSUFF)
+<<
+
 $(MSWDIR)/frame.obj:     $*.$(SRCSUFF)
         cl @<<
 $(CPPFLAGS) /Fo$@ /c /Tp $*.$(SRCSUFF)
@@ -812,6 +832,11 @@ $(COMMDIR)/fontcmn.obj:     $*.$(SRCSUFF)
 $(CPPFLAGS) /Fo$@ /c /Tp $*.$(SRCSUFF)
 <<
 
+$(COMMDIR)/fontmap.obj:     $*.$(SRCSUFF)
+        cl @<<
+$(CPPFLAGS) /Fo$@ /c /Tp $*.$(SRCSUFF)
+<<
+
 $(COMMDIR)/framecmn.obj:     $*.$(SRCSUFF)
         cl @<<
 $(CPPFLAGS) /Fo$@ /c /Tp $*.$(SRCSUFF)
diff --git a/src/msw/menu.cpp b/src/msw/menu.cpp
index 8181a46864..f14522a13b 100644
--- a/src/msw/menu.cpp
+++ b/src/msw/menu.cpp
@@ -439,7 +439,7 @@ bool wxMenu::ProcessCommand(wxCommandEvent & event)
         (void)(*(m_callback))(*this, event);
         processed = TRUE;
     }
-#endif WXWIN_COMPATIBILITY
+#endif // WXWIN_COMPATIBILITY
 
     // Try the menu's event handler
     if ( !processed && GetEventHandler())
diff --git a/src/msw/spinbutt.cpp b/src/msw/spinbutt.cpp
index 51a32f9814..b443d1b062 100644
--- a/src/msw/spinbutt.cpp
+++ b/src/msw/spinbutt.cpp
@@ -35,6 +35,8 @@
 // Can't resolve reference to CreateUpDownControl in
 // TWIN32, but could probably use normal CreateWindow instead.
 
+#if wxUSE_SPINBTN
+
 #if defined(__WIN95__) && !defined(__TWIN32__)
 
 #include "wx/spinbutt.h"
@@ -240,3 +242,7 @@ bool wxSpinButton::MSWCommand(WXUINT cmd, WXWORD id)
 }
 
 #endif // __WIN95__
+
+#endif
+    // wxUSE_SPINCTN
+
diff --git a/src/msw/spinctrl.cpp b/src/msw/spinctrl.cpp
index 1e5ed52266..d37468bbf0 100644
--- a/src/msw/spinctrl.cpp
+++ b/src/msw/spinctrl.cpp
@@ -33,6 +33,8 @@
     #include "wx/wx.h"
 #endif
 
+#if wxUSE_SPINCTRL
+
 #if defined(__WIN95__)
 
 #include "wx/spinctrl.h"
@@ -245,3 +247,7 @@ void wxSpinCtrl::DoMoveWindow(int x, int y, int width, int height)
 }
 
 #endif // __WIN95__
+
+#endif
+       // wxUSE_SPINCTRL
+
-- 
2.50.0

