Update of /cvsroot/anyedit/AnyEditv2
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv17835
Modified Files:
ConfigFile.cpp ConfigFile.h
Log Message:
- Added smart insert; ( becomes ()
- Added default date format
- Added smart tab
Index: ConfigFile.h
===================================================================
RCS file: /cvsroot/anyedit/AnyEditv2/ConfigFile.h,v
retrieving revision 1.23
retrieving revision 1.24
diff -C2 -d -r1.23 -r1.24
*** ConfigFile.h 12 Oct 2005 18:55:57 -0000 1.23
--- ConfigFile.h 16 Oct 2005 12:04:32 -0000 1.24
***************
*** 49,52 ****
--- 49,53 ----
#define TAG_CLASSVIEW "ClassView"
#define TAG_INSERTTEXT "InsertText"
+ #define TAG_DATE_TIME_FORMAT "DateTimeFormat"
// General tags
***************
*** 87,90 ****
--- 88,93 ----
#define TAG_EDITOR_RIGHTEDGECOLUMN "RightEdgeColumn"
#define TAG_EDITOR_RIGHTEDGECOLOR "RightEdgeColor"
+ #define TAG_EDITOR_SMARTINSERT "SmartInsert"
+ #define TAG_EDITOR_SMARTTAB "SmartTab"
// Editor attributes
***************
*** 132,135 ****
--- 135,141 ----
#define TAG_INSERTTEXT_WORD "Word"
+ // Date/Time Default
+ #define TAG_DATE_TIME_DEFAULT "Default"
+
/** \class CConfigFile
* \brief A class with the interface to the AnyEdit config file in XML, derived from CXMLFile
***************
*** 146,149 ****
--- 152,159 ----
public:
+ bool SetSmartTab(bool bSmartTab);
+ bool GetSmartTab(void);
+ CString GetDefaultDateFormat(void);
+ bool SetDefaultDateFormat(CString szFormat);
DECLARE_DYNAMIC(CConfigFile)
***************
*** 498,501 ****
--- 508,517 ----
/// Remove all insert text words.
bool RemoveInsertTextWords();
+
+ /// Get smart insert of ([{"'
+ bool GetSmartInsert(void);
+
+ /// Set smart insert of ([{"'
+ bool SetSmartInsert(bool bSmartInsert);
};
Index: ConfigFile.cpp
===================================================================
RCS file: /cvsroot/anyedit/AnyEditv2/ConfigFile.cpp,v
retrieving revision 1.24
retrieving revision 1.25
diff -C2 -d -r1.24 -r1.25
*** ConfigFile.cpp 12 Oct 2005 18:55:57 -0000 1.24
--- ConfigFile.cpp 16 Oct 2005 12:04:32 -0000 1.25
***************
*** 1179,1180 ****
--- 1179,1210 ----
return m_bModified = true;
}
+
+ bool CConfigFile::GetSmartInsert()
+ {
+ return GetBoolFromXMLFile( TAG_EDITOR, TAG_EDITOR_SMARTINSERT );
+ }
+
+ bool CConfigFile::SetSmartInsert(bool bSmartInsert)
+ {
+ return SetBoolToXMLFile( TAG_EDITOR, TAG_EDITOR_SMARTINSERT, bSmartInsert );
+ }
+
+ bool CConfigFile::SetDefaultDateFormat(CString szFormat)
+ {
+ return SetStringToXMLFile( TAG_DATE_TIME_FORMAT, TAG_DATE_TIME_DEFAULT, szFormat, true );
+ }
+
+ CString CConfigFile::GetDefaultDateFormat()
+ {
+ return GetStringFromXMLFile( TAG_DATE_TIME_FORMAT, TAG_DATE_TIME_DEFAULT );
+ }
+
+ bool CConfigFile::GetSmartTab()
+ {
+ return GetBoolFromXMLFile( TAG_EDITOR, TAG_EDITOR_SMARTTAB );
+ }
+
+ bool CConfigFile::SetSmartTab(bool bSmartTab)
+ {
+ return SetBoolToXMLFile( TAG_EDITOR, TAG_EDITOR_SMARTTAB, bSmartTab );
+ }
|