Files
harbour-core/harbour/tests/wcecon.prg
Viktor Szakats 46f7e48f29 2010-07-26 12:34 UTC+0200 Viktor Szakats (harbour.01 syenar.hu)
* contrib/hbqt/tests/wvtqt.hbp
  * contrib/hbxbp/tests/wvtqt.hbp
    ! Added missing SVN header.
    % Cleanup.

  * INSTALL
  * contrib/hbpost.hbm
  * config/global.mk
    * Changed HB_BUILD_IMPLIB to HB_INSTALL_IMPLIB to reflect
      new meaning after recent changes. With new build system
      the implibs are always created in lib working dir, and
      this setting only controls whether to copy it to final
      install directory. The default is still 'no'. Setting it
      to yes is only recommended if the installation will be
      used in local environment (3rd party .dlls) only. IOW
      never set this to yes when creating a build for other
      users (f.e. for distribution).
      INCOMPATIBLE if you used this setting, pls change it now.

  * INSTALL
    + Documented HB_STATIC_* options.

  * contrib/make.hbs
    * Updated TODO list.

  * src/debug/debugger.prg
  * src/rtl/dirscan.prg
  * tests/wcecon.prg
  * contrib/xhb/traceprg.prg
  * contrib/hbqt/tests/wvtqt.hbp
  * contrib/hbqt/generator2/hbqtgen2.prg
  * contrib/hbxbp/tests/demoxbp.prg
  * contrib/hbxbp/tests/dialogqt.prg
  * contrib/hbxbp/tests/wvtqt.hbp
  * contrib/hbhpdf/tests/harupdf.prg
  * contrib/gtwvg/tests/wvgtbrowser.prg
  * contrib/gtwvg/tests/wvgwvtclasses.prg
  * contrib/hbtip/tests/dbtohtml.prg
  * contrib/hbtip/mail.prg
  * contrib/hbide/idemisc.prg
  * contrib/hbide/ideactions.prg
  * contrib/hbide/idetools.prg
  * contrib/hbide/idesources.prg
  * contrib/hbide/hbide.prg
  * examples/uhttpd2/umain.prg
  * examples/hbvpdf/tests/pdf_demo.prg
  * examples/httpsrv/uhttpd.prg
  * examples/httpsrv/cgifunc.prg
  * examples/httpsrv/modules/tableservletdb.prg
  * examples/httpsrv/session.prg
    * HB_OSPATHSEPARATOR() -> HB_PS()
    % Delete temp vars along the way.

  * utils/hbmk2/hbmk2.prg
    + Generalized internals for support for older Harbour and
      xhb versions.
    + Added -hb20 option. (thanks for asking for it so nicely ;)
2010-07-26 10:36:23 +00:00

104 lines
2.5 KiB
Plaintext

/*
* $Id$
*/
/*
* Harbour Project source code:
* demonstration/test code for WinCE console program
*
* Copyright 2007 Przemyslaw Czerpak <druzus / at / priv.onet.pl>
* www - http://harbour-project.org
*
*/
#include "hbgtinfo.ch"
request DBFCDX
proc main()
field F1, F2, FX
local nMaxScrRow, nMaxScrCol
local cPath, cName, cExt, cDrive
local i, j, k
/* set OEM font encoding for non unicode modes */
hb_gtInfo( HB_GTI_CODEPAGE, 255 )
/* Set EN CP-437 encoding */
hb_cdpSelect( "EN" )
hb_setTermCP( "EN" )
/* Set font size */
hb_gtInfo( HB_GTI_FONTWIDTH, 6 )
hb_gtInfo( HB_GTI_FONTSIZE, 12 )
/* resize console window using new font size */
SetMode( MaxRow() + 1, MaxCol() + 1 )
/* get screen dimensions */
nMaxScrRow := hb_gtInfo( HB_GTI_DESKTOPROWS )
nMaxScrCol := hb_gtInfo( HB_GTI_DESKTOPCOLS )
/* resize console window to the screen size */
SetMode( nMaxScrRow, nMaxScrCol )
/* display console window size */
? "rows =", ltrim( str( maxrow() + 1 ) )
? "cols =", ltrim( str( maxcol() + 1 ) )
inkey( 0 )
/* display infomration aboout used OS, harbour version and GT driver */
alert( OS() + ";" + Version() + ";" + hb_gtVersion() )
/* database test */
hb_FNameSplit( hb_argv( 0 ), @cPath, @cName, @cExt, @cDrive )
cPath += "data" + hb_ps()
Alert( "Database path:;;" + cPath )
rddSetDefault("DBFCDX")
if !hb_dirExists( cPath )
MakeDir( cPath )
endif
dbCreate( cPath + "mydata", { { "F1", "C", 10, 0 }, ;
{ "F2", "=", 8, 0 }, ;
{ "FX", "M", 4, 0 } } )
use ( cPath+"mydata" )
index on F1 tag T1
index on F2 tag T2
while lastrec() < 10
dbappend()
F1 := "rec:" + str( recno(), 3 )
FX := "[rec:" + str( recno(), 3 ) + "]"
enddo
dbCommit()
dbGoTop()
browse()
/* display all characters */
CLS
for i := 0 to 15
for j := 0 to 15
dispout( " " + chr( i * 16 + j ) )
next
?
next
inkey( 0 )
/* display boxes */
?; devout( "ÚÄÂÄ¿ ÉÍËÍ» ÕÍÑ͸ ÖÄÒÄ· ÜÜÜ" )
?; devout( "³ ³ ³ º º º ÃÄÅÄ´ ÇÄ×Ķ ÝþÞ" )
?; devout( "ÃÄÅÄ´ ÌÍÎ͹ ³ ³ ³ º º º ÝÛÞ" )
?; devout( "³ ³ ³ º º º ÆÍØÍµ ÌÍÎ͹ ÝþÞ" )
?; devout( "ÀÄÁÄÙ ÈÍÊͼ ÔÍÏ; ÓÄÐĽ ßßß" )
inkey( 0 )
?
? "@ - interrupt, keycodes test "
while ( k := inkey( 0 ) ) != 64
? ; devout( "key=" + str( k, 4 ) + ", char='" + chr( k ) + "'" )
enddo
return