diff --git a/harbour/ChangeLog b/harbour/ChangeLog index cab7b0863e..339116347e 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -17,6 +17,18 @@ past entries belonging to author(s): Viktor Szakats. */ +2010-01-17 22:49 UTC+0100 Viktor Szakats (harbour.01 syenar.hu) + * contrib/hbwin/hbwin.ch + + Added HB_WINFONT_* constants for WIN_ENUMFONTS() returned + array positions. + + Now possible to disable legacy defintions by defining + HB_WIN_NO_LEGACY. This paves the way to include this file + in .c files. + + * contrib/hbwin/win_prn1.c + ! WIN_ENUMFONTS() fixed to return empty array (instead of NIL) + in error cases. + 2010-01-17 20:34 UTC+0100 Viktor Szakats (harbour.01 syenar.hu) * contrib/hbwin/win_reg.prg * contrib/hbwin/win_os.prg diff --git a/harbour/contrib/hbwin/hbwin.ch b/harbour/contrib/hbwin/hbwin.ch index 9af09b0b87..19f7a1a3ef 100644 --- a/harbour/contrib/hbwin/hbwin.ch +++ b/harbour/contrib/hbwin/hbwin.ch @@ -132,6 +132,13 @@ #define HB_WINPRN_SERVER 6 #define HB_WINPRN_LEN_ 6 +/* WIN_ENUMFONTS() positions for array returned */ +#define HB_WINFONT_NAME 1 +#define HB_WINFONT_FIXED 2 +#define HB_WINFONT_TRUETYPE 3 +#define HB_WINFONT_CHARSET 4 +#define HB_WINFONT_LEN_ 4 + #define WIN_RGB( nR, nG, nB ) ( nR + ( nG * 256 ) + ( nB * 256 * 256 ) ) /* Color constants for convenience */ @@ -277,7 +284,7 @@ /* Deprecated constants and macros */ /* ------------------------------- */ -#ifdef HB_LEGACY_LEVEL3 +#if defined( HB_LEGACY_LEVEL3 ) .AND. ! defined( HB_WIN_NO_LEGACY ) #define HKEY_CLASSES_ROOT WIN_HKEY_CLASSES_ROOT #define HKEY_CURRENT_USER WIN_HKEY_CURRENT_USER diff --git a/harbour/contrib/hbwin/win_prn1.c b/harbour/contrib/hbwin/win_prn1.c index bc2c82d94f..f538145599 100644 --- a/harbour/contrib/hbwin/win_prn1.c +++ b/harbour/contrib/hbwin/win_prn1.c @@ -640,6 +640,8 @@ HB_FUNC( WIN_ENUMFONTS ) hb_itemReturnRelease( pArray ); } + else + hb_reta( 0 ); } HB_FUNC( WIN_SETCOLOR )