See changelog 2000-08-12 20:20 GMt -3
This commit is contained in:
@@ -325,7 +325,7 @@
|
||||
* $FUNCNAME$
|
||||
* dbSkipper()
|
||||
* $CATEGORY$
|
||||
* Data base
|
||||
* Database
|
||||
* $ONELINER$
|
||||
* Helper function to skip a database
|
||||
* $SYNTAX$
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
* Compiler Options
|
||||
* $DESCRIPTION$
|
||||
*
|
||||
* Invoking the Harbour compiler: </par>
|
||||
* <b>Invoking the Harbour compiler: </b> </par>
|
||||
* ============================== </par>
|
||||
*
|
||||
* harbour <file[.prg]> [options] </par>
|
||||
@@ -20,185 +20,208 @@
|
||||
* or </par>
|
||||
* harbour [options] <file[.prg]> [options] </par>
|
||||
*
|
||||
*
|
||||
* The command line options have to be separated by at least one space.
|
||||
* The option can start with either '/' character or '-' character. </par>
|
||||
* The option can start with either '/' character or '-' character.
|
||||
*
|
||||
* The Harbour command line options: </par>
|
||||
* <b>The Harbour command line options: </b> </par>
|
||||
* ================================= </par>
|
||||
*
|
||||
* /a automatic memvar declaration </par>
|
||||
* ----------------- </par>
|
||||
* ================= </par>
|
||||
|
||||
* This causes all variables declared by PARAMETER, PRIVATE or PUBLIC
|
||||
* statements to be automatically declared as MEMVAR variables. </par>
|
||||
* statements to be automatically declared as MEMVAR variables.
|
||||
*
|
||||
* /b debug info </par>
|
||||
* ----------------- </par>
|
||||
* The compiler generates all information required for debugging </par>
|
||||
* ================= </par>
|
||||
|
||||
* The compiler generates all information required for debugging
|
||||
*
|
||||
* /d<id>[=<val>] #define <id> </par>
|
||||
* ----------------- </par>
|
||||
* ================= </par>
|
||||
*
|
||||
* /es[<level>] set exit severity </par>
|
||||
* ----------------- </par>
|
||||
* ================= </par>
|
||||
*
|
||||
* /es or /es0 - all warnings are ignored and exit code returned by
|
||||
* /es or /es0 = all warnings are ignored and exit code returned by
|
||||
* the compiler (accessed by DOS ERRORLEVEL command)
|
||||
* is equal to 0 if there are no errors in compiled
|
||||
* source file. </par>
|
||||
* /es1 - any warnings generate a non-zero exit code, but
|
||||
* output is still created. </par>
|
||||
* /es2 - all warnings are treated as errors and no output
|
||||
* file is created. The exit code is set to a non-zero
|
||||
* value. </par>
|
||||
* source file.
|
||||
*
|
||||
* /es1 = any warnings generate a non=zero exit code, but
|
||||
* output is still created.
|
||||
*
|
||||
* /es2 = all warnings are treated as errors and no output
|
||||
* file is created. The exit code is set to a non=zero
|
||||
* value.
|
||||
*
|
||||
* /g<type> output type generated is <type> </par>
|
||||
* ----------------- </par>
|
||||
* ================= </par>
|
||||
*
|
||||
* /gc output type: C source (.c) (default) </par>
|
||||
* /gf output type: Windows/DOS OBJ32 (.obj) </par>
|
||||
* /gh output type: Harbour Portable Object (.hrb) </par>
|
||||
* /gj output type: Java source (.java) </par>
|
||||
* /gp output type: Pascal source (.pas) </par>
|
||||
* /gr output type: Windows resource (.rc) </par>
|
||||
* /gc output type: C source (.c) (default)
|
||||
*
|
||||
* /gf output type: Windows/DOS OBJ32 (.obj)
|
||||
*
|
||||
* /gh output type: Harbour Portable Object (.hrb)
|
||||
*
|
||||
* /gj output type: Java source (.java)
|
||||
*
|
||||
* /gp output type: Pascal source (.pas)
|
||||
*
|
||||
* /gr output type: Windows resource (.rc)
|
||||
*
|
||||
* /i<path> add #include file search path </par>
|
||||
* ----------------- </par>
|
||||
* ================= </par>
|
||||
*
|
||||
* /l suppress line number information </par>
|
||||
* ----------------- </par>
|
||||
* ================= </par>
|
||||
*
|
||||
* The compiler does not generate the source code line numbers in
|
||||
* the output file. The PROCLINE() function will return 0 for
|
||||
* modules compiled using this option. </par>
|
||||
* modules compiled using this option.
|
||||
*
|
||||
* /m compile current module only </par>
|
||||
* ----------------- </par>
|
||||
* ================= </par>
|
||||
*
|
||||
* /n no implicit starting procedure </par>
|
||||
* ----------------- </par>
|
||||
* ================= </par>
|
||||
*
|
||||
* The compiler does not create a procedure with the same name as
|
||||
* the compiled file. This means that any declarations placed
|
||||
* before the first PROCEDURE or FUNCTION statement have file-
|
||||
* before the first PROCEDURE or FUNCTION statement have file=
|
||||
* wide scope and can be accessed/used in all functions/procedures
|
||||
* defined in the compiled source file. All executable statements
|
||||
* placed at the beginning of the file and before the first
|
||||
* PROCEDURE/FUNCTION statement are ignored. </par>
|
||||
* PROCEDURE/FUNCTION statement are ignored.
|
||||
*
|
||||
* /o<path> output file drive and/or path </par>
|
||||
* ----------------- </par>
|
||||
* ================= </par>
|
||||
*
|
||||
* /p generate pre=processed output (.ppo) file </par>
|
||||
* ================= </par>
|
||||
*
|
||||
* /p generate pre-processed output (.ppo) file </par>
|
||||
* ----------------- </par>
|
||||
* The compiler only creates the file that contains the result of
|
||||
* pre-processing the source file. </par>
|
||||
* pre=processing the source file.
|
||||
*
|
||||
* /q quiet </par>
|
||||
* ----------------- </par>
|
||||
* The compiler does not print any messages during compiling
|
||||
* (except the copyright info). </par>
|
||||
* ================= </par>
|
||||
*
|
||||
* /q0 be really quiet and don't display even the copyright info </par>
|
||||
* The compiler does not print any messages during compiling
|
||||
* (except the copyright info).
|
||||
*
|
||||
* /q0 be really quiet and don't display even the copyright info
|
||||
*
|
||||
* /r[<lib>] request linker to search <lib> (or none) </par>
|
||||
* ----------------- </par>
|
||||
* Currently not supported in Harbour. </par>
|
||||
* ================= </par>
|
||||
*
|
||||
* Currently not supported in Harbour.
|
||||
*
|
||||
* /s syntax check only </par>
|
||||
* ----------------- </par>
|
||||
* The compiler checks the syntax only. No output file is generated. </par>
|
||||
* ================= </par>
|
||||
*
|
||||
* The compiler checks the syntax only. No output file is generated.
|
||||
*
|
||||
* /t<path> path for temp file creation </par>
|
||||
* ----------------- </par>
|
||||
* ================= </par>
|
||||
*
|
||||
* Currently not used in Harbour (the Harbour compiler does not
|
||||
* create any temporary files). </par>
|
||||
* create any temporary files).
|
||||
*
|
||||
* /u[<file>] use command definition set in <file> (or none) </par>
|
||||
* ----------------- </par>
|
||||
* ================= </par>
|
||||
*
|
||||
* /v variables are assumed M=> </par>
|
||||
* ================= </par>
|
||||
*
|
||||
* /v variables are assumed M-> </par>
|
||||
* ----------------- </par>
|
||||
* All undeclared or unaliased variables are assumed MEMVAR
|
||||
* variables (private or public variables). If this switch is not
|
||||
* used then the scope of such variables is checked at runtime. </par>
|
||||
* used then the scope of such variables is checked at runtime.
|
||||
*
|
||||
* /w[<level>] set warning level number (0..4, default 1) </par>
|
||||
* ----------------- </par>
|
||||
* ================= </par>
|
||||
*
|
||||
* /w0 - no warnings </par>
|
||||
* /w or /w1 - Clipper compatible warnings </par>
|
||||
* /w2 - some useful warnings missed in Clipper </par>
|
||||
* /w3 - warnings generated for Harbour language extensions
|
||||
* /w0 = no warnings
|
||||
*
|
||||
* /w or /w1 = Clipper compatible warnings
|
||||
*
|
||||
* /w2 = some useful warnings missed in Clipper
|
||||
*
|
||||
* /w3 = warnings generated for Harbour language extensions
|
||||
* and also enables strong type checking but only
|
||||
* warns against declared types, or types which may be
|
||||
* calculated at compile time </par>
|
||||
* /w4 - Enables warning about suspicious operations, which
|
||||
* calculated at compile time
|
||||
*
|
||||
* /w4 = Enables warning about suspicious operations, which
|
||||
* means if you mix undeclared types, or types which
|
||||
* can not be calculated at compile time,together with
|
||||
* declared types, a warning will be generated. </par>
|
||||
* declared types, a warning will be generated.
|
||||
*
|
||||
* /x[<prefix>] set symbol init function name prefix (for .c only) </par>
|
||||
* ----------------- </par>
|
||||
* ================= </par>
|
||||
*
|
||||
* Sets the prefix added to the generated symbol init function name
|
||||
* (in C output currently). This function is generated
|
||||
* automatically for every PRG module compiled. This additional
|
||||
* prefix can be used to suppress problems with duplicated symbols
|
||||
* during linking an application with some third party libraries. </par>
|
||||
* during linking an application with some third party libraries.
|
||||
*
|
||||
* /y trace lex & yacc activity </par>
|
||||
* ----------------- </par>
|
||||
* ================= </par>
|
||||
*
|
||||
* The Harbour compiler uses the FLEX and YACC utilities to parse
|
||||
* the source code and to generate the required output file. This
|
||||
* option traces the activity of these utilities. </par>
|
||||
* option traces the activity of these utilities.
|
||||
*
|
||||
* /z suppress logical shortcutting (.and. & .or.) </par>
|
||||
* ----------------- </par>
|
||||
* ================= </par>
|
||||
*
|
||||
* /10 restrict symbol length to 10 characters </par>
|
||||
* ----------------- </par>
|
||||
* All variable and function names are cut to maximum 10 characters. </par>
|
||||
* ================= </par>
|
||||
*
|
||||
* All variable and function names are cut to maximum 10 characters.
|
||||
*
|
||||
* Compilation in batch mode. </par>
|
||||
* ========================== </par>
|
||||
*
|
||||
* @<file> compile list of modules in <file> </par>
|
||||
* ----------------- </par>
|
||||
* Not supported yet. </par>
|
||||
* ================= </par>
|
||||
*
|
||||
* Not supported yet.
|
||||
*
|
||||
*
|
||||
* Known incompatibilities between harbour and clipper compilers </par>
|
||||
* <b>Known incompatibilities between harbour and clipper compilers </b> </par>
|
||||
* ============================================================= </par>
|
||||
*
|
||||
* NOTE: </par>
|
||||
* If you want a 100% compatible compile and runtime libraries then
|
||||
*
|
||||
* If you want a 100% compatible compile and runtime libraries then
|
||||
* you have to define HARBOUR_STRICT_CLIPPER_COMPATIBILITY. This
|
||||
* option should be defined in the file include/hbsetup.h (in fact this
|
||||
* option is placed in a comment by default - you need to remove the
|
||||
* option is placed in a comment by default = you need to remove the
|
||||
* /* */ characters only). This change has to be done before invoking
|
||||
* the make utility. </par>
|
||||
* the make utility.
|
||||
*
|
||||
*
|
||||
* Handling of undeclared variables </par>
|
||||
* -------------------------------- </par>
|
||||
* When a value is assigned to an undeclared variable and the '-v'
|
||||
* <b>Handling of undeclared variables </b> </par>
|
||||
* ================================ </par>
|
||||
*
|
||||
* When a value is assigned to an undeclared variable and the '=v'
|
||||
* command line option is not used, then the Clipper compiler assumes
|
||||
* that the variable is a PRIVATE or a PUBLIC variable and generates
|
||||
* POPM (pop memvar) opcode. </par>
|
||||
* POPM (pop memvar) opcode.
|
||||
*
|
||||
* When the value of an undeclared variable is accessed and the '-v'
|
||||
* When the value of an undeclared variable is accessed and the '=v'
|
||||
* command line option is not used, the Clipper compiler generates PUSHV
|
||||
* (push variable) opcode that determines the type of variable at runtime.
|
||||
* If a field with the requested name exists in the current workarea then
|
||||
* its value is used. If there is no field then a PRIVATE or a PUBLIC
|
||||
* variable is used (if exists). </par>
|
||||
* variable is used (if exists).
|
||||
*
|
||||
* The Harbour compiler generates an opcode to determine the type of
|
||||
* The Harbour compiler generates an opcode to determine the type of
|
||||
* variable at runtime (POPVARIABLE or PUSHVARIABLE) in both cases
|
||||
* (assignment and access). </par>
|
||||
* (assignment and access).
|
||||
*
|
||||
* The difference can be checked by the following code:
|
||||
*
|
||||
* The difference can be checked by the following code: </par>
|
||||
|
||||
* <fixed>
|
||||
* PROCEDURE MAIN()
|
||||
* PRIVATE myname
|
||||
@@ -208,71 +231,73 @@
|
||||
* SELECT test
|
||||
* APPEND BLANK
|
||||
*
|
||||
* FIELD->myname := "FIELD"
|
||||
* MEMVAR->myname := "MEMVAR"
|
||||
* FIELD=>myname := "FIELD"
|
||||
* MEMVAR=>myname := "MEMVAR"
|
||||
*
|
||||
* myname := myname + " assigned"
|
||||
*
|
||||
* // In Clipper: "FIELD", In Harbour: "FIELD assigned"
|
||||
* ? FIELD->myname
|
||||
* ? FIELD=>myname
|
||||
*
|
||||
* // In Clipper: "MEMVAR assigned", In Harbour: "MEMVAR"
|
||||
* ? MEMVAR->myname
|
||||
* ? MEMVAR=>myname
|
||||
*
|
||||
* USE
|
||||
*
|
||||
* RETURN
|
||||
* </fixed>
|
||||
*
|
||||
* Passing an undeclared variable by the reference </par>
|
||||
* ----------------------------------------------- </par>
|
||||
* The Clipper compiler uses the special opcode PUSHP to pass a
|
||||
* <b>Passing an undeclared variable by the reference </b> </par>
|
||||
* =============================================== </par>
|
||||
*
|
||||
* The Clipper compiler uses the special opcode PUSHP to pass a
|
||||
* reference to an undeclared variable ( '@' operator ). The type of
|
||||
* passed variable is checked at runtime (field or memvar). However,
|
||||
* field variables cannot be passed by reference. This means that
|
||||
* Clipper checks the memvar variable only and doesn't look for a field.
|
||||
* This is the reason why the Harbour compiler uses the usual
|
||||
* PUSHMEMVARREF opcode in such cases. Notice that the runtime behavior
|
||||
* is the same in Clipper and in Harbour - only the generated opcodes
|
||||
* are different. </par>
|
||||
* is the same in Clipper and in Harbour = only the generated opcodes
|
||||
* are different.
|
||||
*
|
||||
*
|
||||
* Handling of object messages </par>
|
||||
* --------------------------- </par>
|
||||
* =========================== </par>
|
||||
*
|
||||
* The HARBOUR_STRICT_CLIPPER_COMPATIBILITY setting determines
|
||||
* the way chained send messages are handled. </par>
|
||||
* the way chained send messages are handled.
|
||||
*
|
||||
* For example, the following code: </par>
|
||||
* For example, the following code:
|
||||
*
|
||||
* a:b( COUNT() ):c += 1 </par>
|
||||
* a:b( COUNT() ):c += 1
|
||||
*
|
||||
* will be handled as: </par>
|
||||
* will be handled as:
|
||||
*
|
||||
* a:b( COUNT() ):c := a:b( COUNT() ):c + 1 </par>
|
||||
* a:b( COUNT() ):c := a:b( COUNT() ):c + 1
|
||||
*
|
||||
* in strict Clipper compatibility mode and </par>
|
||||
* in strict Clipper compatibility mode and
|
||||
*
|
||||
* temp := a:b( COUNT() ), temp:c += 1 </par>
|
||||
* temp := a:b( COUNT() ), temp:c += 1
|
||||
*
|
||||
* in non-strict mode. </par>
|
||||
* in non=strict mode.
|
||||
*
|
||||
* In practice, Clipper will call the COUNT() function two times:
|
||||
* In practice, Clipper will call the COUNT() function two times:
|
||||
* the first time before addition and the second one after addition.
|
||||
* In Harbour, COUNT() will be called only once, before addition. </par>
|
||||
* In Harbour, COUNT() will be called only once, before addition.
|
||||
*
|
||||
* The Harbour (non-strict) method is: </par>
|
||||
* The Harbour (non=strict) method is: </par>
|
||||
* 1) faster </par>
|
||||
* 2) it guarantees that the same instance variable of the same object
|
||||
* will be changed </par>
|
||||
* will be changed
|
||||
*
|
||||
* (See also: source/compiler/expropt.c) </par>
|
||||
* (See also: source/compiler/expropt.c)
|
||||
*
|
||||
* Initialization of static variables </par>
|
||||
* ---------------------------------- </par>
|
||||
* <b>Initialization of static variables </b></par>
|
||||
* ================================== </par>
|
||||
*
|
||||
* There is a difference in the initialization of static
|
||||
* variables that are initialized with a codeblock that refers to
|
||||
* a local variable. For example: </par>
|
||||
* a local variable. For example:
|
||||
|
||||
* <fixed>
|
||||
* PROCEDURE TEST()
|
||||
@@ -287,10 +312,10 @@
|
||||
|
||||
* The above code compiles fine in Clipper, but it generates a
|
||||
* runtime error Error/BASE 1132 Bound error: array access
|
||||
* Called form (b)STATICS$(0) </par>
|
||||
* Called form (b)STATICS$(0)
|
||||
*
|
||||
* In Harbour this code generates a compile time error:
|
||||
* Error E0009 Illegal variable (b) initializer: 'MyLocalVar' </par>
|
||||
* Error E0009 Illegal variable (b) initializer: 'MyLocalVar'
|
||||
*
|
||||
* Both Clipper and Harbour are handling all local variables used in a
|
||||
* codeblock in a special way: they are detached from the local stack
|
||||
@@ -300,7 +325,7 @@
|
||||
* ('STATICS$' in Clipper and '(_INITSTATICS)' in Harbour) before the
|
||||
* main procedure and before all INIT procedures. The local variables
|
||||
* don't exist on the eval stack when static variables are initialized,
|
||||
* so they cannot be detached. </par>
|
||||
* so they cannot be detached.
|
||||
*
|
||||
* $END$
|
||||
*/
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
* $FUNCNAME$
|
||||
* DISKSPACE()
|
||||
* $CATEGORY$
|
||||
* Low level
|
||||
* Low Level
|
||||
* $ONELINER$
|
||||
* Get the amount of space available on a disk
|
||||
* $SYNTAX$
|
||||
@@ -55,7 +55,7 @@
|
||||
* $FUNCNAME$
|
||||
* HB_DISKSPACE()
|
||||
* $CATEGORY$
|
||||
* Low level
|
||||
* Low Level
|
||||
* $ONELINER$
|
||||
* Get the amount of space available on a disk
|
||||
* $SYNTAX$
|
||||
|
||||
@@ -775,7 +775,7 @@
|
||||
* $FUNCNAME$
|
||||
* TYPE
|
||||
* $CATEGORY$
|
||||
* Data input and output
|
||||
* Command
|
||||
* $ONELINER$
|
||||
* Show the content of a file on the console, printer or file
|
||||
* $SYNTAX$
|
||||
|
||||
@@ -12,63 +12,73 @@
|
||||
*<b>Language extensions:</b> </par>
|
||||
*--------------------
|
||||
*
|
||||
** Class generation and management. </par>
|
||||
** Class generation and management.
|
||||
*
|
||||
* Clipper only allowed creation of objects from a few standard
|
||||
* classes. </par>
|
||||
* classes.
|
||||
*
|
||||
* In Harbour, you can create your own classes--complete with
|
||||
* Methods, Instance Variables, Class Variables and Inheritance.
|
||||
* Entire applications can be designed and coded in Object Oriented
|
||||
* style. </par>
|
||||
* style.
|
||||
*
|
||||
** @<FunctionName>() </par>
|
||||
* Returns the pointer (address) to a function. </par>
|
||||
*
|
||||
* Returns the pointer (address) to a function.
|
||||
*
|
||||
* The returned value is not useful to application-level programming, but
|
||||
* is used at a low level to implement object oriented coding.
|
||||
* (Internally, a class method is a static function and there is no
|
||||
* symbol for it, so it is accessed via its address). </par>
|
||||
* symbol for it, so it is accessed via its address).
|
||||
*
|
||||
** Class TGetList </par>
|
||||
* Object oriented support for GetLists management. </par>
|
||||
** Class TGetList
|
||||
*
|
||||
** ProcName() support for class Method names. </par>
|
||||
* Class Methods can be retrieved from the call stack. </par>
|
||||
* Object oriented support for GetLists management.
|
||||
*
|
||||
** Memory() has new return values. </par>
|
||||
* See hbmemory.ch </par>
|
||||
** ProcName() support for class Method names.
|
||||
*
|
||||
** Transform() --> new function in format string </par>
|
||||
* @0 Make a zero padded string out of the number. </par>
|
||||
* Class Methods can be retrieved from the call stack.
|
||||
*
|
||||
** SToD() --> dDate </par>
|
||||
* New function that converts a yyyymmdd string to a Date value. </par>
|
||||
** Memory() has new return values.
|
||||
*
|
||||
* See hbmemory.ch
|
||||
*
|
||||
** Transform() --> new function in format string
|
||||
*
|
||||
* @0 Make a zero padded string out of the number.
|
||||
*
|
||||
** SToD() --> dDate
|
||||
*
|
||||
* New function that converts a yyyymmdd string to a Date value.
|
||||
*
|
||||
** Optional Compile Time STRONG TYPE declaration (and compile time TYPE
|
||||
* MISMATCH warnings) </par> </par>
|
||||
* MISMATCH warnings)
|
||||
*
|
||||
* Example: LOCAL/STATIC Var AS ... </par>
|
||||
* Example: LOCAL/STATIC Var AS ...
|
||||
*
|
||||
** The Harbour debugger provides new interesting classes: </par>
|
||||
* - Class TDbWindow could be the foundation for a generic multiplatform </par>
|
||||
* - Class TForm </par>
|
||||
* - Class TDbMenu implement both pulldown and popup menus. </par>
|
||||
** The Harbour debugger provides new interesting classes:
|
||||
*
|
||||
* - Class TDbWindow could be the foundation for a generic multiplatform
|
||||
*
|
||||
* - Class TForm
|
||||
*
|
||||
* - Class TDbMenu implement both pulldown and popup menus.
|
||||
*
|
||||
*<b>RTL enhanced functionality:</b> </par>
|
||||
*--------------------------- </par>
|
||||
*---------------------------
|
||||
*
|
||||
*- Directory( <cMask>, <cFlags>, <lEightDotThree> )
|
||||
*
|
||||
*- Directory( <cMask>, <cFlags>, <lEightDotThree> ) </par>
|
||||
* The 3rd parameter is a Harbour (optional) parameter and indicates that on
|
||||
* those platforms that support long filenames, that you wish to receive what
|
||||
* would be considered the dos equivalant 8.3 name.
|
||||
* Could affect Adir() and Dir if they were modified to take advantage
|
||||
* of it - currently, they will return long names if the os supports it. </par>
|
||||
* of it - currently, they will return long names if the os supports it.
|
||||
*
|
||||
*- HB_DiskSpace( <nDrive>, <nType> )
|
||||
*
|
||||
*- HB_DiskSpace( <nDrive>, <nType> ) </par>
|
||||
* The second parameter is a Harbour (optional) parameter and indicates the
|
||||
* type of diskinfo being requested. See en/diskspac.txt for info. </par>
|
||||
* type of diskinfo being requested. See en/diskspac.txt for info.
|
||||
*
|
||||
* $END$
|
||||
*/
|
||||
|
||||
@@ -385,7 +385,7 @@
|
||||
* $FUNCNAME$
|
||||
* __VMVARLGET()
|
||||
* $CATEGORY$
|
||||
* Variable management
|
||||
* Variable Management
|
||||
* $ONELINER$
|
||||
* Retrive a local variable from a procedure level
|
||||
* $SYNTAX$
|
||||
|
||||
@@ -161,7 +161,7 @@
|
||||
* $FUNCNAME$
|
||||
* MAX()
|
||||
* $CATEGORY$
|
||||
* MATH
|
||||
* Math
|
||||
* $ONELINER$
|
||||
* Returns the maximum of two numbers or dates.
|
||||
* $SYNTAX$
|
||||
@@ -200,7 +200,7 @@
|
||||
* $FUNCNAME$
|
||||
* MIN()
|
||||
* $CATEGORY$
|
||||
* MATH
|
||||
* Math
|
||||
* $ONELINER$
|
||||
* Determines the minumum of two numbers or dates.
|
||||
* $SYNTAX$
|
||||
|
||||
@@ -998,7 +998,7 @@ start from 3000
|
||||
* $SUBCODE$
|
||||
* BASE/2012
|
||||
* $CATEGORY$
|
||||
* files
|
||||
* Run Time Errors
|
||||
* $ONELINER$
|
||||
* File error
|
||||
* $DESCRIPTION$
|
||||
@@ -1347,7 +1347,7 @@ start from 3000
|
||||
* $SUBCODE$
|
||||
* TERM/2013
|
||||
* $CATEGORY$
|
||||
* files
|
||||
* Run Time Errors
|
||||
* $ONELINER$
|
||||
* Create error
|
||||
* $DESCRIPTION$
|
||||
|
||||
@@ -1060,10 +1060,12 @@ FUNCTION ProcChmDesc( cBuffer, oChm, cStyle )
|
||||
ENDIF
|
||||
IF !EMPTY( cBuffer )
|
||||
// cBuffer:=SUBSTR(cBuffer,2)
|
||||
cBuffer := STRTRAN( cBuffer, "<b>", "bold" )
|
||||
cBuffer := STRTRAN( cBuffer, "</b>", "negrito" )
|
||||
cBuffer := STRTRAN( cBuffer, "<", "<" )
|
||||
cBuffer := STRTRAN( cBuffer, ">", ">" )
|
||||
cBuffer := STRTRAN( cBuffer, "<b>", "<b>" )
|
||||
cBuffer := STRTRAN( cBuffer, "</b>", "</b>" )
|
||||
cBuffer := STRTRAN( cBuffer, "bold", "<b>" )
|
||||
cBuffer := STRTRAN( cBuffer, "negrito", "</b>" )
|
||||
|
||||
cBuffeR := ALLTRIM( cBuffer )
|
||||
oChm:WritePar( cBuffer )
|
||||
@@ -1276,7 +1278,7 @@ FUNCTION GenChmTable( oChm )
|
||||
|
||||
oChm:Writetext( "</table>" )
|
||||
|
||||
oChm:WriteText( "<br>" )
|
||||
|
||||
afiTable := {}
|
||||
asitable := {}
|
||||
atitable := {}
|
||||
|
||||
@@ -1089,8 +1089,12 @@ FUNCTION ProchtmDesc( cBuffer, oHtm, cStyle )
|
||||
ENDIF
|
||||
IF !EMPTY( cBuffer )
|
||||
// cBuffer:=SUBSTR(cBuffer,2)
|
||||
cBuffer := STRTRAN( cBuffer, "<b>", "bold" )
|
||||
cBuffer := STRTRAN( cBuffer, "</b>", "negrito" )
|
||||
cBuffer := STRTRAN( cBuffer, "<", "<" )
|
||||
cBuffer := STRTRAN( cBuffer, ">", ">" )
|
||||
cBuffer := STRTRAN( cBuffer, "bold", "<b>" )
|
||||
cBuffer := STRTRAN( cBuffer, "negrito", "</b>" )
|
||||
|
||||
cBuffeR := ALLTRIM( cBuffer )
|
||||
oHtm:WritePar( cBuffer )
|
||||
@@ -1306,7 +1310,7 @@ FUNCTION GenhtmTable( oHtm )
|
||||
|
||||
oHtm:Writetext( "</table>" )
|
||||
|
||||
oHtm:WriteText( "<br>" )
|
||||
// oHtm:WriteText( "<br>" )
|
||||
afiTable := {}
|
||||
asitable := {}
|
||||
atitable := {}
|
||||
|
||||
@@ -357,7 +357,7 @@ FUNCTION ProcessRtf()
|
||||
ELSEIF lMethod
|
||||
oRtf:WriteJumpTitle( LEFT( cFilename, AT( '.', cFilename ) - 1 ) + cFuncName, "Method " + cFuncName )
|
||||
ELSE
|
||||
oRtf:WriteTitle( cFuncName, cFuncName, cOneLine )
|
||||
oRtf:WriteTitle( cFuncName, cFuncName, cOneLine,cCategory)
|
||||
// oRtf:WriteParBold( cOneLine )
|
||||
// oRtf:WriteParBox( cBar )
|
||||
ENDIF
|
||||
|
||||
@@ -124,6 +124,7 @@ MEMVAR lChm
|
||||
MEMVAR lNorton
|
||||
MEMVAR aWWW
|
||||
MEMVAR lTroff
|
||||
MEMVAR aResult
|
||||
STATIC cTitle:=''
|
||||
|
||||
/*
|
||||
@@ -142,6 +143,7 @@ FUNCTION MAIN( cFlags, cLinkName, cAtFile )
|
||||
|
||||
LOCAL aExtensions := { "*.ch", "*.prg", "*.c", "*.asm", "*.txt" }
|
||||
LOCAL i
|
||||
Local cLast
|
||||
LOCAL nItem
|
||||
LOCAL nHpj
|
||||
LOCAL cItem:=''
|
||||
@@ -152,6 +154,8 @@ FUNCTION MAIN( cFlags, cLinkName, cAtFile )
|
||||
LOCAL nPos
|
||||
LOCAL ppp
|
||||
LOCAL aMetaContents:={}
|
||||
Local aTemp:={}
|
||||
LOCAL lAdded:=.f.
|
||||
PUBLIC theHandle
|
||||
PUBLIC aDirList
|
||||
PUBLIC aDocInfo := {}
|
||||
@@ -167,6 +171,7 @@ FUNCTION MAIN( cFlags, cLinkName, cAtFile )
|
||||
PUBLIC lChm := .F.
|
||||
PUBLIC lNorton := .F.
|
||||
PUBLIC aWWW := {}
|
||||
PUBLIC aResult:={}
|
||||
PUBLIC lTroff := .f.
|
||||
|
||||
// The following variables are used to allow one to change the delimiter
|
||||
@@ -430,7 +435,7 @@ FUNCTION MAIN( cFlags, cLinkName, cAtFile )
|
||||
|
||||
NEXT
|
||||
ELSEIF lRtf
|
||||
nHpj := FCREATE( 'HARBOUR.HPJ' )
|
||||
nHpj := FCREATE( 'harbour.hpj' )
|
||||
FWRITE( nHpj, '[OPTIONS]' + CRLF )
|
||||
FWRITE( nHpj, 'HCW=1' + CRLF )
|
||||
FWRITE( nHpj, 'COMPRESS=60 Hall Zeck' + CRLF )
|
||||
@@ -441,12 +446,71 @@ FUNCTION MAIN( cFlags, cLinkName, cAtFile )
|
||||
FWRITE( nHpj, 'COPYRIGHT=Harbour (C) http://www.harbour-project.org' + CRLF )
|
||||
FWRITE( nHpj, 'HLP=.\'+ lower(substr(cLinkName,1,AT(".",cLinkName)-1)) +".hlp"+ CRLF )
|
||||
FWRITE( nHpj, 'ROOT=\' + CURDIR() + "\RTF" + CRLF )
|
||||
FWRITE( nHpj, 'CNT=.\Harbour.cnt' + CRLF )
|
||||
FWRITE( nHpj, 'CNT=.\'+ lower(substr(cLinkName,1,AT(".",cLinkName)-1)) +".cnt"+ CRLF )
|
||||
FWRITE( nHpj, '[FILES]' + CRLF )
|
||||
FWRITE( nHpj, "harbour.rtf" + CRLF )
|
||||
FWRITE( nHpj, '[CONFIG]' + CRLF + 'contents()' + CRLF + 'prev()' + CRLF + 'next()' + CRLF + 'BrowseButtons()' + CRLF )
|
||||
FWRITE( nHpj, '[WINDOWS]' + CRLF + 'Commands="Harbour Commands",(653,102,360,600),20736,(r14876671),(r12632256),f2' + CRLF + 'Error="Harbour Run Time Errors",(653,102,360,600),20736,(r14876671),(r12632256),f2' + CRLF + 'Tools="Harbour Tools",(653,102,360,600),20736,(r14876671),(r12632256),f2' + CRLF + 'Class="Harbour OOP Commands",(653,102,360,600),20736,(r14876671),(r12632256),f2' + CRLF + 'Funca="Harbour Run Time Functions A-M",(653,102,360,600),20736,(r14876671),(r12632256),f2' + CRLF + 'Funcn="Harbour Run Time Functions N-_",(653,102,360,600),20736,(r14876671),(r12632256),f2' + CRLF + 'Main="HARBOUR",(117,100,894,873),60672,(r14876671),(r12632256),f2' + CRLF )
|
||||
FWRITE( nHpj, '[WINDOWS]' + CRLF + 'Commands="Harbour Commands",(653,102,360,600),20736,(r14876671),(r12632256),f2' + CRLF +'API="Harbour Commands",(653,102,360,600),20736,(r14876671),(r12632256),f2' + CRLF + 'Error="Harbour Run Time Errors",(653,102,360,600),20736,(r14876671),(r12632256),f2' + CRLF + 'Tools="Harbour Tools",(653,102,360,600),20736,(r14876671),(r12632256),f2' + CRLF + 'Class="Harbour OOP Commands",(653,102,360,600),20736,(r14876671),(r12632256),f2' + CRLF + 'Funca="Harbour Run Time Functions A-M",(653,102,360,600),20736,(r14876671),(r12632256),f2' + CRLF + 'Funcn="Harbour Run Time Functions N-_",(653,102,360,600),20736,(r14876671),(r12632256),f2' + CRLF + 'Main="HARBOUR",(117,100,894,873),60672,(r14876671),(r12632256),f2' + CRLF )
|
||||
FCLOSE( nHpj )
|
||||
nHpj := FCREATE( lower(substr(cLinkName,1,AT(".",cLinkName)-1)) +".cnt" )
|
||||
FWRITE( nHpj, ':Base'+ lower(substr(cLinkName,1,AT(".",cLinkName)-1)) +".hlp"+ CRLF )
|
||||
FWRITE( nHpj, ':Title'+cTitle+CRLF)
|
||||
FWRITE( nHpj, ':Index harbour='+lower(substr(cLinkName,1,AT(".",cLinkName)-1)) +".hlp"+ CRLF )
|
||||
FWRITE( nHpj, '1 Harbour'+CRLF)
|
||||
asort(aWww,,,{|x,y| x[3]+x[1]<y[3]+y[1]})
|
||||
for ppp:=1 to len(aWww)
|
||||
if aWww[ppp,3]=='Document'
|
||||
fWrite( nHpj, '2 '+aWww[ppp,1]+"="+aWww[ppp,2]+">Main"+CRLF)
|
||||
endif
|
||||
Next
|
||||
asort(aWww,,,{|x,y| x[3]+x[1]<y[3]+y[1]})
|
||||
FWRITE( nHpj, '1 Harbour Run Time Error'+CRLF)
|
||||
for ppp:=1 to len(aWww)
|
||||
if aWww[ppp,3]=='Run Time Errors'
|
||||
fWrite( nHpj, '2 '+aWww[ppp,1]+"="+aWww[ppp,2]+">Error"+CRLF)
|
||||
endif
|
||||
Next
|
||||
FWRITE( nHpj, '1 Harbour Runtime functions and Commands by Name'+CRLF)
|
||||
asort(aWww,,,{|x,y| x[1]<y[1]})
|
||||
for ppp:=1 to len(aWww)
|
||||
if aWww[ppp,3]<>'Run Time Errors' .and. aWww[ppp,3] <>"Document" .and. aWww[ppp,3] <>"The garbage collector" .and. aWww[ppp,3] <>"OOP Command" .and. aWww[ppp,3] <>"Command" .and. aWww[ppp,3] <>"The idle states"
|
||||
fWrite( nHpj, '2 '+aWww[ppp,1]+"="+aWww[ppp,2]+">Funca"+CRLF)
|
||||
endif
|
||||
Next
|
||||
|
||||
FWRITE( nHpj, '1 Harbour Runtime functions Category'+CRLF)
|
||||
asort(aWww,,,{|x,y| x[3]<y[3]})
|
||||
SET CONSOLE ON
|
||||
nItem := len(aResult)
|
||||
asort(aResult,,,{|x,y| x<y})
|
||||
for ppp:=1 to nItem
|
||||
? ppp
|
||||
cLast:=GetNextContent(ppp)
|
||||
if cLast<>'Run Time Errors' .and. cLast <>"Document" .and. cLast <>"The garbage collector" .and. cLast <>"OOP Command" .and. cLast <>"Command" .and. cLast <>"The idle states"
|
||||
WriteContentFile(aWww,cLast,nHpj)
|
||||
endif
|
||||
Next
|
||||
|
||||
FWRITE( nHpj, '1 Harbour Commands'+CRLF)
|
||||
for ppp:=1 to len(aWww)
|
||||
if aWww[ppp,3]=='Command'
|
||||
fWrite( nHpj, '2 '+aWww[ppp,1]+"="+aWww[ppp,2]+">Commands"+CRLF)
|
||||
endif
|
||||
Next
|
||||
FWRITE( nHpj, '1 Harbour OOP commands'+CRLF)
|
||||
for ppp:=1 to len(aWww)
|
||||
if aWww[ppp,3]=='OOP Command'
|
||||
fWrite( nHpj, '2 '+aWww[ppp,1]+"="+aWww[ppp,2]+">Class"+CRLF)
|
||||
endif
|
||||
Next
|
||||
FWRITE( nHpj, '1 The Garbage API'+CRLF)
|
||||
for ppp:=1 to len(aWww)
|
||||
if aWww[ppp,3]=='The garbage collector'
|
||||
fWrite( nHpj, '2 '+aWww[ppp,1]+"="+aWww[ppp,2]+">API"+CRLF)
|
||||
endif
|
||||
Next
|
||||
fClose(nHpj)
|
||||
set console off
|
||||
ELSEIF lWWW
|
||||
|
||||
asort(adocinfo,,,{|x,y| x[1]+x[2]<y[1]+y[2]})
|
||||
@@ -497,7 +561,7 @@ FUNCTION MAIN( cFlags, cLinkName, cAtFile )
|
||||
oHtm1:WriteLink( "license", UpperLower( "Harbour License" ) )
|
||||
oHtm1:WriteLink( "http://www.gnu.org/copyleft/gpl.html", "GNU License" )
|
||||
oHtm1:WriteLink( "compileroptions.htm", "Compiler Options" )
|
||||
oHtm1:WriteLink( "harbourextension.htm", "Harbour Extensions" )
|
||||
oHtm1:WriteLink( "harbourextensions.htm", "Harbour Extensions" )
|
||||
oHtm1:WriteLink( "thegarbagecollector.htm", "The Garbage Collector" )
|
||||
oHtm1:WriteLink( "theidlestates.htm", "The Idle States" )
|
||||
oHtm1:WriteText( "</UL>" )
|
||||
@@ -510,7 +574,7 @@ FUNCTION MAIN( cFlags, cLinkName, cAtFile )
|
||||
ohtm1:WriteLink('hb'+strtran(adocinfo[1,1]," ","")+'.htm',cItem)
|
||||
for ppp:=1 to len(adocinfo)
|
||||
|
||||
if citem<>adocinfo[ppp,1]
|
||||
if citem<>adocinfo[ppp,1] .and. cItem <>"Document"
|
||||
citem:=alltrim(rtrim(ltrim(adocinfo[ppp,1])))
|
||||
ohtm1:WriteLink('hb'+strtran(adocinfo[ppp,1]," ","")+'.htm',cItem)
|
||||
|
||||
@@ -636,6 +700,7 @@ FUNCTION MAIN( cFlags, cLinkName, cAtFile )
|
||||
ohtm:WriteText("</ul>")
|
||||
|
||||
citem:=adocinfo[ppp,1]
|
||||
if cItem <>"Document"
|
||||
oHtm:Listitem()
|
||||
oHtm:AddObject("text/sitemap")
|
||||
oHtm:AddParam("Name",adocinfo[ppp,1])
|
||||
@@ -647,7 +712,7 @@ FUNCTION MAIN( cFlags, cLinkName, cAtFile )
|
||||
oHtm:AddParam("Local",lower(aDocInfo[ppp,4]))
|
||||
oHtm:EndObject()
|
||||
oHtm:WriteChmlink(lower(adocinfo[ppp,4]),adocinfo[ppp,2])
|
||||
|
||||
endif
|
||||
endif
|
||||
next
|
||||
if ppp>len(adocinfo)
|
||||
@@ -1308,3 +1373,44 @@ cReturn:=substr(cVersion,9,4)
|
||||
|
||||
RETURN cReturn
|
||||
|
||||
Function WriteContentFile(aTop,cCat,nFile)
|
||||
Local nCount:=0
|
||||
|
||||
Local aTemp:={}
|
||||
ascan(aWww,,,{|x,y|x[3]+x[1]<y[3]+y[1]})
|
||||
for nCount:=1 to Len(aWww)
|
||||
if Alltrim(aTop[nCount,3])==alltrim(cCat)
|
||||
aadd(aTemp,{aTop[nCount,1],aTop[nCount,2],aTop[nCount,3]})
|
||||
endif
|
||||
Next
|
||||
asort(aTemp,,,{|x,y| x[1]<y[1]})
|
||||
fWrite( nFile, '2 '+cCat+CRLF)
|
||||
for nCount:=1 to Len(aTemp)
|
||||
fWrite( nFile, '3 '+aTemp[nCount,1]+"="+aTemp[nCount,2]+">Funca"+CRLF)
|
||||
next
|
||||
return nil
|
||||
|
||||
|
||||
function GetNextContent(nPos)
|
||||
Local cReturn
|
||||
if nPos <=Len(aResult)
|
||||
cReturn := aResult[nPos]
|
||||
endif
|
||||
return cReturn
|
||||
// fWrite( nHpj, '2 '+aWww[1,3]+CRLF)
|
||||
/* if aWww[ppp,3] <> cLast .and. aWww[ppp,3]<>'Run Time Errors' .and. aWww[ppp,3] <>"Document" .and. aWww[ppp,3] <>"The garbage collector" .and. aWww[ppp,3] <>"OOP Command" .and. aWww[ppp,3] <>"Command" .and. aWww[ppp,3] <>"The idle states"
|
||||
fWrite( nHpj, '2 '+aWww[ppp,3]+CRLF)
|
||||
lAdded:=.t.
|
||||
endif
|
||||
if lAdded
|
||||
ppp++
|
||||
if aWww[ppp,3] == cLast .and. aWww[ppp,3]<>'Run Time Errors' .and. aWww[ppp,3] <>"Document" .and. aWww[ppp,3] <>"The garbage collector" .and. aWww[ppp,3] <>"OOP Command" .and. aWww[ppp,3] <>"Command" .and. aWww[ppp,3] <>"The idle states"
|
||||
fWrite( nHpj, '3 '+aWww[ppp,1]+"="+aWww[ppp,2]+">Funca"+CRLF)
|
||||
endif
|
||||
lAdded:=.F.
|
||||
Elseif aWww[ppp,3] == cLast .and. aWww[ppp,3]<>'Run Time Errors' .and. aWww[ppp,3] <>"Document" .and. aWww[ppp,3] <>"The garbage collector" .and. aWww[ppp,3] <>"OOP Command" .and. aWww[ppp,3] <>"Command" .and. aWww[ppp,3] <>"The idle states"
|
||||
fWrite( nHpj, '3 '+aWww[ppp,1]+"="+aWww[ppp,2]+">Funca"+CRLF)
|
||||
endif
|
||||
|
||||
cLast:=aWww[ppp,3]
|
||||
*/
|
||||
|
||||
@@ -37,7 +37,7 @@
|
||||
|
||||
#include 'hbclass.ch'
|
||||
#include 'common.ch'
|
||||
|
||||
MEMVAR aWWW,aResult
|
||||
*+±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±
|
||||
*+
|
||||
*+ Class TRTF
|
||||
@@ -185,7 +185,7 @@ METHOD WriteParBoldText( cPar, cText ) CLASS TRTF
|
||||
FWRITE( Self:nHandle, '\par \pard\cf1\f6\fs20\i\b ' + ALLTRIM( HB_OEMTOANSI( cPar ) ) + ' \b\cf1\f6\fs20\i0\b0\li300 ' + ALLTRIM( HB_OEMTOANSI( cText ) ) + CRLF )
|
||||
RETURN Self
|
||||
|
||||
METHOD WriteTitle( cTitle, cTopic, cOne ) CLASS TRTF
|
||||
METHOD WriteTitle( cTitle, cTopic, cOne ,cCat) CLASS TRTF
|
||||
|
||||
LOCAL cTemp
|
||||
LOCAL nPos
|
||||
@@ -207,7 +207,11 @@ METHOD WriteTitle( cTitle, cTopic, cOne ) CLASS TRTF
|
||||
' ${\footnote \pard\fs20 $ ' + ALLTRIM( cTopic ) + ' }' + CRLF + ;
|
||||
' K{\footnote \pard\fs20 K ' + ALLTRIM( cTopic ) + ' }' + CRLF + ;
|
||||
'}' + CRLF
|
||||
|
||||
aadd(aWww,{cTopic,"IDH_"+cTemp,cCat})
|
||||
nPos := ascan(aResult,{|a| UPPER(a) == UPPER(cCat)})
|
||||
if nPos==0
|
||||
aadd(aResult,cCat)
|
||||
endif
|
||||
FWRITE( Self:nHandle, cWrite )
|
||||
|
||||
FWRITE( Self:nHandle, '\pard\cf1\f6\fs30\i0\b\keepn ' + ALLTRIM( HB_OEMTOANSI( cTopic ) ) + CRLF )
|
||||
|
||||
Reference in New Issue
Block a user