00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029 #ifndef INC_MGUI_SMLEDIT_H
00030 #define INC_MGUI_SMLEDIT_H
00031
00032 #ifndef INC_MGUI_CTRL_H
00033 #include <mgui/ctrl.h>
00034 #endif
00035
00036 #ifndef INC_MI32_SML_H
00037 #include <mi32/sml.h>
00038 #endif
00039
00040 class SCRIPTVIEW;
00041
00042 namespace MGUI {
00043
00044
00045
00046 class FORM_SMLEDITOR : public MGUI::FORM {
00047 public:
00048
00049
00050 FORM_SMLEDITOR ();
00051
00052
00053 ~FORM_SMLEDITOR ();
00054
00055
00056
00057 bool CheckSyntax (
00058 bool bShowError = true
00059 );
00060
00061
00062 void Create (
00063 MGUI::LAYOUT_PANE_BASE& ParentPane,
00064 int width = 30,
00065 int height = 10,
00066 MGUI::LAYOUT_SIZEALIGN sizealign= MGUI::LAYOUT_SIZEALIGN_Expand,
00067 bool bFileIcons = true
00068 );
00069
00070
00071 const MISTRING& GetScript (
00072 );
00073
00074
00075 MGUI::LAYOUT_PANE& GetToolBarPane (
00076 );
00077
00078
00079 bool HasChanged (
00080 ) const;
00081
00082
00083
00084 virtual bool IsCreated (
00085 ) const;
00086
00087
00088
00089 virtual bool IsEnabled (
00090 ) const;
00091
00092
00093 void OpenDocumentation (
00094 );
00095
00096
00097
00098
00099
00100
00101
00102 void SetContext (
00103 SMLCONTEXT* context,
00104 int segment,
00105 UINT32 flags = 0
00106 );
00107
00108
00109 virtual void SetEnabled (
00110 bool enabled = true
00111 );
00112
00113
00114 void SetScript (
00115 const MISTRING& script
00116 );
00117
00118
00119 virtual void SetVisible (
00120 bool visible = true
00121 );
00122
00123 private:
00124 #ifndef GENERATING_DOXYGEN_OUTPUT
00125 SCRIPTVIEW* m_pView;
00126 #endif // GENERATING_DOXYGEN_OUTPUT
00127
00128 };
00129
00130 }
00131
00132
00133 #endif // INC_MGUI_SMLEDIT
00134