2009-07-12 12:21 UTC+0200 Viktor Szakats (harbour.01 syenar.hu)

* INSTALL
    + Added information about creating Windows / Windows CE
      builds on Linux. Corresponding scripts references.
    ! Minor correction to OS/2 on Windows cross-build example.

  * contrib/hbct/Makefile
  - contrib/hbct/blank.prg
  + contrib/hbct/blank.c
    + Applied patch by Pavel Tsarenko (xhb) (with some little modifications):
      BLANK() function rewritten in C.

  * contrib/rddads/adsfunc.c
    ! Reimplemented fix from Pavel Tsarenko (xhb):
      Removed unnecessary OEM to ANSI convertation in SQL functions.
This commit is contained in:
Viktor Szakats
2009-07-12 10:29:46 +00:00
parent 9bc00dd21d
commit 8f1a9dbf7d
5 changed files with 120 additions and 81 deletions

View File

@@ -17,21 +17,37 @@
past entries belonging to author(s): Viktor Szakats.
*/
2009-07-12 00:01 UTC-0800 Pritpal Bedi (pritpal@vouchcac.com)
* harbour/contrib/hbxbp/Makefile
* harbour/contrib/hbxbp/xbp.ch
* harbour/contrib/hbxbp/xbpdialog.prg
* harbour/contrib/hbxbp/xbpgeneric.prg
* harbour/contrib/hbxbp/xbpprinter.prg
+ harbour/contrib/hbxbp/xbprtf.prg
+ Implemented XbpRtf() class - the toughest so far.
Example code lifted from Xbase++ documentaion is working as is
except for one feature. Still more work is required. I see a
possibility of lot more features in this class - later.
2009-07-12 12:21 UTC+0200 Viktor Szakats (harbour.01 syenar.hu)
* INSTALL
+ Added information about creating Windows / Windows CE
builds on Linux. Corresponding scripts references.
! Minor correction to OS/2 on Windows cross-build example.
* harbour/contrib/hbxbp/tests/demoxbp.prg
+ Demonstrated the XbpRtf() class implementation.
Click on <Rtf> tab-page and view the results. Also examine the code.
* contrib/hbct/Makefile
- contrib/hbct/blank.prg
+ contrib/hbct/blank.c
+ Applied patch by Pavel Tsarenko (xhb) (with some little modifications):
BLANK() function rewritten in C.
* contrib/rddads/adsfunc.c
! Reimplemented fix from Pavel Tsarenko (xhb):
Removed unnecessary OEM to ANSI convertation in SQL functions.
2009-07-12 00:01 UTC-0800 Pritpal Bedi (pritpal@vouchcac.com)
* harbour/contrib/hbxbp/Makefile
* harbour/contrib/hbxbp/xbp.ch
* harbour/contrib/hbxbp/xbpdialog.prg
* harbour/contrib/hbxbp/xbpgeneric.prg
* harbour/contrib/hbxbp/xbpprinter.prg
+ harbour/contrib/hbxbp/xbprtf.prg
+ Implemented XbpRtf() class - the toughest so far.
Example code lifted from Xbase++ documentaion is working as is
except for one feature. Still more work is required. I see a
possibility of lot more features in this class - later.
* harbour/contrib/hbxbp/tests/demoxbp.prg
+ Demonstrated the XbpRtf() class implementation.
Click on <Rtf> tab-page and view the results. Also examine the code.
2009-07-11 11:44 UTC-0800 Pritpal Bedi (pritpal@vouchcac.com)
* harbour/contrib/hbqt/generator/hbqtgen.prg
@@ -489,13 +505,13 @@
* harbour/contrib/hbqt/TQWindowsStyle.prg
* harbour/contrib/hbqt/TQWindowsXPStyle.prg
* harbour/contrib/hbqt/TQWizard.prg
+ .cpp generation : HB_FUNC( QT_<object>_DESTROY )
information : More info included
+ .prg generation : METHOD Configure( xObject )
METHOD Destroy()
! Tweaked copyright info a little.
2009-07-11 18:59 UTC+0200 Viktor Szakats (harbour.01 syenar.hu)
* config/dos/global.cf
* config/win/global.cf

