* source/rtl/net.c
* contrib/hbziparc/hbziparc.prg
* contrib/hbct/files.c
* Minor formatting.
* source/rtl/gtxwc/gtxwc.c
! Fix to recent fix. An '!' was missing, Przemek pls check me.
* source/rtl/philes.c
+ HB_PROGNAME() now returns absolute path in *NIX systems, too.
(please test and refine)
* source/lang/msgca.c
! Fixes from xhb.
* contrib/hbziparc/hbziparc.prg
* Minor correction ( = -> := )
* source/rtl/gtwin/gtwin.c
+ Added HB_GTI_CODEPAGE support.
As per MS docs, this works only when non-raster font is used
in the console window. Notice that the accepted CP values are
different from the GTWVT ones (GTWIN being the more "logical"
one, since it's a newer API). Currently, Harbour doesn't try
to hide these interface details.
; TODO: UNICODE and BOX char support for GTWIN mode.
* source/rtl/tbrowse.prg
* Using HB_DISPOUTATBOX() to draw column/header/footer separators.
; NOTE: This may cause problems if someone wants to use native
CP (accented or other special CP specific) chars to draw
these screen elements. Maybe an option should be added,
or some sort of markings in the separator strings to
control that.
Pls REVIEW.
* include/hbextern.ch
* source/rtl/console.c
+ Added HB_DISPOUTATBOX() which is similar to HB_DISPOUTAT(),
but marks the text drawn as HB_GT_ATTR_BOX, so these chars
can be properly displayed as drawing chars, regardless of
the selected codepage. Another difference is that this
function only supports strings to be printed. Other types
don't print anything.
; NOTE: Maybe this function could use a better name, pls
review and decide.
* source/rtl/gtwvt/gtwvt.c
* source/rtl/gtwvt/gtwvt.h
! Fixed not accepting zero as a HB_GTI_CODEPAGE value.
! Fixed HB_GTI_CODEPAGE to change the codepage.
+ Added box char support in Unicode mode.
For chars marked as HB_GT_ATTR_BOX, chars will be
mapped to Unicode according to CP437.
+ Added box char support in non-Unicode mode.
For chars marked as HB_GT_ATTR_BOX, OEM_CHARSET will
always be used.
; NOTE: This way it's possible to use ISO/WIN codepages with
GTWVT, while still being able to use various drawing
chars (lines, blocks, arrows).
; NOTE: The available set of drawing chars depends on the
OS OEM_CHARSET mapping _for non-Unicode Harbour_.
For Unicode Harbour, full CP437 codepage is
always available.
; NOTE: This solution doesn't go as far as (GTWXC) to
graphically draw / emulate these chars.
; TODO: Add HB_GTI_BOXCP support to change hard-wired "EN" CP.
* include/hbapigt.h
* include/hbgtcore.h
! Moved HB_GT_ATTR_* macros to public headers, because they
are needed for public API functions.
* contrib/hbwin/win_reg.prg
+ w32_regRead(): Added second parameter to specify the default
value returned in case the reg entry doesn't exist.
If not specified, NIL will be returned, just like before.
+ GetRegistry(): Added 4th parameter with same purpose as above.
* source/rtl/hbregex.c
* Minor opt.
* contrib/hbwin/win_misc.c
* Added command line option parameter to WIN_RUNDETACHED().
* include/hbapi.h
+ HB_ERRCODE (to replace ERRCODE)
+ HB_SUCCESS (to replace SUCCESS)
+ HB_FAILURE (to replace FAILURE)
+ contrib/hbwin/win_misc.c
* contrib/hbwin/common.mak
* contrib/hbwin/Makefile
+ WIN_SHELLEXECUTE()
WIN_RUNDETACHED()
WIN_LOADRESOURCE()
Added some new Windows API wrappers.
; TODO: Add hb_osEncode() to them.
* source/rtl/diskspac.c
* source/rtl/disksphb.c
! Fixed DISKSPACE() and HB_DISKSPACE() for Darwin.
Previously they had returned erroneous values.
; TOFIX: Probably HB_DISKSPACE() should be implemented for Watcom and CEGCC,
just like DISKSPACE() is.
* source/rtl/filesys.c
! hb_fsGetAttr() to set the returned attribute to zero
in case of error.
* include/hbextern.ch
* source/rtl/philes.c
+ HB_FSETATTR( <cFileName>, @<nAttr> ) -> <lSuccess>
+ HB_FGETATTR( <cFileName>, <nAttr> ) -> <lSuccess>
+ HB_FSETDATETIME( <cFileName>, [<dDate>], [<cTime HH:MM:SS>] ) -> <lSuccess>
* source/rtl/direct.c
! Fixed DIRECTORY() when called with "V" (label) parameter.
Tested under Windows. Please test/correct for other platforms.
On Windows, the dirspec should not contain a filemask in order
to work.
* contrib/hbtip/base64x.c
% HB_BASE64(): Optimized, cleaned.
! HB_BASE64(): Removed second parameter allowing to pass the length of
the string. This could cause GPF if passed incorrectly. Now length
is simply determined using hb_parclen().
; TOFIX: Input string size limit checking.
* include/hbdefs.h
+ HB_SIZEOFARRAY() macro, which does: ( sizeof( var ) / sizeof( *var ) )
To be really precise, f.e. all hb_strncpy() calls should use
'hb_strncpy( d, s, HB_SIZEOFARRAY( d ) );' instead of:
'hb_strncpy( d, s, sizeof( d ) );' (given that 'd' is allocated at compile time).
So that the code adapts to changing character sizes (like UTF-16/32).
It's useful in some other places, too.
* contrib/hbct/dattime2.c
* 0 -> FALSE for BOOL types.
* include/hbextern.ch
* source/rtl/strmatch.c
+ HB_WILDMATCHI(). Case-instenstive, exact match. First
two parameters and return value are the same as for
HB_WILDMATCH().
* include/hbextern.ch
* source/rtl/cdpapi.c
+ HB_CDPSELECT() which does the same as HB_SETCODEPAGE(), but
aligns well with function naming rules and namespace.
HB_SETCODEPAGE() still works, but usage is not recommended.
+ Added HB_CDPUNIID( <cHarbourCP> ) -> <cCPName>
This will return the std CP ID of a Harbour CP, or empty
if the Harbour CP isn't linked.
* include/hbapi.h
* source/rtl/is.c
! Fixed compile error when HB_CDP_SUPPORT_OFF is defined.
+ Added following functions:
hb_charIsDigit()
hb_charIsAlpha()
hb_charIsLower()
hb_charIsUpper()
* include/hbapi.h
- hb_strUpperCopy() removed. Implementation was missing.
* source/rtl/strcase.c
* Minor formatting.
* source/rtl/filesys.c
! hb_fsCurDirBuff() fixed potential buffer overrun by one byte.
* source/rtl/hbrunfun.c
* source/rtl/run.c
! Fixed missing header hbapiitm.h (after previous local change).
* include/hbapi.h
* include/hbset.h
* include/hbapifs.h
* include/set.ch
* source/rtl/hbffind.c
* source/rtl/gete.c
* source/rtl/filesys.c
* source/rtl/hbrunfun.c
* source/rtl/run.c
* source/rtl/philes.c
* source/vm/set.c
* source/vm/cmdarg.c
+ Added file system CP translation.
Set( _SET_FNAMECP[, <cCPID> ] ) -> <cOldCPID>
All operations passing filenames to/from the
OS will convert them to/from the host CP from/to
the FS CP specified using _SET_FNAMECP.
* hb_fsNameConv() extended to deal with CP
conversion, if requested by the app.
+ hb_fsNameConvFrom() (exported) added to deal
with CP conversions for filenames received from OS.
+ hb_fsNameConvTo() (exported) added to deal
with CP conversions for filenames/string sent to the OS.
+ Added hb_setGetFNAMECP() (exported) function.
+ Added hb_setGetFileCPTransTo(), hb_setGetFileCPTransFrom()
(non-exported) functions.
+ hb_fsCurDirBuff() and hb_fsFindNextLow() extended
to use hb_fsNameConvFrom().
+ Added hb_fsBaseDirBuff() to return the base
directory on the C level (based on argv[0]).
+ Added HB_PROGNAME() to return the executable
program name (based on argv[0]).
+ Added HB_DIRBASE() to return the executable
base directory (based on argv[0]).
* Renames done regarding OS/FS CP conversion:
hb_fsNameConvFrom() -> hb_osDecode()
hb_fsNameConvTo() -> hb_osEncode()
hb_setGetFileCPTransTo() -> -
hb_setGetFileCPTransFrom() -> -
hb_setGetFNAMECP() -> hb_setGetOSCODEPAGE()
_SET_FNAMECP -> _SET_OSCODEPAGE
* hb_osDecode()/hb_osEncode() extended to have a second
parameter BOOL * fFree.
Changed all calls to handle the case when fFree is set
to TRUE by hb_osDecode()/hb_osEncode().
+ HB_GETENV(): Added 3rd logical parameter to control wether
to convert the returned value from OS CP to Harbour CP.
The default is TRUE to be in sync with GETE[NV]() and the
rest of core.
* hb_fsNameConv() is now doing OS CP conversion using std APIs,
rather than duplicating such logic. I've traded some speed
for modularity.
* hb_osDecode/hb_osEncode() function declarations moved to hbapi.h
* hb_osDecode/hb_osEncode() function definitions moved to set.c
; NOTE: None of these were extensively tested, and I tend
to make mistakes when dealing with pointers.
It compiles cleanly with BCC, and some basic tests
worked, but bFree = TRUE codepaths are not yet
working so this needs more review.
* source/rtl/teditor.prg
* source/rtl/tpersist.prg
* utils/hbmake/hbmake.prg
* MemoRead() -> hb_MemoRead()
* contrib/hbct/files.c
; TOFIX: Many functions here are possibly not thread safe.
; TOFIX: Calling hb_fsFindClose() at app exit (and thus keeping
the FF handles open for the whole app lifetime) doesn't
play well with server side apps (as the app may run for
months or even longer), and even worse, they
will lock the passed directory so that they cannot be
removed (maybe even renamed), until the app exists.
At least on Windows.
* source/rtl/dirdrive.c
! Fixed to use F_ERROR instead of -1.
* include/hbextern.ch
! Added missing HB_GCSTEP().
* source/vm/extrap.c
+ Added CPU dump code for Windows x64.
+ Enabled module listing for Windows 64-bit platforms.
% Minor cleanup in Windows x86 CPU dump code.
+ Added TODO for Windows IA64 CPU dump.
+ Added TODO for Windows x64 stack walk, with pointers.
+ Added TOFIX regarding displaying module names in Windows x64 mode.
* source/rtl/fstemp.c
! Minor formatting.
* source/rtl/gete.c
* source/rtl/run.c
* source/rtl/hbrunfun.c
* source/vm/cmdarg.c
+ Added CP conversion to:
GETE[NV](), HB_GETENV(), __RUN(), HB_RUN(),
HB_ARGSTRING(), HB_CMDLINE().
; TODO: dbCreateTemp( <cAlias>, <aStruct>, <cRDD>, <cDelimArg>, <nConnection> ) -> <lSuccess>
Generates and opens a new dbf with a temporary filename
in exclusive mode, deletes it automatically when closed.
All indexes created for this table, should ideally have
the temporary flag on, so those get deleted too, when closed.
; TOFIX: hb_regex*() functions will not honor Harbour CP setting,
when case insensitivity is selected.
; TOFIX: hbct / SetFDaTi() to move any local logic into Harbour core
functions and use a simple Harbour API call only.
I'm not sure what is the reason with keeping the logic
duplicated here; if this isn't by intent, this function
could be much simplified.
; TOFIX: Avoid using C level toupper()/tolower()/islower()/isupper()
; TOFIX: hb_regexMatch()'s 3rd parameter has a double meaning.
It controls case-sensitivity (in sync with the documentation),
but it also controls if hb_regexMatch() behaves like
hb_regexLike() (.T.), or hb_regexHas() (.F.). This means
that hb_regexMatch(,, .T.) == hb_regexLike(,, .T.) (case-sensitive) and
hb_regexMatch(,, .F.) == hb_regexHas(,, .F.) (case-insensitive)
Maybe this was the intent of the original developers, but
to me it looks a rather strange behaviour which was added by
accidentally forgetting about the 3rd parameter already being
utilized. This either needs to be fixed, or properly documented.
; NOTE: Noteworthy links:
http://docs.python.org/3.0/whatsnew/3.0.html
- Unicode/text section
- Removed <> (use != instead)
http://sphinx.pocoo.org/
- Documentation format
http://fredeaker.blogspot.com/2007/01/character-encoding-detection.html
- Character encoding detection
621 lines
34 KiB
C
621 lines
34 KiB
C
/*
|
|
* $Id$
|
|
*/
|
|
|
|
/*
|
|
* Harbour Project source code:
|
|
* Header file for the Internal Terminal API
|
|
*
|
|
* Copyright 2006 Przemyslaw Czerpak < druzus /at/ priv.onet.pl >
|
|
* www - http://www.harbour-project.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
|
|
* the Free Software Foundation; either version 2, or (at your option)
|
|
* any later version.
|
|
*
|
|
* This program is distributed in the hope that it will be useful,
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
* GNU General Public License for more details.
|
|
*
|
|
* You should have received a copy of the GNU General Public License
|
|
* along with this software; see the file COPYING. If not, write to
|
|
* the Free Software Foundation, Inc., 59 Temple Place, Suite 330,
|
|
* Boston, MA 02111-1307 USA (or visit the web site http://www.gnu.org/).
|
|
*
|
|
* As a special exception, the Harbour Project gives permission for
|
|
* additional uses of the text contained in its release of Harbour.
|
|
*
|
|
* The exception is that, if you link the Harbour libraries with other
|
|
* files to produce an executable, this does not by itself cause the
|
|
* resulting executable to be covered by the GNU General Public License.
|
|
* Your use of that executable is in no way restricted on account of
|
|
* linking the Harbour library code into it.
|
|
*
|
|
* This exception does not however invalidate any other reasons why
|
|
* the executable file might be covered by the GNU General Public License.
|
|
*
|
|
* This exception applies only to the code released by the Harbour
|
|
* Project under the name Harbour. If you copy code from other
|
|
* Harbour Project or Free Software Foundation releases into a copy of
|
|
* Harbour, as the General Public License permits, the exception does
|
|
* not apply to the code that you add in this way. To avoid misleading
|
|
* anyone as to the status of such modified files, you must delete
|
|
* this exception notice from them.
|
|
*
|
|
* If you write modifications of your own for Harbour, it is your choice
|
|
* whether to permit this exception to apply to your modifications.
|
|
* If you do not wish that, delete this exception notice.
|
|
*
|
|
*/
|
|
|
|
/* NOTE: The declaration of hb_gtSetPos(), hb_gtGetPos(), hb_gtWrite(),
|
|
hb_gtWriteAt(), hb_gtRepChar(), hb_gtBox(), hb_gtBoxS(), hb_gtBoxD()
|
|
hb_gtInit() differs in parameter types from the original CA-Cl*pper
|
|
versions. [vszakats] */
|
|
|
|
#ifndef HB_GTCORE_H_
|
|
#define HB_GTCORE_H_
|
|
|
|
#include "hbapigt.h"
|
|
#include "hbapicdp.h"
|
|
|
|
HB_EXTERN_BEGIN
|
|
|
|
/* convert lower case suffixes to upper */
|
|
#define HB_GT_nul HB_GT_NUL
|
|
#define HB_GT_std HB_GT_STD
|
|
#define HB_GT_cgi HB_GT_CGI
|
|
#define HB_GT_pca HB_GT_PCA
|
|
#define HB_GT_crs HB_GT_CRS
|
|
#define HB_GT_sln HB_GT_SLN
|
|
#define HB_GT_win HB_GT_WIN
|
|
#define HB_GT_wvt HB_GT_WVT
|
|
#define HB_GT_dos HB_GT_DOS
|
|
#define HB_GT_os2 HB_GT_OS2
|
|
#define HB_GT_tpl HB_GT_TPL
|
|
#define HB_GT_trm HB_GT_TRM
|
|
#define HB_GT_QTc HB_GT_QTC
|
|
#define HB_GT_xvt HB_GT_XVT
|
|
#define HB_GT_xwc HB_GT_XWC
|
|
#define HB_GT_gui HB_GT_GUI
|
|
|
|
/* These hacks are needed to force preprocessing if id/x is also a macro */
|
|
#define _HB_GT_PREF_( id ) _HB_GT_PREF__( id )
|
|
#define _HB_GT_PREF__( id ) HB_GT_##id
|
|
|
|
#define HB_GT_REQUEST( id ) HB_GT_REQUEST_( _HB_GT_PREF_( id ) )
|
|
#define HB_GT_REQUEST_( id ) HB_GT_REQUEST__( id )
|
|
#define HB_GT_REQUEST__( id ) HB_FUNC_EXTERN( id ); \
|
|
void hb_gt_ForceLink_##id( void ) \
|
|
{ \
|
|
HB_FUNC_EXEC( id ); \
|
|
}
|
|
|
|
#define HB_GT_ANNOUNCE( id ) HB_GT_ANNOUNCE_( _HB_GT_PREF_( id ) )
|
|
#define HB_GT_ANNOUNCE_( id ) HB_GT_ANNOUNCE__( id )
|
|
#define HB_GT_ANNOUNCE__( id ) HB_FUNC( id ) {} HB_FUNC( id##_DEFAULT ) {}
|
|
|
|
#define HB_GT_DRVNAME( id ) HB_MACRO2STRING( id )
|
|
|
|
#define HB_GT_FUNC( x ) HB_GT_FUNC_( x, HB_GT_NAME )
|
|
#define HB_GT_FUNC_( x, id ) HB_GT_FUNC__( x, id )
|
|
#define HB_GT_FUNC__( x, id ) hb##_##id##_##x
|
|
|
|
/* forward declaration */
|
|
struct _HB_GT_BASE;
|
|
|
|
#define HB_GT_PTR struct _HB_GT_BASE *
|
|
|
|
typedef struct
|
|
{
|
|
BOOL (* Lock) ( HB_GT_PTR );
|
|
void (* Unlock) ( HB_GT_PTR );
|
|
void (* Init) ( HB_GT_PTR, HB_FHANDLE, HB_FHANDLE, HB_FHANDLE );
|
|
void (* Exit) ( HB_GT_PTR );
|
|
void * (* New) ( HB_GT_PTR );
|
|
void (* Free) ( HB_GT_PTR );
|
|
BOOL (* Resize ) ( HB_GT_PTR, int, int );
|
|
BOOL (* SetMode) ( HB_GT_PTR, int, int );
|
|
void (* GetSize) ( HB_GT_PTR, int *, int * );
|
|
void (* SemiCold) ( HB_GT_PTR );
|
|
void (* ColdArea) ( HB_GT_PTR, int, int, int, int );
|
|
void (* ExposeArea) ( HB_GT_PTR, int, int, int, int );
|
|
void (* ScrollArea) ( HB_GT_PTR, int, int, int, int, BYTE, BYTE, int, int );
|
|
void (* TouchCell) ( HB_GT_PTR, int, int );
|
|
void (* Redraw) ( HB_GT_PTR, int, int, int );
|
|
void (* Refresh) ( HB_GT_PTR );
|
|
void (* Flush) ( HB_GT_PTR );
|
|
int (* MaxCol) ( HB_GT_PTR );
|
|
int (* MaxRow) ( HB_GT_PTR );
|
|
BOOL (* CheckPos) ( HB_GT_PTR, int, int, long * );
|
|
void (* SetPos) ( HB_GT_PTR, int, int );
|
|
void (* GetPos) ( HB_GT_PTR, int *, int * );
|
|
BOOL (* IsColor) ( HB_GT_PTR );
|
|
void (* GetColorStr) ( HB_GT_PTR, char * );
|
|
void (* SetColorStr) ( HB_GT_PTR, const char * );
|
|
void (* ColorSelect) ( HB_GT_PTR, int );
|
|
int (* GetColor) ( HB_GT_PTR );
|
|
int (* ColorNum) ( HB_GT_PTR, const char * );
|
|
void (* ColorsToString) ( HB_GT_PTR, int *, int, char *, int );
|
|
void (* StringToColors) ( HB_GT_PTR, const char *, int **, int * );
|
|
void (* GetColorData) ( HB_GT_PTR, int **, int *, int * );
|
|
int (* GetClearColor) ( HB_GT_PTR );
|
|
void (* SetClearColor) ( HB_GT_PTR, int );
|
|
int (* GetClearChar) ( HB_GT_PTR );
|
|
void (* SetClearChar) ( HB_GT_PTR, int );
|
|
int (* GetCursorStyle) ( HB_GT_PTR );
|
|
void (* SetCursorStyle) ( HB_GT_PTR, int );
|
|
void (* GetScrCursor) ( HB_GT_PTR, int *, int *, int * );
|
|
BOOL (* GetScrChar) ( HB_GT_PTR, int, int, BYTE *, BYTE *, USHORT * );
|
|
BOOL (* PutScrChar) ( HB_GT_PTR, int, int, BYTE, BYTE, USHORT );
|
|
void (* DispBegin) ( HB_GT_PTR );
|
|
void (* DispEnd) ( HB_GT_PTR );
|
|
int (* DispCount) ( HB_GT_PTR );
|
|
BOOL (* GetChar) ( HB_GT_PTR, int, int, BYTE *, BYTE *, USHORT * );
|
|
BOOL (* PutChar) ( HB_GT_PTR, int, int, BYTE, BYTE, USHORT );
|
|
long (* RectSize) ( HB_GT_PTR, int, int, int, int );
|
|
void (* Save) ( HB_GT_PTR, int, int, int, int, BYTE * );
|
|
void (* Rest) ( HB_GT_PTR, int, int, int, int, BYTE * );
|
|
void (* PutText) ( HB_GT_PTR, int, int, BYTE, BYTE *, ULONG );
|
|
void (* Replicate) ( HB_GT_PTR, int, int, BYTE, BYTE, USHORT, ULONG );
|
|
void (* WriteAt) ( HB_GT_PTR, int, int, BYTE *, ULONG );
|
|
void (* Write) ( HB_GT_PTR, BYTE *, ULONG );
|
|
void (* WriteCon) ( HB_GT_PTR, BYTE *, ULONG );
|
|
void (* SetAttribute) ( HB_GT_PTR, int, int, int, int, BYTE );
|
|
void (* DrawShadow) ( HB_GT_PTR, int, int, int, int, BYTE );
|
|
void (* Scroll) ( HB_GT_PTR, int, int, int, int, BYTE, BYTE, int, int );
|
|
void (* ScrollUp) ( HB_GT_PTR, int, BYTE, BYTE );
|
|
void (* Box) ( HB_GT_PTR, int, int, int, int, BYTE *, BYTE );
|
|
void (* BoxD) ( HB_GT_PTR, int, int, int, int, BYTE *, BYTE );
|
|
void (* BoxS) ( HB_GT_PTR, int, int, int, int, BYTE *, BYTE );
|
|
void (* HorizLine) ( HB_GT_PTR, int, int, int, BYTE, BYTE );
|
|
void (* VertLine) ( HB_GT_PTR, int, int, int, BYTE, BYTE );
|
|
BOOL (* GetBlink) ( HB_GT_PTR );
|
|
void (* SetBlink) ( HB_GT_PTR, BOOL );
|
|
void (* SetSnowFlag) ( HB_GT_PTR, BOOL );
|
|
const char * (* Version) ( HB_GT_PTR, int );
|
|
BOOL (* Suspend) ( HB_GT_PTR );
|
|
BOOL (* Resume) ( HB_GT_PTR );
|
|
BOOL (* PreExt) ( HB_GT_PTR );
|
|
BOOL (* PostExt) ( HB_GT_PTR );
|
|
void (* OutStd) ( HB_GT_PTR, BYTE *, ULONG );
|
|
void (* OutErr) ( HB_GT_PTR, BYTE *, ULONG );
|
|
void (* Tone) ( HB_GT_PTR, double, double );
|
|
void (* Bell) ( HB_GT_PTR );
|
|
BOOL (* Info) ( HB_GT_PTR, int, PHB_GT_INFO );
|
|
int (* Alert) ( HB_GT_PTR, PHB_ITEM, PHB_ITEM, int, int, double );
|
|
int (* SetFlag) ( HB_GT_PTR, int, int );
|
|
|
|
/* internationalization */
|
|
BOOL (* SetDispCP) ( HB_GT_PTR, const char *, const char *, BOOL );
|
|
BOOL (* SetKeyCP) ( HB_GT_PTR, const char *, const char * );
|
|
|
|
/* keyboard */
|
|
int (* ReadKey) ( HB_GT_PTR, int );
|
|
|
|
int (* InkeyGet) ( HB_GT_PTR, BOOL fWait, double dSeconds, int iEventMask );
|
|
void (* InkeyPut) ( HB_GT_PTR, int iKey );
|
|
void (* InkeyIns) ( HB_GT_PTR, int iKey );
|
|
int (* InkeyLast) ( HB_GT_PTR, int iEventMask );
|
|
int (* InkeyNext) ( HB_GT_PTR, int iEventMask );
|
|
void (* InkeyPoll) ( HB_GT_PTR );
|
|
void (* InkeySetText) ( HB_GT_PTR, const char * szText, ULONG ulLen );
|
|
int (* InkeySetLast) ( HB_GT_PTR, int iKey );
|
|
void (* InkeyReset) ( HB_GT_PTR );
|
|
void (* InkeyExit) ( HB_GT_PTR );
|
|
|
|
/* mouse */
|
|
void (* MouseInit) ( HB_GT_PTR );
|
|
void (* MouseExit) ( HB_GT_PTR );
|
|
BOOL (* MouseIsPresent) ( HB_GT_PTR );
|
|
void (* MouseShow) ( HB_GT_PTR );
|
|
void (* MouseHide) ( HB_GT_PTR );
|
|
BOOL (* MouseGetCursor) ( HB_GT_PTR );
|
|
void (* MouseSetCursor) ( HB_GT_PTR, BOOL );
|
|
int (* MouseCol) ( HB_GT_PTR );
|
|
int (* MouseRow) ( HB_GT_PTR );
|
|
void (* MouseGetPos) ( HB_GT_PTR, int *, int * );
|
|
void (* MouseSetPos) ( HB_GT_PTR, int, int );
|
|
void (* MouseSetBounds) ( HB_GT_PTR, int, int, int, int );
|
|
void (* MouseGetBounds) ( HB_GT_PTR, int *, int *, int *, int * );
|
|
int (* MouseStorageSize) ( HB_GT_PTR );
|
|
void (* MouseSaveState) ( HB_GT_PTR, BYTE * );
|
|
void (* MouseRestoreState) ( HB_GT_PTR, BYTE * );
|
|
int (* MouseGetDoubleClickSpeed) ( HB_GT_PTR );
|
|
void (* MouseSetDoubleClickSpeed) ( HB_GT_PTR, int );
|
|
int (* MouseCountButton) ( HB_GT_PTR );
|
|
BOOL (* MouseButtonState) ( HB_GT_PTR, int );
|
|
BOOL (* MouseButtonPressed) ( HB_GT_PTR, int, int *, int * );
|
|
BOOL (* MouseButtonReleased) ( HB_GT_PTR, int, int *, int * );
|
|
int (* MouseReadKey) ( HB_GT_PTR, int );
|
|
|
|
/* Graphics API */
|
|
int (* GfxPrimitive) ( HB_GT_PTR, int, int, int, int, int, int );
|
|
void (* GfxText) ( HB_GT_PTR, int, int, const char *, int, int, int );
|
|
|
|
#if 0
|
|
/* keyboard */
|
|
int (* ExtendedKeySupport) ( HB_GT_PTR );
|
|
|
|
/* GT CLIPBOARD functions */
|
|
void (* GetClipboard) ( HB_GT_PTR, char *, ULONG * );
|
|
void (* SetClipboard) ( HB_GT_PTR, char *, ULONG );
|
|
ULONG (* GetClipboardSize) ( HB_GT_PTR );
|
|
|
|
void (* ProcessMessages) ( HB_GT_PTR );
|
|
|
|
/* GT to DRIVER communication functions */
|
|
void (* update ) ( HB_GT_PTR, int );
|
|
int (* info ) ( HB_GT_PTR, int, BOOL , int , void * );
|
|
|
|
#endif
|
|
|
|
void (* WhoCares) ( HB_GT_PTR, void * );
|
|
|
|
} HB_GT_FUNCS, * PHB_GT_FUNCS;
|
|
|
|
typedef int ( * GTENTRYP_V )( void );
|
|
|
|
#define GTFUNCSCOUNT ( sizeof( HB_GT_FUNCS ) / sizeof( GTENTRYP_V ) )
|
|
|
|
#define HB_GT_MAX_ 32
|
|
#define HB_GT_NAME_MAX_ 8
|
|
|
|
typedef struct _HB_GT_INIT
|
|
{
|
|
const char * id;
|
|
BOOL (* init) ( PHB_GT_FUNCS );
|
|
PHB_GT_FUNCS pSuperTable;
|
|
int * pGtId;
|
|
} HB_GT_INIT, * PHB_GT_INIT;
|
|
|
|
|
|
typedef union
|
|
{
|
|
struct
|
|
{
|
|
UINT16 usChar;
|
|
BYTE bColor;
|
|
BYTE bAttr;
|
|
} c;
|
|
UINT32 uiValue;
|
|
} HB_SCREENCELL;
|
|
typedef HB_SCREENCELL * PHB_SCREENCELL;
|
|
|
|
|
|
typedef struct _HB_GT_BASE
|
|
{
|
|
PHB_GT_FUNCS pFuncTable;
|
|
|
|
PHB_ITEM pMutex;
|
|
int iUsed;
|
|
|
|
int iRow; /* cursor row position */
|
|
int iCol; /* cursor column position */
|
|
|
|
int iHeight; /* window height */
|
|
int iWidth; /* window width */
|
|
|
|
PHB_SCREENCELL screenBuffer; /* window foreground (board) current buffer */
|
|
PHB_SCREENCELL prevBuffer; /* window foreground (board) previous buffer */
|
|
|
|
BOOL * pLines; /* Touched Window lines */
|
|
BOOL fRefresh; /* Should Window be refreshed */
|
|
|
|
BOOL fVgaCell;
|
|
BOOL fIsColor;
|
|
BOOL fBlinking;
|
|
BOOL fStdOutCon;
|
|
BOOL fStdErrCon;
|
|
int iCursorShape;
|
|
USHORT uiDispCount;
|
|
USHORT uiExtCount;
|
|
USHORT uiClearChar;
|
|
USHORT uiClearColor;
|
|
HB_FHANDLE hStdIn;
|
|
HB_FHANDLE hStdOut;
|
|
HB_FHANDLE hStdErr;
|
|
|
|
BOOL fDispTrans;
|
|
PHB_CODEPAGE cdpTerm;
|
|
PHB_CODEPAGE cdpHost;
|
|
|
|
int iColorIndex;
|
|
int iColorCount;
|
|
int * pColor;
|
|
|
|
int iDoubleClickSpeed; /* In milliseconds */
|
|
BOOL fMouseVisible;
|
|
int iMouseLastRow;
|
|
int iMouseLastCol;
|
|
HB_LONG iMouseLeftTimer;
|
|
HB_LONG iMouseRightTimer;
|
|
HB_LONG iMouseMiddleTimer;
|
|
|
|
int defaultKeyBuffer[ HB_DEFAULT_INKEY_BUFSIZE + 1 ];
|
|
|
|
int * inkeyBuffer;
|
|
int inkeyBufferSize;
|
|
int inkeyHead;
|
|
int inkeyTail;
|
|
int iLastPut;
|
|
int inkeyLast;
|
|
BYTE * StrBuffer;
|
|
ULONG StrBufferSize;
|
|
ULONG StrBufferPos;
|
|
|
|
PHB_ITEM pNotifierBlock;
|
|
|
|
void * pGTData[HB_GT_MAX_]; /* local GT data */
|
|
|
|
} HB_GT_BASE, * PHB_GT_BASE, * PHB_GT;
|
|
|
|
extern PHB_GT hb_gt_Base( void );
|
|
extern void hb_gt_BaseFree( PHB_GT pGT );
|
|
extern PHB_GT hb_gt_ItemBase( PHB_ITEM pItemGT );
|
|
|
|
#define HB_GTLOCAL(g) (g)->pGTData[*HB_GTID_PTR]
|
|
|
|
#define HB_GTSELF_LOCK(g) (g)->pFuncTable->Lock(g)
|
|
#define HB_GTSELF_UNLOCK(g) (g)->pFuncTable->Unlock(g)
|
|
#define HB_GTSELF_INIT(g,i,o,e) (g)->pFuncTable->Init(g,i,o,e)
|
|
#define HB_GTSELF_EXIT(g) (g)->pFuncTable->Exit(g)
|
|
#define HB_GTSELF_NEW(g) (g)->pFuncTable->New(g)
|
|
#define HB_GTSELF_FREE(g) (g)->pFuncTable->Free(g)
|
|
#define HB_GTSELF_RESIZE(g,r,c) (g)->pFuncTable->Resize(g,r,c)
|
|
#define HB_GTSELF_SETMODE(g,r,c) (g)->pFuncTable->SetMode(g,r,c)
|
|
#define HB_GTSELF_GETSIZE(g,pr,pc) (g)->pFuncTable->GetSize(g,pr,pc)
|
|
#define HB_GTSELF_SEMICOLD(g) (g)->pFuncTable->SemiCold(g)
|
|
#define HB_GTSELF_COLDAREA(g,t,l,b,r) (g)->pFuncTable->ColdArea(g,t,l,b,r)
|
|
#define HB_GTSELF_EXPOSEAREA(g,t,l,b,r) (g)->pFuncTable->ExposeArea(g,t,l,b,r)
|
|
#define HB_GTSELF_SCROLLAREA(g,t,l,b,r,m,u,v,h) (g)->pFuncTable->ScrollArea(g,t,l,b,r,m,u,v,h)
|
|
#define HB_GTSELF_TOUCHCELL(g,r,c) (g)->pFuncTable->TouchCell(g,r,c)
|
|
#define HB_GTSELF_REDRAW(g,r,c,l) (g)->pFuncTable->Redraw(g,r,c,l)
|
|
#define HB_GTSELF_REFRESH(g) (g)->pFuncTable->Refresh(g)
|
|
#define HB_GTSELF_FLUSH(g) (g)->pFuncTable->Flush(g)
|
|
#define HB_GTSELF_MAXCOL(g) (g)->pFuncTable->MaxCol(g)
|
|
#define HB_GTSELF_MAXROW(g) (g)->pFuncTable->MaxRow(g)
|
|
#define HB_GTSELF_CHECKPOS(g,r,c,l) (g)->pFuncTable->CheckPos(g,r,c,l)
|
|
#define HB_GTSELF_SETPOS(g,r,c) (g)->pFuncTable->SetPos(g,r,c)
|
|
#define HB_GTSELF_GETPOS(g,pr,pc) (g)->pFuncTable->GetPos(g,pr,pc)
|
|
#define HB_GTSELF_ISCOLOR(g) (g)->pFuncTable->IsColor(g)
|
|
#define HB_GTSELF_GETCOLORSTR(g,s) (g)->pFuncTable->GetColorStr(g,s)
|
|
#define HB_GTSELF_SETCOLORSTR(g,s) (g)->pFuncTable->SetColorStr(g,s)
|
|
#define HB_GTSELF_COLORSELECT(g,c) (g)->pFuncTable->ColorSelect(g,c)
|
|
#define HB_GTSELF_GETCOLOR(g) (g)->pFuncTable->GetColor(g)
|
|
#define HB_GTSELF_COLORNUM(g,s) (g)->pFuncTable->ColorNum(g,s)
|
|
#define HB_GTSELF_COLORSTOSTRING(g,pc,i,ps,n) (g)->pFuncTable->ColorsToString(g,pc,i,ps,n)
|
|
#define HB_GTSELF_STRINGTOCOLORS(g,ps,pc,pi) (g)->pFuncTable->StringToColors(g,ps,pc,pi)
|
|
#define HB_GTSELF_GETCOLORDATA(g,pc,pn,pi) (g)->pFuncTable->GetColorData(g,pc,pn,pi)
|
|
#define HB_GTSELF_GETCLEARCOLOR(g) (g)->pFuncTable->GetClearColor(g)
|
|
#define HB_GTSELF_SETCLEARCOLOR(g,c) (g)->pFuncTable->SetClearColor(g,c)
|
|
#define HB_GTSELF_GETCLEARCHAR(g) (g)->pFuncTable->GetClearChar(g)
|
|
#define HB_GTSELF_SETCLEARCHAR(g,c) (g)->pFuncTable->SetClearChar(g,c)
|
|
#define HB_GTSELF_GETCURSORSTYLE(g) (g)->pFuncTable->GetCursorStyle(g)
|
|
#define HB_GTSELF_SETCURSORSTYLE(g,s) (g)->pFuncTable->SetCursorStyle(g,s)
|
|
#define HB_GTSELF_GETSCRCURSOR(g,pr,pc,ps) (g)->pFuncTable->GetScrCursor(g,pr,pc,ps)
|
|
#define HB_GTSELF_GETSCRCHAR(g,r,c,pm,pa,pc) (g)->pFuncTable->GetScrChar(g,r,c,pm,pa,pc)
|
|
#define HB_GTSELF_PUTSCRCHAR(g,r,c,m,a,u) (g)->pFuncTable->PutScrChar(g,r,c,m,a,u)
|
|
#define HB_GTSELF_DISPBEGIN(g) (g)->pFuncTable->DispBegin(g)
|
|
#define HB_GTSELF_DISPEND(g) (g)->pFuncTable->DispEnd(g)
|
|
#define HB_GTSELF_DISPCOUNT(g) (g)->pFuncTable->DispCount(g)
|
|
#define HB_GTSELF_GETCHAR(g,r,c,pm,pa,pc) (g)->pFuncTable->GetChar(g,r,c,pm,pa,pc)
|
|
#define HB_GTSELF_PUTCHAR(g,r,c,m,a,u) (g)->pFuncTable->PutChar(g,r,c,m,a,u)
|
|
#define HB_GTSELF_RECTSIZE(g,t,l,b,r) (g)->pFuncTable->RectSize(g,t,l,b,r)
|
|
#define HB_GTSELF_SAVE(g,t,l,b,r,p) (g)->pFuncTable->Save(g,t,l,b,r,p)
|
|
#define HB_GTSELF_REST(g,t,l,b,r,p) (g)->pFuncTable->Rest(g,t,l,b,r,p)
|
|
#define HB_GTSELF_PUTTEXT(g,r,c,m,s,l) (g)->pFuncTable->PutText(g,r,c,m,s,l)
|
|
#define HB_GTSELF_REPLICATE(g,r,c,m,a,u,l) (g)->pFuncTable->Replicate(g,r,c,m,a,u,l)
|
|
#define HB_GTSELF_WRITEAT(g,r,c,s,l) (g)->pFuncTable->WriteAt(g,r,c,s,l)
|
|
#define HB_GTSELF_WRITE(g,s,l) (g)->pFuncTable->Write(g,s,l)
|
|
#define HB_GTSELF_WRITECON(g,s,l) (g)->pFuncTable->WriteCon(g,s,l)
|
|
#define HB_GTSELF_SETATTRIBUTE(g,t,l,b,r,m) (g)->pFuncTable->SetAttribute(g,t,l,b,r,m)
|
|
#define HB_GTSELF_DRAWSHADOW(g,t,l,b,r,m) (g)->pFuncTable->DrawShadow(g,t,l,b,r,m)
|
|
#define HB_GTSELF_SCROLL(g,t,l,b,r,m,u,v,h) (g)->pFuncTable->Scroll(g,t,l,b,r,m,u,v,h)
|
|
#define HB_GTSELF_SCROLLUP(g,r,m,u) (g)->pFuncTable->ScrollUp(g,r,m,u)
|
|
#define HB_GTSELF_BOX(g,t,l,b,r,f,m) (g)->pFuncTable->Box(g,t,l,b,r,f,m)
|
|
#define HB_GTSELF_BOXD(g,t,l,b,r,f,m) (g)->pFuncTable->BoxD(g,t,l,b,r,f,m)
|
|
#define HB_GTSELF_BOXS(g,t,l,b,r,f,m) (g)->pFuncTable->BoxS(g,t,l,b,r,f,m)
|
|
#define HB_GTSELF_HORIZLINE(g,h,l,r,u,m) (g)->pFuncTable->HorizLine(g,h,l,r,u,m)
|
|
#define HB_GTSELF_VERTLINE(g,c,t,b,u,m) (g)->pFuncTable->VertLine(g,c,t,b,u,m)
|
|
#define HB_GTSELF_GETBLINK(g) (g)->pFuncTable->GetBlink(g)
|
|
#define HB_GTSELF_SETBLINK(g,b) (g)->pFuncTable->SetBlink(g,b)
|
|
#define HB_GTSELF_SETSNOWFLAG(g,b) (g)->pFuncTable->SetSnowFlag(g,b)
|
|
#define HB_GTSELF_VERSION(g,i) (g)->pFuncTable->Version(g,i)
|
|
#define HB_GTSELF_SUSPEND(g) (g)->pFuncTable->Suspend(g)
|
|
#define HB_GTSELF_RESUME(g) (g)->pFuncTable->Resume(g)
|
|
#define HB_GTSELF_PREEXT(g) (g)->pFuncTable->PreExt(g)
|
|
#define HB_GTSELF_POSTEXT(g) (g)->pFuncTable->PostExt(g)
|
|
#define HB_GTSELF_OUTSTD(g,s,l) (g)->pFuncTable->OutStd(g,s,l)
|
|
#define HB_GTSELF_OUTERR(g,s,l) (g)->pFuncTable->OutErr(g,s,l)
|
|
#define HB_GTSELF_TONE(g,f,d) (g)->pFuncTable->Tone(g,f,d)
|
|
#define HB_GTSELF_BELL(g) (g)->pFuncTable->Bell(g)
|
|
#define HB_GTSELF_INFO(g,i,p) (g)->pFuncTable->Info(g,i,p)
|
|
#define HB_GTSELF_ALERT(g,m,o,n,h,d) (g)->pFuncTable->Alert(g,m,o,n,h,d)
|
|
#define HB_GTSELF_SETFLAG(g,i,f) (g)->pFuncTable->SetFlag(g,i,f)
|
|
#define HB_GTSELF_SETDISPCP(g,t,h,b) (g)->pFuncTable->SetDispCP(g,t,h,b)
|
|
#define HB_GTSELF_SETKEYCP(g,t,h) (g)->pFuncTable->SetKeyCP(g,t,h)
|
|
#define HB_GTSELF_READKEY(g,m) (g)->pFuncTable->ReadKey(g,m)
|
|
#define HB_GTSELF_INKEYGET(g,w,d,m) (g)->pFuncTable->InkeyGet(g,w,d,m)
|
|
#define HB_GTSELF_INKEYPUT(g,k) (g)->pFuncTable->InkeyPut(g,k)
|
|
#define HB_GTSELF_INKEYINS(g,k) (g)->pFuncTable->InkeyIns(g,k)
|
|
#define HB_GTSELF_INKEYLAST(g,m) (g)->pFuncTable->InkeyLast(g,m)
|
|
#define HB_GTSELF_INKEYNEXT(g,m) (g)->pFuncTable->InkeyNext(g,m)
|
|
#define HB_GTSELF_INKEYPOLL(g) (g)->pFuncTable->InkeyPoll(g)
|
|
#define HB_GTSELF_INKEYSETTEXT(g,s,l) (g)->pFuncTable->InkeySetText(g,s,l)
|
|
#define HB_GTSELF_INKEYSETLAST(g,k) (g)->pFuncTable->InkeySetLast(g,k)
|
|
#define HB_GTSELF_INKEYRESET(g) (g)->pFuncTable->InkeyReset(g)
|
|
#define HB_GTSELF_INKEYEXIT(g) (g)->pFuncTable->InkeyExit(g)
|
|
#define HB_GTSELF_MOUSEINIT(g) (g)->pFuncTable->MouseInit(g)
|
|
#define HB_GTSELF_MOUSEEXIT(g) (g)->pFuncTable->MouseExit(g)
|
|
#define HB_GTSELF_MOUSEISPRESENT(g) (g)->pFuncTable->MouseIsPresent(g)
|
|
#define HB_GTSELF_MOUSESHOW(g) (g)->pFuncTable->MouseShow(g)
|
|
#define HB_GTSELF_MOUSEHIDE(g) (g)->pFuncTable->MouseHide(g)
|
|
#define HB_GTSELF_MOUSEGETCURSOR(g) (g)->pFuncTable->MouseGetCursor(g)
|
|
#define HB_GTSELF_MOUSESETCURSOR(g,v) (g)->pFuncTable->MouseSetCursor(g,v)
|
|
#define HB_GTSELF_MOUSECOL(g) (g)->pFuncTable->MouseCol(g)
|
|
#define HB_GTSELF_MOUSEROW(g) (g)->pFuncTable->MouseRow(g)
|
|
#define HB_GTSELF_MOUSEGETPOS(g,pr,pc) (g)->pFuncTable->MouseGetPos(g,pr,pc)
|
|
#define HB_GTSELF_MOUSESETPOS(g,r,c) (g)->pFuncTable->MouseSetPos(g,r,c)
|
|
#define HB_GTSELF_MOUSESETBOUNDS(g,t,l,b,r) (g)->pFuncTable->MouseSetBounds(g,t,l,b,r)
|
|
#define HB_GTSELF_MOUSEGETBOUNDS(g,t,l,b,r) (g)->pFuncTable->MouseGetBounds(g,t,l,b,r)
|
|
#define HB_GTSELF_MOUSESTORAGESIZE(g) (g)->pFuncTable->MouseStorageSize(g)
|
|
#define HB_GTSELF_MOUSESAVESTATE(g,p) (g)->pFuncTable->MouseSaveState(g,p)
|
|
#define HB_GTSELF_MOUSERESTORESTATE(g,p) (g)->pFuncTable->MouseRestoreState(g,p)
|
|
#define HB_GTSELF_MOUSEGETDOUBLECLICKSPEED(g) (g)->pFuncTable->MouseGetDoubleClickSpeed(g)
|
|
#define HB_GTSELF_MOUSESETDOUBLECLICKSPEED(g,i) (g)->pFuncTable->MouseSetDoubleClickSpeed(g,i)
|
|
#define HB_GTSELF_MOUSECOUNTBUTTON(g) (g)->pFuncTable->MouseCountButton(g)
|
|
#define HB_GTSELF_MOUSEBUTTONSTATE(g,b) (g)->pFuncTable->MouseButtonState(g,b)
|
|
#define HB_GTSELF_MOUSEBUTTONPRESSED(g,b,r,c) (g)->pFuncTable->MouseButtonPressed(g,b,r,c)
|
|
#define HB_GTSELF_MOUSEBUTTONRELEASED(g,b,r,c) (g)->pFuncTable->MouseButtonReleased(g,b,r,c)
|
|
#define HB_GTSELF_MOUSEREADKEY(g,m) (g)->pFuncTable->MouseReadKey(g,m)
|
|
#define HB_GTSELF_GFXPRIMITIVE(g,i,t,l,b,r,c) (g)->pFuncTable->GfxPrimitive(g,i,t,l,b,r,c)
|
|
#define HB_GTSELF_GFXTEXT(g,t,l,s,c,h,w) (g)->pFuncTable->GfxText(g,t,l,s,c,h,w)
|
|
#define HB_GTSELF_WHOCARES(g,p) (g)->pFuncTable->WhoCares(g,p)
|
|
|
|
#ifndef HB_GTSUPERTABLE
|
|
# define HB_GTSUPERTABLE(g) HB_GTSUPER
|
|
#endif
|
|
|
|
#define HB_GTSUPER_LOCK(g) (HB_GTSUPERTABLE(g))->Lock(g)
|
|
#define HB_GTSUPER_UNLOCK(g) (HB_GTSUPERTABLE(g))->Unlock(g)
|
|
#define HB_GTSUPER_INIT(g,i,o,e) (HB_GTSUPERTABLE(g))->Init(g,i,o,e)
|
|
#define HB_GTSUPER_EXIT(g) (HB_GTSUPERTABLE(g))->Exit(g)
|
|
#define HB_GTSUPER_NEW(g) (HB_GTSUPERTABLE(g))->New(g)
|
|
#define HB_GTSUPER_FREE(g) (HB_GTSUPERTABLE(g))->Free(g)
|
|
#define HB_GTSUPER_RESIZE(g,r,c) (HB_GTSUPERTABLE(g))->Resize(g,r,c)
|
|
#define HB_GTSUPER_SETMODE(g,r,c) (HB_GTSUPERTABLE(g))->SetMode(g,r,c)
|
|
#define HB_GTSUPER_GETSIZE(g,pr,pc) (HB_GTSUPERTABLE(g))->GetSize(g,pr,pc)
|
|
#define HB_GTSUPER_SEMICOLD(g) (HB_GTSUPERTABLE(g))->SemiCold(g)
|
|
#define HB_GTSUPER_COLDAREA(g,t,l,b,r) (HB_GTSUPERTABLE(g))->ColdArea(g,t,l,b,r)
|
|
#define HB_GTSUPER_EXPOSEAREA(g,t,l,b,r) (HB_GTSUPERTABLE(g))->ExposeArea(g,t,l,b,r)
|
|
#define HB_GTSUPER_SCROLLAREA(g,t,l,b,r,m,u,v,h) (HB_GTSUPERTABLE(g))->ScrollArea(g,t,l,b,r,m,u,v,h)
|
|
#define HB_GTSUPER_TOUCHCELL(g,r,c) (HB_GTSUPERTABLE(g))->TouchCell(g,r,c)
|
|
#define HB_GTSUPER_REDRAW(g,r,c,l) (HB_GTSUPERTABLE(g))->Redraw(g,r,c,l)
|
|
#define HB_GTSUPER_REFRESH(g) (HB_GTSUPERTABLE(g))->Refresh(g)
|
|
#define HB_GTSUPER_FLUSH(g) (HB_GTSUPERTABLE(g))->Flush(g)
|
|
#define HB_GTSUPER_MAXCOL(g) (HB_GTSUPERTABLE(g))->MaxCol(g)
|
|
#define HB_GTSUPER_MAXROW(g) (HB_GTSUPERTABLE(g))->MaxRow(g)
|
|
#define HB_GTSUPER_CHECKPOS(g,r,c,l) (HB_GTSUPERTABLE(g))->CheckPos(g,r,c,l)
|
|
#define HB_GTSUPER_SETPOS(g,r,c) (HB_GTSUPERTABLE(g))->SetPos(g,r,c)
|
|
#define HB_GTSUPER_GETPOS(g,pr,pc) (HB_GTSUPERTABLE(g))->GetPos(g,pr,pc)
|
|
#define HB_GTSUPER_ISCOLOR(g) (HB_GTSUPERTABLE(g))->IsColor(g)
|
|
#define HB_GTSUPER_GETCOLORSTR(g,s) (HB_GTSUPERTABLE(g))->GetColorStr(g,s)
|
|
#define HB_GTSUPER_SETCOLORSTR(g,s) (HB_GTSUPERTABLE(g))->SetColorStr(g,s)
|
|
#define HB_GTSUPER_COLORSELECT(g,c) (HB_GTSUPERTABLE(g))->ColorSelect(g,c)
|
|
#define HB_GTSUPER_GETCOLOR(g) (HB_GTSUPERTABLE(g))->GetColor(g)
|
|
#define HB_GTSUPER_COLORNUM(g,s) (HB_GTSUPERTABLE(g))->ColorNum(g,s)
|
|
#define HB_GTSUPER_COLORSTOSTRING(g,pc,i,ps,n) (HB_GTSUPERTABLE(g))->ColorsToString(g,pc,i,ps,n)
|
|
#define HB_GTSUPER_STRINGTOCOLORS(g,ps,pc,pi) (HB_GTSUPERTABLE(g))->StringToColors(g,ps,pc,pi)
|
|
#define HB_GTSUPER_GETCOLORDATA(g,pc,pn,pi) (HB_GTSUPERTABLE(g))->GetColorData(g,pc,pn,pi)
|
|
#define HB_GTSUPER_GETCLEARCOLOR(g) (HB_GTSUPERTABLE(g))->GetClearColor(g)
|
|
#define HB_GTSUPER_SETCLEARCOLOR(g,c) (HB_GTSUPERTABLE(g))->SetClearColor(g,c)
|
|
#define HB_GTSUPER_GETCLEARCHAR(g) (HB_GTSUPERTABLE(g))->GetClearChar(g)
|
|
#define HB_GTSUPER_SETCLEARCHAR(g,c) (HB_GTSUPERTABLE(g))->SetClearChar(g,c)
|
|
#define HB_GTSUPER_GETCURSORSTYLE(g) (HB_GTSUPERTABLE(g))->GetCursorStyle(g)
|
|
#define HB_GTSUPER_SETCURSORSTYLE(g,s) (HB_GTSUPERTABLE(g))->SetCursorStyle(g,s)
|
|
#define HB_GTSUPER_GETSCRCURSOR(g,pr,pc,ps) (HB_GTSUPERTABLE(g))->GetScrCursor(g,pr,pc,ps)
|
|
#define HB_GTSUPER_GETSCRCHAR(g,r,c,pm,pa,pc) (HB_GTSUPERTABLE(g))->GetScrChar(g,r,c,pm,pa,pc)
|
|
#define HB_GTSUPER_PUTSCRCHAR(g,r,c,m,a,u) (HB_GTSUPERTABLE(g))->PutScrChar(g,r,c,m,a,u)
|
|
#define HB_GTSUPER_DISPBEGIN(g) (HB_GTSUPERTABLE(g))->DispBegin(g)
|
|
#define HB_GTSUPER_DISPEND(g) (HB_GTSUPERTABLE(g))->DispEnd(g)
|
|
#define HB_GTSUPER_DISPCOUNT(g) (HB_GTSUPERTABLE(g))->DispCount(g)
|
|
#define HB_GTSUPER_GETCHAR(g,r,c,pm,pa,pc) (HB_GTSUPERTABLE(g))->GetChar(g,r,c,pm,pa,pc)
|
|
#define HB_GTSUPER_PUTCHAR(g,r,c,m,a,u) (HB_GTSUPERTABLE(g))->PutChar(g,r,c,m,a,u)
|
|
#define HB_GTSUPER_RECTSIZE(g,t,l,b,r) (HB_GTSUPERTABLE(g))->RectSize(g,t,l,b,r)
|
|
#define HB_GTSUPER_SAVE(g,t,l,b,r,p) (HB_GTSUPERTABLE(g))->Save(g,t,l,b,r,p)
|
|
#define HB_GTSUPER_REST(g,t,l,b,r,p) (HB_GTSUPERTABLE(g))->Rest(g,t,l,b,r,p)
|
|
#define HB_GTSUPER_PUTTEXT(g,r,c,m,s,l) (HB_GTSUPERTABLE(g))->PutText(g,r,c,m,s,l)
|
|
#define HB_GTSUPER_REPLICATE(g,r,c,m,a,u,l) (HB_GTSUPERTABLE(g))->Replicate(g,r,c,m,a,u,l)
|
|
#define HB_GTSUPER_WRITEAT(g,r,c,s,l) (HB_GTSUPERTABLE(g))->WriteAt(g,r,c,s,l)
|
|
#define HB_GTSUPER_WRITE(g,s,l) (HB_GTSUPERTABLE(g))->Write(g,s,l)
|
|
#define HB_GTSUPER_WRITECON(g,s,l) (HB_GTSUPERTABLE(g))->WriteCon(g,s,l)
|
|
#define HB_GTSUPER_SETATTRIBUTE(g,t,l,b,r,m) (HB_GTSUPERTABLE(g))->SetAttribute(g,t,l,b,r,m)
|
|
#define HB_GTSUPER_DRAWSHADOW(g,t,l,b,r,m) (HB_GTSUPERTABLE(g))->DrawShadow(g,t,l,b,r,m)
|
|
#define HB_GTSUPER_SCROLL(g,t,l,b,r,m,u,v,h) (HB_GTSUPERTABLE(g))->Scroll(g,t,l,b,r,m,u,v,h)
|
|
#define HB_GTSUPER_SCROLLUP(g,r,m,u) (HB_GTSUPERTABLE(g))->ScrollUp(g,r,m,u)
|
|
#define HB_GTSUPER_BOX(g,t,l,b,r,f,m) (HB_GTSUPERTABLE(g))->Box(g,t,l,b,r,f,m)
|
|
#define HB_GTSUPER_BOXD(g,t,l,b,r,f,m) (HB_GTSUPERTABLE(g))->BoxD(g,t,l,b,r,f,m)
|
|
#define HB_GTSUPER_BOXS(g,t,l,b,r,f,m) (HB_GTSUPERTABLE(g))->BoxS(g,t,l,b,r,f,m)
|
|
#define HB_GTSUPER_HORIZLINE(g,h,l,r,u,m) (HB_GTSUPERTABLE(g))->HorizLine(g,h,l,r,u,m)
|
|
#define HB_GTSUPER_VERTLINE(g,c,t,b,u,m) (HB_GTSUPERTABLE(g))->VertLine(g,c,t,b,u,m)
|
|
#define HB_GTSUPER_GETBLINK(g) (HB_GTSUPERTABLE(g))->GetBlink(g)
|
|
#define HB_GTSUPER_SETBLINK(g,b) (HB_GTSUPERTABLE(g))->SetBlink(g,b)
|
|
#define HB_GTSUPER_SETSNOWFLAG(g,b) (HB_GTSUPERTABLE(g))->SetSnowFlag(g,b)
|
|
#define HB_GTSUPER_VERSION(g,i) (HB_GTSUPERTABLE(g))->Version(g,i)
|
|
#define HB_GTSUPER_SUSPEND(g) (HB_GTSUPERTABLE(g))->Suspend(g)
|
|
#define HB_GTSUPER_RESUME(g) (HB_GTSUPERTABLE(g))->Resume(g)
|
|
#define HB_GTSUPER_PREEXT(g) (HB_GTSUPERTABLE(g))->PreExt(g)
|
|
#define HB_GTSUPER_POSTEXT(g) (HB_GTSUPERTABLE(g))->PostExt(g)
|
|
#define HB_GTSUPER_OUTSTD(g,s,l) (HB_GTSUPERTABLE(g))->OutStd(g,s,l)
|
|
#define HB_GTSUPER_OUTERR(g,s,l) (HB_GTSUPERTABLE(g))->OutErr(g,s,l)
|
|
#define HB_GTSUPER_TONE(g,f,d) (HB_GTSUPERTABLE(g))->Tone(g,f,d)
|
|
#define HB_GTSUPER_BELL(g) (HB_GTSUPERTABLE(g))->Bell(g)
|
|
#define HB_GTSUPER_INFO(g,i,p) (HB_GTSUPERTABLE(g))->Info(g,i,p)
|
|
#define HB_GTSUPER_ALERT(g,m,o,n,h,d) (HB_GTSUPERTABLE(g))->Alert(g,m,o,n,h,d)
|
|
#define HB_GTSUPER_SETFLAG(g,i,f) (HB_GTSUPERTABLE(g))->SetFlag(g,i,f)
|
|
#define HB_GTSUPER_SETDISPCP(g,t,h,b) (HB_GTSUPERTABLE(g))->SetDispCP(g,t,h,b)
|
|
#define HB_GTSUPER_SETKEYCP(g,t,h) (HB_GTSUPERTABLE(g))->SetKeyCP(g,t,h)
|
|
#define HB_GTSUPER_READKEY(g,m) (HB_GTSUPERTABLE(g))->ReadKey(g,m)
|
|
#define HB_GTSUPER_INKEYGET(g,w,d,m) (HB_GTSUPERTABLE(g))->InkeyGet(g,w,d,m)
|
|
#define HB_GTSUPER_INKEYPUT(g,k) (HB_GTSUPERTABLE(g))->InkeyPut(g,k)
|
|
#define HB_GTSUPER_INKEYINS(g,k) (HB_GTSUPERTABLE(g))->InkeyIns(g,k)
|
|
#define HB_GTSUPER_INKEYLAST(g,m) (HB_GTSUPERTABLE(g))->InkeyLast(g,m)
|
|
#define HB_GTSUPER_INKEYNEXT(g,m) (HB_GTSUPERTABLE(g))->InkeyNext(g,m)
|
|
#define HB_GTSUPER_INKEYPOLL(g) (HB_GTSUPERTABLE(g))->InkeyPoll(g)
|
|
#define HB_GTSUPER_INKEYSETTEXT(g,s,l) (HB_GTSUPERTABLE(g))->InkeySetText(g,s,l)
|
|
#define HB_GTSUPER_INKEYSETLAST(g,k) (HB_GTSUPERTABLE(g))->InkeySetLast(g,k)
|
|
#define HB_GTSUPER_INKEYRESET(g) (HB_GTSUPERTABLE(g))->InkeyReset(g)
|
|
#define HB_GTSUPER_INKEYEXIT(g) (HB_GTSUPERTABLE(g))->InkeyExit(g)
|
|
#define HB_GTSUPER_MOUSEINIT(g) (HB_GTSUPERTABLE(g))->MouseInit(g)
|
|
#define HB_GTSUPER_MOUSEEXIT(g) (HB_GTSUPERTABLE(g))->MouseExit(g)
|
|
#define HB_GTSUPER_MOUSEISPRESENT(g) (HB_GTSUPERTABLE(g))->MouseIsPresent(g)
|
|
#define HB_GTSUPER_MOUSESHOW(g) (HB_GTSUPERTABLE(g))->MouseShow(g)
|
|
#define HB_GTSUPER_MOUSEHIDE(g) (HB_GTSUPERTABLE(g))->MouseHide(g)
|
|
#define HB_GTSUPER_MOUSEGETCURSOR(g) (HB_GTSUPERTABLE(g))->MouseGetCursor(g)
|
|
#define HB_GTSUPER_MOUSESETCURSOR(g,v) (HB_GTSUPERTABLE(g))->MouseSetCursor(g,v)
|
|
#define HB_GTSUPER_MOUSECOL(g) (HB_GTSUPERTABLE(g))->MouseCol(g)
|
|
#define HB_GTSUPER_MOUSEROW(g) (HB_GTSUPERTABLE(g))->MouseRow(g)
|
|
#define HB_GTSUPER_MOUSEGETPOS(g,pr,pc) (HB_GTSUPERTABLE(g))->MouseGetPos(g,pr,pc)
|
|
#define HB_GTSUPER_MOUSESETPOS(g,r,c) (HB_GTSUPERTABLE(g))->MouseSetPos(g,r,c)
|
|
#define HB_GTSUPER_MOUSESETBOUNDS(g,t,l,b,r) (HB_GTSUPERTABLE(g))->MouseSetBounds(g,t,l,b,r)
|
|
#define HB_GTSUPER_MOUSEGETBOUNDS(g,t,l,b,r) (HB_GTSUPERTABLE(g))->MouseGetBounds(g,t,l,b,r)
|
|
#define HB_GTSUPER_MOUSESTORAGESIZE(g) (HB_GTSUPERTABLE(g))->MouseStorageSize(g)
|
|
#define HB_GTSUPER_MOUSESAVESTATE(g,p) (HB_GTSUPERTABLE(g))->MouseSaveState(g,p)
|
|
#define HB_GTSUPER_MOUSERESTORESTATE(g,p) (HB_GTSUPERTABLE(g))->MouseRestoreState(g,p)
|
|
#define HB_GTSUPER_MOUSEGETDOUBLECLICKSPEED(g) (HB_GTSUPERTABLE(g))->MouseGetDoubleClickSpeed(g)
|
|
#define HB_GTSUPER_MOUSESETDOUBLECLICKSPEED(g,i) (HB_GTSUPERTABLE(g))->MouseSetDoubleClickSpeed(g,i)
|
|
#define HB_GTSUPER_MOUSECOUNTBUTTON(g) (HB_GTSUPERTABLE(g))->MouseCountButton(g)
|
|
#define HB_GTSUPER_MOUSEBUTTONSTATE(g,b) (HB_GTSUPERTABLE(g))->MouseButtonState(g,b)
|
|
#define HB_GTSUPER_MOUSEBUTTONPRESSED(g,b,r,c) (HB_GTSUPERTABLE(g))->MouseButtonPressed(g,b,r,c)
|
|
#define HB_GTSUPER_MOUSEBUTTONRELEASED(g,b,r,c) (HB_GTSUPERTABLE(g))->MouseButtonReleased(g,b,r,c)
|
|
#define HB_GTSUPER_MOUSEREADKEY(g,m) (HB_GTSUPERTABLE(g))->MouseReadKey(g,m)
|
|
#define HB_GTSUPER_GFXPRIMITIVE(g,i,t,l,b,r,c) (HB_GTSUPERTABLE(g))->GfxPrimitive(g,i,t,l,b,r,c)
|
|
#define HB_GTSUPER_GFXTEXT(g,t,l,s,c,h,w) (HB_GTSUPERTABLE(g))->GfxText(g,t,l,s,c,h,w)
|
|
#define HB_GTSUPER_WHOCARES(g,p) (HB_GTSUPERTABLE(g))->WhoCares(g,p)
|
|
|
|
extern HB_EXPORT void hb_gtSetDefault( const char * szGtName );
|
|
extern HB_EXPORT BOOL hb_gtRegister( const HB_GT_INIT * gtInit );
|
|
extern HB_EXPORT PHB_GT hb_gtLoad( const char * szGtName, PHB_GT pGT, PHB_GT_FUNCS pSuperTable );
|
|
|
|
/* low level GT functions common to different GTs supported by RTL */
|
|
extern int hb_gt_chrmapinit( int *piTransTbl, const char *pszTerm, BOOL fSetACSC );
|
|
extern BOOL hb_gt_setClipboard( const char * szClipData, ULONG ulLen );
|
|
extern BOOL hb_gt_getClipboard( char ** pszClipData, ULONG *pulLen );
|
|
#if defined( HB_OS_WIN_32 )
|
|
extern BOOL hb_gt_w32_setClipboard( UINT uFormat, const char * szClipData, ULONG ulLen );
|
|
extern BOOL hb_gt_w32_getClipboard( UINT uFormat, char ** pszClipData, ULONG *pulLen );
|
|
extern int hb_gt_w32_getKbdState( void );
|
|
extern void hb_gt_w32_setKbdState( int kbdShifts );
|
|
extern void hb_gt_w32_tone( double dFrequency, double dDuration );
|
|
#endif /* HB_OS_WIN_32 */
|
|
#if defined( HB_OS_DOS ) || defined( HB_OS_WIN_32 ) || defined( HB_OS_OS2 )
|
|
extern int hb_gt_dos_keyCodeTranslate( int iKey );
|
|
#endif /* HB_OS_DOS || HB_OS_WIN_32 || HB_OS_OS2 */
|
|
|
|
HB_EXTERN_END
|
|
|
|
#endif /* HB_GTCORE_H_ */
|