1 Index: common/config.cpp
2 ===================================================================
3 RCS file: /sources/aspell/aspell/common/config.cpp,v
4 retrieving revision 1.72.2.1
5 diff -u -B -b -r1.72.2.1 config.cpp
6 --- common/config.cpp 22 Jun 2005 05:32:29 -0000 1.72.2.1
7 +++ common/config.cpp 18 Sep 2006 17:42:40 -0000
18 +#include "string.hpp"
23 + String ReadRegString(HKEY hive, String key, String name)
26 + // Reads a string from the Windows registry (used to get paths)
29 + unsigned long lType;
31 + unsigned char* szValue = NULL;
33 + if (::RegOpenKeyEx(hive, key.c_str(), 0, KEY_READ, &hKey) == ERROR_SUCCESS)
35 + if(::RegQueryValueEx(hKey, name.c_str(), NULL, &lType, NULL, &dwSize) == ERROR_SUCCESS)
37 + szValue = new unsigned char[dwSize + 1];
38 + ::RegQueryValueEx(hKey, name.c_str(), NULL, &lType, szValue, &dwSize);
39 + String RegistryReturn((char*)szValue);
41 + return RegistryReturn;
54 + // Check whether Aspell is installed for the current user or for all users
58 + if (ReadRegString(HKEY_LOCAL_MACHINE, "Software\\Aspell", "Dictionary Path") == "")
60 + return HKEY_CURRENT_USER;
62 + return HKEY_LOCAL_MACHINE;
70 Index: common/config.hpp
71 ===================================================================
72 RCS file: /sources/aspell/aspell/common/config.hpp,v
73 retrieving revision 1.25
74 diff -u -B -b -r1.25 config.hpp
75 --- common/config.hpp 18 Nov 2004 02:01:53 -0000 1.25
76 +++ common/config.hpp 18 Sep 2006 17:42:41 -0000
89 + extern HKEY GetRegHive();
90 + extern String ReadRegString(HKEY type, String key, String name);
98 Index: common/file_util.cpp
99 ===================================================================
100 RCS file: /sources/aspell/aspell/common/file_util.cpp,v
101 retrieving revision 1.10
102 diff -u -B -b -r1.10 file_util.cpp
103 --- common/file_util.cpp 15 Nov 2004 12:29:53 -0000 1.10
104 +++ common/file_util.cpp 18 Sep 2006 17:42:41 -0000
106 # define ACCESS _access
107 # include <windows.h>
108 # include <winbase.h>
109 +# include <dirent.h>
110 +# include <asc_ctype.hpp>
114 Index: common/gettext_init.cpp
115 ===================================================================
116 RCS file: /sources/aspell/aspell/common/gettext_init.cpp,v
117 retrieving revision 1.4
118 diff -u -B -b -r1.4 gettext_init.cpp
119 --- common/gettext_init.cpp 9 Nov 2004 08:20:24 -0000 1.4
120 +++ common/gettext_init.cpp 18 Sep 2006 17:42:41 -0000
122 if (did_init) return;
126 + // Registry key for Locale Path
128 + aspell::String value;
131 + hive = acommon::GetRegHive();
132 + value = acommon::ReadRegString(hive, "Software\\Aspell", "Locale Path");
133 + if (value == "") value = LOCALEDIR;
135 + bindtextdomain("aspell", value.c_str());
137 bindtextdomain("aspell", LOCALEDIR);
142 Index: common/info.cpp
143 ===================================================================
144 RCS file: /sources/aspell/aspell/common/info.cpp,v
145 retrieving revision 1.34
146 diff -u -B -b -r1.34 info.cpp
147 --- common/info.cpp 10 Nov 2004 06:18:45 -0000 1.34
148 +++ common/info.cpp 18 Sep 2006 17:42:42 -0000
153 - lst.add(config->retrieve("data-dir"));
157 + HKEY hive = acommon::GetRegHive();
158 + // Registry key for dictionary path
159 + dictpath =acommon::ReadRegString(hive, "Software\\Aspell", "Dictionary Path");;
160 + if (dictpath == "") dictpath = config->retrieve("data-dir");
162 + dictpath = config->retrieve("data-dir");
165 lst.add(config->retrieve("dict-dir"));
168 Index: common/objstack.cpp
169 ===================================================================
170 RCS file: /sources/aspell/aspell/common/objstack.cpp,v
171 retrieving revision 1.5
172 diff -u -B -b -r1.5 objstack.cpp
173 --- common/objstack.cpp 29 Jun 2004 00:18:16 -0000 1.5
174 +++ common/objstack.cpp 18 Sep 2006 17:42:42 -0000
177 #include "objstack.hpp"
183 Index: common/posib_err.cpp
184 ===================================================================
185 RCS file: /sources/aspell/aspell/common/posib_err.cpp,v
186 retrieving revision 1.16
187 diff -u -B -b -r1.16 posib_err.cpp
188 --- common/posib_err.cpp 21 Nov 2004 02:52:22 -0000 1.16
189 +++ common/posib_err.cpp 18 Sep 2006 17:42:42 -0000
191 // license along with this library if you did not you can find
192 // it at http://www.gnu.org/.
194 +#include <settings.h>
198 Index: common/vector.hpp
199 ===================================================================
200 RCS file: /sources/aspell/aspell/common/vector.hpp,v
201 retrieving revision 1.12
202 diff -u -B -b -r1.12 vector.hpp
203 --- common/vector.hpp 21 Jun 2004 02:40:07 -0000 1.12
204 +++ common/vector.hpp 18 Sep 2006 17:42:42 -0000
207 T * data() {return &*this->begin();}
208 T * data(int pos) {return &*this->begin() + pos;}
209 - T * data_end() {return &*this->end();}
210 + T * data_end() {return &this->back()+1;}
212 T * pbegin() {return &*this->begin();}
213 - T * pend() {return &*this->end();}
214 + T * pend() {return &this->back()+1;}
216 const T * pbegin() const {return &*this->begin();}
217 - const T * pend() const {return &*this->end();}
218 + const T * pend() const {return &this->back()+1;}
220 template <typename U>
222 Index: modules/speller/default/affix.hpp
223 ===================================================================
224 RCS file: /sources/aspell/aspell/modules/speller/default/affix.hpp,v
225 retrieving revision 1.19
226 diff -u -B -b -r1.19 affix.hpp
227 --- modules/speller/default/affix.hpp 29 Nov 2004 17:50:06 -0000 1.19
228 +++ modules/speller/default/affix.hpp 18 Sep 2006 17:42:42 -0000
231 WordAff * expand_suffix(ParmString word, const unsigned char * new_aff,
232 ObjStack &, int limit = INT_MAX,
233 - unsigned char * new_aff = 0, WordAff * * * l = 0,
234 + unsigned char * new_aff2 = 0, WordAff * * * l = 0,
235 ParmString orig_word = 0) const;
238 Index: win32/settings.h
239 ===================================================================
240 RCS file: /sources/aspell/aspell/win32/settings.h,v
241 retrieving revision 1.2
242 diff -u -B -b -r1.2 settings.h
243 --- win32/settings.h 3 Jan 2004 12:06:25 -0000 1.2
244 +++ win32/settings.h 18 Sep 2006 17:42:43 -0000
246 -/* common/settings.h. Generated by configure. */
247 /* common/settings.h.in. Generated from configure.ac by autoheader. */
249 /* Defined if no special Workarounds are needed for Curses headers */
250 -/* #undef CURSES_INCLUDE_STANDARD */
251 +#undef CURSES_INCLUDE_STANDARD
253 /* Defined if special Wordaround I is need for Curses headers */
254 -/* #undef CURSES_INCLUDE_WORKAROUND_1 */
255 +#undef CURSES_INCLUDE_WORKAROUND_1
257 /* Defined if curses like POSIX Functions should be used */
258 -/* #undef CURSES_ONLY */
261 /* Defined if win32 relocation should be used */
262 -/* #undef ENABLE_WIN32_RELOCATABLE */
263 +#define ENABLE_WIN32_RELOCATABLE 1
265 /* Define to 1 if you have the <dlfcn.h> header file. */
266 -/* #undef HAVE_DLFCN_H */
269 /* Defined if msdos getch is supported */
270 -/* #undef HAVE_GETCH */
273 /* Define to 1 if you have the <inttypes.h> header file. */
274 -#define HAVE_INTTYPES_H 1
275 +#undef HAVE_INTTYPES_H
277 /* Defined if the curses library is available */
278 -/* #undef HAVE_LIBCURSES */
279 +#undef HAVE_LIBCURSES
281 /* Define to 1 if you have the <memory.h> header file. */
282 #define HAVE_MEMORY_H 1
284 /* Defined if mmap and friends is supported */
285 -/* #undef HAVE_MMAP */
288 /* Define to 1 if you have the <stdint.h> header file. */
289 -#define HAVE_STDINT_H 1
290 +#undef HAVE_STDINT_H
292 /* Define to 1 if you have the <stdlib.h> header file. */
293 #define HAVE_STDLIB_H 1
295 /* Define to 1 if you have the <strings.h> header file. */
296 -#define HAVE_STRINGS_H 1
297 +#undef HAVE_STRINGS_H
299 /* Define to 1 if you have the <string.h> header file. */
300 #define HAVE_STRING_H 1
302 #define HAVE_SYS_TYPES_H 1
304 /* Define to 1 if you have the <unistd.h> header file. */
305 -#define HAVE_UNISTD_H 1
306 +#undef HAVE_UNISTD_H
308 /* Name of package */
309 -#define PACKAGE "aspell"
312 /* Define to the address where bug reports for this package should be sent. */
313 -#define PACKAGE_BUGREPORT ""
314 +#undef PACKAGE_BUGREPORT
316 /* Define to the full name of this package. */
317 -#define PACKAGE_NAME ""
320 /* Define to the full name and version of this package. */
321 -#define PACKAGE_STRING ""
322 +#undef PACKAGE_STRING
324 /* Define to the one symbol short name of this package. */
325 -#define PACKAGE_TARNAME ""
326 +#undef PACKAGE_TARNAME
328 /* Define to the version of this package. */
329 -#define PACKAGE_VERSION ""
330 +#undef PACKAGE_VERSION
332 /* Defined if Posix Termios is Supported */
333 -/* #undef POSIX_TERMIOS */
334 +#undef POSIX_TERMIOS
336 /* Defined if STL rel_ops polute the global namespace */
337 -/* #undef REL_OPS_POLLUTION */
338 +#undef REL_OPS_POLLUTION
340 /* Define to 1 if you have the ANSI C header files. */
341 -#define STDC_HEADERS 1
344 /* Defined if file ino is supported */
345 -/* #undef USE_FILE_INO */
348 /* Defined if file locking and truncating is supported */
349 -/* #undef USE_FILE_LOCKS */
350 +#undef USE_FILE_LOCKS
352 /* Defined if Posix locales are supported */
353 -/* #undef USE_LOCALE */
356 /* Version number of package */
357 -#define VERSION "0.50.3"
358 +#define VERSION "0.50.4.1"
360 +#define PACKAGE_VERSION "aspell-6.0"
362 +#define C_EXPORT extern "C"
364 +#if defined(ASPELL_NO_EXPORTS)
366 +#elif defined(_WINDLL) || defined(_USRDLL) || defined(__DLL__)
367 +# define ASPELL_API __declspec(dllexport)
369 +# define ASPELL_API __declspec(dllimport)
372 +// Microsoft VC6.0 does not allow typename except when directly
373 +// declaring a template param. The other supporte compilers (Borlands
374 +// BCB5.5 and GNU C++) require or allow it anywhere in the template
375 +// decl. The macro TYPENAME is defines to whatever works.
376 +#if defined(_MSC_VER) && (_MSC_VER<1300)
379 +#define TYPENAME typename
382 +// Microsoft Visual C 6.0 stdio.h does not declare snprintf, rather
383 +// it declares _snprintf. We define snprintf for VC builds here.
384 +// snprintf is not standard, but it is common.
386 +#define snprintf _snprintf
387 +#define vsnprintf _vsnprintf