View File

@@ -66,6 +66,10 @@ HOW TO BUILD AND INSTALL HARBOUR FROM SOURCE
in the name. You can leave it empty, in this case the
results will be created under the current directory tree.
- With mingw, sh.exe (part of MSYS) mustn't be in the PATH.
- You can also use Linux hosts to create Windows builds.
See script: make_gnu_xmingw.sh
- You can also use Linux hosts to create Windows CE builds.
See script: make_gnu_xmingwce.sh
Windows with MinGW + MSYS or Cygwin
----------------------------------------------
@@ -588,7 +592,7 @@ EXAMPLES
call make_gnu_os2.cmd %1 %2 > log-%HB_COMPILER%.txt 2>&1
---
--- Open Watcom C++ on Windows NT (requires native Windows Harbour binaries)
--- Open Watcom C++ on Windows NT host (requires native Windows Harbour binaries)
SET WATCOM=C:\watcom
SET PATH=%WATCOM%\BINNT;%WATCOM%\BINW;%PATH%
SET BEGINLIBPATH=%WATCOM%\BINP\DLL
@@ -601,12 +605,12 @@ EXAMPLES
rem
set HB_ARCHITECTURE=os2
set HB_COMPILER=watcom
set HB_USER_PRGFLAGS=-D__PLATFORM__OS2 -undef:__PLATFORM__WINDOWS
set HB_USER_PRGFLAGS=%HB_USER_PRGFLAGS% -D__PLATFORM__OS2 -undef:__PLATFORM__WINDOWS
set HB_INSTALL_PREFIX=C:\hb-%HB_COMPILER%
call make_gnu.bat %1 %2 > log-%HB_COMPILER%.txt 2>&1
---
--- Open Watcom C++ on Linux (requires native Linux Harbour binaries)
--- Open Watcom C++ on Linux host (requires native Linux Harbour binaries)
#!/bin/sh
if [ -z "${WATCOM}" ]; then
export WATCOM="/opt/lng/watcom"

View File

@@ -14,6 +14,7 @@ C_SOURCES =\
atnum.c \
atrepl.c \
bitnum.c \
blank.c \
charevod.c \
charlist.c \
charmirr.c \
@@ -94,7 +95,6 @@ C_HEADERS = \
ctwin.h \
PRG_SOURCES=\
blank.prg \
ct.prg \
ctdummy.prg \
ctmisc.prg \

View File

@@ -6,9 +6,8 @@
* Harbour Project source code:
* CT3 BLANK function
*
* Copyright 2003 Luiz Rafael Culik Guimaraes <culikr@uol.com.br>
*
* www - http://www.harbour-project.org
* Copyright 2009 Pavel Tsarenko <tpe2@mail.ru>
* http://www.xharbour.org
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -51,43 +50,80 @@
*
*/
#include "hbapi.h"
#include "hbapiitm.h"
#include "common.ch"
#include "ct.h"
FUNCTION BLANK( xItem, xMode )
LOCAL cType := ValType( xItem )
LOCAL xRet
HB_FUNC( BLANK )
{
PHB_ITEM pItem = hb_param( 1, HB_IT_ANY );
BOOL bRef = HB_ISBYREF( 1 );
BOOL bRet = ! ct_getref();
SWITCH cType
CASE "D"
xRet := CTOD( "" )
EXIT
if( ! pItem )
{
if( bRet )
hb_retl( FALSE );
}
else if( HB_IS_DATE( pItem ) )
{
if( bRef )
hb_stordl( 0, 1 );
if( bRet )
hb_retdl( 0 );
}
else if( HB_IS_NUMBER( pItem ) )
{
if( bRef )
hb_stornl( 0, 1 );
if( bRet )
hb_retnl( 0 );
}
else if( HB_IS_STRING( pItem ) )
{
PHB_ITEM pMode = hb_param( 2, HB_IT_LOGICAL );
CASE "L"
xRet :=.F.
EXIT
if( pMode && hb_itemGetL( pMode ) )
{
ULONG lLen = hb_itemGetCLen( pItem );
char * szResult = ( char * ) hb_xgrab( lLen + 1 );
CASE "N"
xRet := 0
EXIT
CASE "C"
CASE "M"
xRet := xItem := IIF( ISLOGICAL( xMode ) .and. xMode, ;
Space( Len( xItem ) ), "" )
EXIT
CASE "A"
xRet := {}
EXIT
CASE "H"
xRet := {=>}
EXIT
OTHERWISE
xRet:=.F.
ENDSWITCH
RETURN xRet
hb_xmemset( szResult, ' ', lLen );
if( bRef )
hb_storclen( szResult, lLen, 1 );
if( bRet )
hb_retclen_buffer( szResult, lLen );
else
hb_xfree( szResult );
}
else
{
if( bRef )
hb_storc( NULL, 1 );
if( bRet )
hb_retc_null();
}
}
else if( HB_IS_ARRAY( pItem ) )
{
if( bRef )
hb_arraySize( pItem, 0 );
if( bRet )
hb_reta( 0 );
}
else if( HB_IS_LOGICAL( pItem ) )
{
if( bRef )
hb_storl( FALSE, 1 );
if( bRet )
hb_retl( FALSE );
}
else
{
if( bRet )
hb_retl( FALSE );
}
if( ! bRet )
hb_ret();
}

