- Edit src/make.env to change options according to your local
environment. In particular, change WXDIR to where wxWindows is
- found on your system.
+ found on your system, or set the WXWIN environment variable
+ before compilation, e.g.:
+
+ export WXWIN=/home/jacs/wx2
+
Later, there will be a better makefile system
and/or alternate make.env files as per wxWindows 1.68.
Please feel free to contribute settings files for your environment.
__WATCOMC__ Watcom C++
__SYMANTECC__ Symantec C++
__VISUALC__ VC++
-__SUNCC__
+__SUNCC__ Sun CC
__XLC__ ?? compiler
wxWindows modes:
#endif
#endif
+#if defined(sun) || defined(__SUN__)
+# if !defined(__GNUG__)
+# ifndef __SUNCC__
+# define __SUNCC__
+# endif
+# endif
+#endif
+
// suppress some Visual C++ warnings
#ifdef _MSC_VER
# pragma warning(disable:4244) // cobversion from double to float
#define bool unsigned int
#elif defined(__BORLANDC__) && (__BORLANDC__ < 0x500)
typedef unsigned int bool;
+#elif defined(__SUNCC__)
+ // If we use int, we get identically overloaded functions in config.cpp
+ typedef unsigned char bool;
#endif
#if ( defined(_MSC_VER) && (_MSC_VER <= 800) ) || defined(__GNUWIN32__)
#undef new
#endif
+#if defined(__SUNCC__)
+#define wxUSE_ARRAY_MEMORY_OPERATORS 0
+#elif !( defined (_MSC_VER) && (_MSC_VER <= 1020) ) || defined( __MWERKS__)
+#define wxUSE_ARRAY_MEMORY_OPERATORS 1
+#else
+#define wxUSE_ARRAY_MEMORY_OPERATORS 0
+#endif
+
// Added JACS 25/11/98: needed for some compilers
void * operator new (size_t size);
-#if !( defined (_MSC_VER) && (_MSC_VER <= 1020) ) || defined( __MWERKS__)
+#if wxUSE_ARRAY_MEMORY_OPERATORS
void * operator new[] (size_t size);
#endif
void * operator new (size_t size, char * fileName, int lineNum);
void operator delete (void * buf);
-#if !( defined (_MSC_VER) && (_MSC_VER <= 1020) ) || defined( __MWERKS__)
+#if wxUSE_ARRAY_MEMORY_OPERATORS
void * operator new[] (size_t size, char * fileName, int lineNum);
void operator delete[] (void * buf);
#endif
#endif
// Cause problems for VC++
-#ifndef _MSC_VER
+// #ifndef _MSC_VER
+#if !defined(_MSC_VER) && wxUSE_ARRAY_MEMORY_OPERATORS
void * operator new[] (size_t size, char * fileName = NULL, int lineNum = 0);
void operator delete[] (void * buf);
#endif
+/*
#ifdef __MWERKS__
void * operator new[] (size_t size, char * fileName , int lineNum = 0);
void operator delete[] (void * buf);
#endif
+*/
#endif
#else
frame = new MyFrame((wxFrame*) NULL, -1, (char *) "Notebook", wxPoint(-1, -1), wxSize(365, 390), wxDEFAULT_FRAME_STYLE);
+ // Problem with Motif whereby it doesn't size properly unless
+ // you set the size again (to a different size than before,
+ // since SetSize is optimized)
+#ifdef __WXMOTIF__
+ frame->SetSize(-1, -1, 370, 390);
+#endif
+
return TRUE;
#endif
}
(void)new wxButton(panel1, -1, "Press me", wxPoint(10, 10));
(void)new wxTextCtrl(panel1, -1, "1234", wxPoint(10, 40), wxSize(120, 150));
- notebook->AddPage(panel1, "Cat");
+ notebook->AddPage(panel1, "Cat", TRUE);
wxPanel *panel2 = new wxPanel(notebook, -1);
panel2->SetBackgroundColour(wxColour("BLUE"));
#endif
}
-#if !( defined (_MSC_VER) && (_MSC_VER <= 1020) )
+#if wxUSE_ARRAY_MEMORY_OPERATORS
void * operator new[] (size_t size)
{
#ifdef NO_DEBUG_ALLOCATION
}
#endif
-#if !( defined (_MSC_VER) && (_MSC_VER <= 1020) )
+#if wxUSE_ARRAY_MEMORY_OPERATORS
void * operator new[] (size_t size, char * fileName, int lineNum)
{
#ifdef NO_DEBUG_ALLOCATION
}
#endif
-#if !( defined (_MSC_VER) && (_MSC_VER <= 1020) )
+#if wxUSE_ARRAY_MEMORY_OPERATORS
void operator delete[] (void * buf)
{
#endif
// Cause problems for VC++ - crashes
-#ifndef _MSC_VER
+#if !defined(_MSC_VER) && wxUSE_ARRAY_MEMORY_OPERATORS
void * wxObject::operator new[] (size_t size, char * fileName, int lineNum)
{
return wxDebugAlloc(size, fileName, lineNum, TRUE, TRUE);
file = ifile;
if(! wxDirExists(file))
- return false;
+ return FALSE;
mapFile << file << WXEXTHELP_SEPARATOR << WXEXTHELP_MAPFILE;
}
mapFile = m_MapFile;
if(! wxFileExists(mapFile))
- return false;
+ return FALSE;
DeleteList();
m_MapList = new wxList;
FILE *input = fopen(mapFile.c_str(),"rt");
if(! input)
- return false;
+ return FALSE;
do
{
if(fgets(buffer,WXEXTHELP_BUFLEN,input) && *buffer != WXEXTHELP_COMMENTCHAR)
fclose(input);
m_MapFile = file; // now it's valid
- return true;
+ return TRUE;
}
bool
<< WXEXTHELP_SEPARATOR << relativeURL << ")";
success = wxExecute(command);
if(success != 0 ) // returns PID on success
- return true;
+ return TRUE;
}
}
command = m_BrowserName;
wxExtHelpController::DisplayContents(void)
{
if(! m_NumOfEntries)
- return false;
+ return FALSE;
wxBusyCursor b; // display a busy cursor
return KeywordSearch("");
}
wxExtHelpController::DisplaySection(int sectionNo)
{
if(! m_NumOfEntries)
- return false;
+ return FALSE;
wxBusyCursor b; // display a busy cursor
wxNode *node = m_MapList->First();
return CallBrowser(entry->url);
node = node->Next();
}
- return false;
+ return FALSE;
}
bool
wxExtHelpController::KeywordSearch(const wxString& k)
{
if(! m_NumOfEntries)
- return false;
+ return FALSE;
wxBusyCursor b; // display a busy cursor
wxString *choices = new wxString[m_NumOfEntries];
else if(idx == 0)
{
wxMessageBox(_("No entries found."));
- rc = false;
+ rc = FALSE;
}
else
{
if(idx != -1)
rc = CallBrowser(urls[idx]);
else
- rc = false;
+ rc = FALSE;
}
delete[] urls;
delete[] choices;
bool
wxExtHelpController::Quit(void)
{
- return true;
+ return TRUE;
}
void
########################### Programs #################################
# Replace this with your own path if necessary
-WXDIR = $(wx)
+WXDIR = $(WXWIN)
# C++ compiler
CC = g++
#pragma implementation "colordlg.h"
#endif
-#include "wx/stubs/colordlg.h"
+#include "wx/motif/colordlg.h"
#if !USE_SHARED_LIBRARY
IMPLEMENT_DYNAMIC_CLASS(wxColourDialog, wxDialog)
XEvent event;
// Loop until we signal that the dialog should be closed
- while ((wxModalShowingStack.Number() > 0) && (bool)wxModalShowingStack.First()->Data())
+ while ((wxModalShowingStack.Number() > 0) && ((int)(wxModalShowingStack.First()->Data()) != 0))
{
// XtAppProcessEvent((XtAppContext) wxTheApp->GetAppContext(), XtIMAll);
#pragma implementation "fontdlg.h"
#endif
-#include "wx/stubs/fontdlg.h"
+#include "wx/motif/fontdlg.h"
#include "wx/cmndata.h"
#if !USE_SHARED_LIBRARY
#pragma implementation "helpxxxx.h"
#endif
-#include "wx/stubs/helpxxxx.h"
+#include "wx/motif/helpxxxx.h"
#include <string.h>
#pragma implementation "imaglist.h"
#endif
-#include "wx/stubs/imaglist.h"
+#include "wx/motif/imaglist.h"
#if !USE_SHARED_LIBRARY
IMPLEMENT_DYNAMIC_CLASS(wxImageList, wxObject)
#pragma implementation "listctrl.h"
#endif
-#include "wx/stubs/textctrl.h"
-#include "wx/stubs/listctrl.h"
+#include "wx/motif/textctrl.h"
+#include "wx/motif/listctrl.h"
#if !USE_SHARED_LIBRARY
IMPLEMENT_DYNAMIC_CLASS(wxListCtrl, wxControl)
#include "wx/object.h"
#include "wx/string.h"
#include "wx/dc.h"
-#include "wx/stubs/metafile.h"
+#include "wx/motif/metafile.h"
#include "wx/clipbrd.h"
extern bool wxClipboardIsOpen;
#pragma implementation "msgdlg.h"
#endif
-#include "wx/stubs/msgdlg.h"
+#include "wx/motif/msgdlg.h"
#if !USE_SHARED_LIBRARY
IMPLEMENT_CLASS(wxMessageDialog, wxDialog)
{
static bool s_bFirstTime = TRUE;
if ( s_bFirstTime ) {
+ /*
+ wxSize sz(GetSize());
+ sz.x ++;
+ SetSize(sz);
+ sz.x --;
+ SetSize(sz);
+ */
+
+ /*
wxSize sz(GetSize());
wxSizeEvent sizeEvent(sz, GetId());
sizeEvent.SetEventObject(this);
GetEventHandler()->ProcessEvent(sizeEvent);
Refresh();
+ */
s_bFirstTime = FALSE;
}
event.Skip();
#pragma implementation "print.h"
#endif
-#include "wx/stubs/print.h"
-#include "wx/stubs/printdlg.h"
+#include "wx/motif/print.h"
+#include "wx/motif/printdlg.h"
#if !USE_SHARED_LIBRARY
IMPLEMENT_DYNAMIC_CLASS(wxPrinter, wxPrinterBase)
#endif
#include "wx/object.h"
-#include "wx/stubs/printdlg.h"
+#include "wx/motif/printdlg.h"
#include "wx/dcprint.h"
// Use generic page setup dialog: use your own native one if one exists.
// headers
// ----------------------------------------------------------------------------
-#include "wx/stubs/statusbr.h"
+#include "wx/motif/statusbr.h"
#if !USE_SHARED_LIBRARY
IMPLEMENT_DYNAMIC_CLASS(wxStatusBarXX, wxStatusBar);
#pragma implementation "treectrl.h"
#endif
-#include "wx/stubs/textctrl.h"
-#include "wx/stubs/treectrl.h"
+#include "wx/motif/textctrl.h"
+#include "wx/motif/treectrl.h"
#if !USE_SHARED_LIBRARY
IMPLEMENT_DYNAMIC_CLASS(wxTreeCtrl, wxControl)
#include <netdb.h>
#include <signal.h>
-#ifdef __SVR4__
+#if defined(__SVR4__) && !defined(__HPUX__)
#include <sys/systeminfo.h>
#endif
+#if (defined(__SUNCC__) || defined(__CLCC__))
+#include <sysent.h>
+#endif
+
#include <Xm/Xm.h>
#include "wx/motif/private.h"
// Get full hostname (eg. DoDo.BSn-Germany.crg.de)
bool wxGetHostName(char *buf, int maxSize)
{
-#if defined(SVR4) && !defined(__hpux)
+#if defined(__SVR4__) && !defined(__HPUX__)
return (sysinfo (SI_HOSTNAME, buf, maxSize) != -1);
#else /* BSD Sockets */
char name[255];
size_t len;
environment = GetIniFile (filename, NULL);
len = strlen (environment);
-#if defined(SVR4) && !defined(__hpux)
+#if defined(__SVR4__) && !defined(__HPUX__)
(void) sysinfo (SI_HOSTNAME, environment + len, 1024 - len);
#else
(void) gethostname (environment + len, 1024 - len);
#else
-#if defined(_AIX) || defined(__xlC__)
+#if defined(__AIX__) || defined(__xlC__)
#include <sys/socket.h>
#include <sys/select.h>
#else
-#ifndef DG
+#ifndef __DATA_GENERAL__
#include <sys/syscall.h>
#endif
#endif
#include "wx/object.h"
#include "wx/string.h"
-#include "wx/stubs/wave.h"
+#include "wx/motif/wave.h"
wxWave::wxWave()
: m_waveData(NULL), m_waveLength(0), m_isResource(FALSE)
variant.MakeNull();
break;
}
+ case VT_EMPTY:
+ {
+ break; // Ignore Empty Variant, used only during destruction of objects
+ }
default:
{
wxLogError("wxAutomationObject::ConvertOleToVariant: Unknown variant value type");
bool wxMetaFile::Play(wxDC *dc)
{
// TODO
- return false;
+ return FALSE;
}
/*