]> git.saurik.com Git - wxWidgets.git/blobdiff - samples/stc/edit.h
Large image-loading speedup and small attribute-loading speedup
[wxWidgets.git] / samples / stc / edit.h
index 0a4cbf4aba4c4debca7fb710d376c47149013011..780076d77a42c8e1ff9b6486d48f544c14aa6aa6 100644 (file)
 // headers
 //----------------------------------------------------------------------------
 
-//! wxWindows headers
+//! wxWidgets headers
 
-//! wxWindows/contrib headers
-#include <wx/stc/stc.h>  // styled text control
+//! wxWidgets/contrib headers
+#include "wx/stc/stc.h"  // styled text control
 
 //! application headers
 #include "prefs.h"       // preferences
@@ -45,10 +45,14 @@ class Edit: public wxStyledTextCtrl {
 
 public:
     //! constructor
-    Edit (wxWindow *parent, wxWindowID id = -1,
+    Edit (wxWindow *parent, wxWindowID id = wxID_ANY,
           const wxPoint &pos = wxDefaultPosition,
           const wxSize &size = wxDefaultSize,
-          long style = wxSUNKEN_BORDER|wxVSCROLL
+          long style = 
+#ifndef __WXMAC__
+          wxSUNKEN_BORDER|
+#endif
+          wxVSCROLL
          );
 
     //! destructor
@@ -93,6 +97,7 @@ public:
     // stc
     void OnMarginClick (wxStyledTextEvent &event);
     void OnCharAdded  (wxStyledTextEvent &event);
+    void OnKey  (wxStyledTextEvent &event);
 
     //! language/lexer
     wxString DeterminePrefs (const wxString &filename);
@@ -139,6 +144,8 @@ private:
 
 };
 
+#if wxUSE_PRINTING_ARCHITECTURE
+
 //----------------------------------------------------------------------------
 //! EditPrint
 class EditPrint: public wxPrintout {
@@ -146,7 +153,7 @@ class EditPrint: public wxPrintout {
 public:
 
     //! constructor
-    EditPrint (Edit *edit, wxChar *title = _T(""));
+    EditPrint (Edit *edit, const wxChar *title = wxT(""));
 
     //! event handlers
     bool OnPrintPage (int page);
@@ -165,5 +172,6 @@ private:
     bool PrintScaling (wxDC *dc);
 };
 
-#endif // _EDIT_H_
+#endif // wxUSE_PRINTING_ARCHITECTURE
 
+#endif // _EDIT_H_