[Date Prev][Date Next][Thread Prev][Thread Next][Thread Index]

Re: [XaraXtreme-dev] Patch for spelling and white space consistency

Hi Ben,

I have checked in your suggested patches and I noticed that there were some other "non-standard" spacing in that code block so I changed them too. By "non-standard" I mean not adhering to our recommended standard, namely:
   TCHAR* variable;      // Correct
   TCHAR *variable;      // Incorrect

The logic for this one is that the variable you are declaring is a pointer to a TCHAR (it will be the size of a pointer) and so it makes more sense for the code to express that.

Unfortunately, you will find many, many places in the code that don't adhere to this standard.


Ben Fowler wrote:

Index: wxOil/basestr.h
--- wxOil/basestr.h     (revision 731)
+++ wxOil/basestr.h     (working copy)
@@ -302,10 +307,10 @@

// This is our very own version of the Windows string function
lstrcpyn(), which
// was mysteriously dropped from the Win32 API.  Using the standard C
library function
-// strncpy() doesn't give quit the same results, so we must provide our own.
+// strncpy() doesn't give quite the same results, so we must provide our own.
TCHAR* cc_lstrcpyn(TCHAR* dest, const TCHAR* src, size_t n);
-const TCHAR *cc_lstrstr(const TCHAR *String1, const TCHAR *String2);
+const TCHAR* cc_lstrstr(const TCHAR *String1, const TCHAR *String2);
TCHAR* cc_lstristr(TCHAR *String1, TCHAR *String2);
TCHAR* cc_lstrchr(TCHAR *Src, TCHAR c);
TCHAR* cc_lstrichr(TCHAR *String1, TCHAR c);
TCHAR* cc_lstrrchr(TCHAR *Src, TCHAR c);