View File

@@ -1205,16 +1205,11 @@ HB_FUNC( ADSEXECUTESQLDIRECT )
if( /* hb_ads_hConnect && */ pArea && pArea->hStatement && HB_ISCHAR( 1 ) )
{
char * pucStmt = hb_adsOemToAnsi( hb_parc( 1 ), hb_parclen( 1 ) );
ADSHANDLE hCursor = 0;
UNSIGNED32 ulRetVal = AdsExecuteSQLDirect( pArea->hStatement,
( UNSIGNED8 * ) pucStmt,
&hCursor );
hb_adsOemAnsiFree( pucStmt );
if( ulRetVal == AE_SUCCESS )
if( AdsExecuteSQLDirect( pArea->hStatement,
( UNSIGNED8 * ) hb_parc( 1 ) /* pucStmt */,
&hCursor ) == AE_SUCCESS )
{
if( hCursor )
{
@@ -1254,14 +1249,8 @@ HB_FUNC( ADSPREPARESQL )
if( /* hb_ads_hConnect && */ pArea && pArea->hStatement && HB_ISCHAR( 1 ) )
{
char * pucStmt = hb_adsOemToAnsi( hb_parc( 1 ), hb_parclen( 1 ) );
UNSIGNED32 ulRetVal = AdsPrepareSQL( pArea->hStatement,
( UNSIGNED8 * ) pucStmt );
hb_adsOemAnsiFree( pucStmt );
if( ulRetVal == AE_SUCCESS )
if( AdsPrepareSQL( pArea->hStatement,
( UNSIGNED8 * ) hb_parc( 1 ) /* pucStmt */ ) == AE_SUCCESS )
hb_retl( TRUE );
else
{
@@ -1321,13 +1310,7 @@ HB_FUNC( ADSVERIFYSQL )
ADSAREAP pArea = hb_adsGetWorkAreaPointer();
if( pArea && pArea->hStatement && HB_ISCHAR( 1 ) )
{
char * pucStmt = hb_adsOemToAnsi( hb_parc( 1 ), hb_parclen( 1 ) );
hb_retl( AdsVerifySQL( pArea->hStatement, ( UNSIGNED8 * ) pucStmt ) == AE_SUCCESS );
hb_adsOemAnsiFree( pucStmt );
}
hb_retl( AdsVerifySQL( pArea->hStatement, ( UNSIGNED8 * ) hb_parc( 1 ) /* pucStmt */ ) == AE_SUCCESS );
else
hb_errRT_DBCMD( EG_NOTABLE, 2001, NULL, HB_ERR_FUNCNAME );
#else