2012-07-30 01:58 UTC+0200 Viktor Szakats (harbour syenar.net)
* contrib/hbct/doc/en/addascii.txt
* contrib/hbct/doc/en/asciisum.txt
* contrib/hbct/doc/en/ascpos.txt
* contrib/hbct/doc/en/atadjust.txt
* contrib/hbct/doc/en/atnum.txt
* contrib/hbct/doc/en/atrepl.txt
* contrib/hbct/doc/en/charevod.txt
* contrib/hbct/doc/en/charlihb.txt
* contrib/hbct/doc/en/charlist.txt
* contrib/hbct/doc/en/charmirr.txt
* contrib/hbct/doc/en/charmix.txt
* contrib/hbct/doc/en/charone.txt
* contrib/hbct/doc/en/charonly.txt
* contrib/hbct/doc/en/charop.txt
* contrib/hbct/doc/en/charophb.txt
* contrib/hbct/doc/en/charrepl.txt
* contrib/hbct/doc/en/charsort.txt
* contrib/hbct/doc/en/charswap.txt
* contrib/hbct/doc/en/color.txt
* contrib/hbct/doc/en/count.txt
* contrib/hbct/doc/en/ct.txt
* contrib/hbct/doc/en/ctc.txt
* contrib/hbct/doc/en/ctmath.txt
* contrib/hbct/doc/en/ctmath2.txt
* contrib/hbct/doc/en/ctpad.txt
* contrib/hbct/doc/en/ctstr.txt
* contrib/hbct/doc/en/datetime.txt
* contrib/hbct/doc/en/dattime2.txt
* contrib/hbct/doc/en/dattime3.txt
* contrib/hbct/doc/en/exponent.txt
* contrib/hbct/doc/en/finan.txt
* contrib/hbct/doc/en/justify.txt
* contrib/hbct/doc/en/keyset.txt
* contrib/hbct/doc/en/num1.txt
* contrib/hbct/doc/en/numat.txt
* contrib/hbct/doc/en/numconv.txt
* contrib/hbct/doc/en/pos1.txt
* contrib/hbct/doc/en/pos2.txt
* contrib/hbct/doc/en/posdiff.txt
* contrib/hbct/doc/en/print.txt
* contrib/hbct/doc/en/range.txt
* contrib/hbct/doc/en/relation.txt
* contrib/hbct/doc/en/remove.txt
* contrib/hbct/doc/en/replace.txt
* contrib/hbct/doc/en/screen1.txt
* contrib/hbct/doc/en/strdiff.txt
* contrib/hbct/doc/en/strswap.txt
* contrib/hbct/doc/en/tab.txt
* contrib/hbct/doc/en/token1.txt
* contrib/hbct/doc/en/token2.txt
* contrib/hbct/doc/en/trig.txt
* contrib/hbct/doc/en/video.txt
* contrib/hbct/doc/en/wordrepl.txt
* contrib/hbct/doc/en/wordtoch.txt
* code formatting, minor cleanups
This commit is contained in:
@@ -16,6 +16,63 @@
|
||||
The license applies to all entries newer than 2009-04-28.
|
||||
*/
|
||||
|
||||
2012-07-30 01:58 UTC+0200 Viktor Szakats (harbour syenar.net)
|
||||
* contrib/hbct/doc/en/addascii.txt
|
||||
* contrib/hbct/doc/en/asciisum.txt
|
||||
* contrib/hbct/doc/en/ascpos.txt
|
||||
* contrib/hbct/doc/en/atadjust.txt
|
||||
* contrib/hbct/doc/en/atnum.txt
|
||||
* contrib/hbct/doc/en/atrepl.txt
|
||||
* contrib/hbct/doc/en/charevod.txt
|
||||
* contrib/hbct/doc/en/charlihb.txt
|
||||
* contrib/hbct/doc/en/charlist.txt
|
||||
* contrib/hbct/doc/en/charmirr.txt
|
||||
* contrib/hbct/doc/en/charmix.txt
|
||||
* contrib/hbct/doc/en/charone.txt
|
||||
* contrib/hbct/doc/en/charonly.txt
|
||||
* contrib/hbct/doc/en/charop.txt
|
||||
* contrib/hbct/doc/en/charophb.txt
|
||||
* contrib/hbct/doc/en/charrepl.txt
|
||||
* contrib/hbct/doc/en/charsort.txt
|
||||
* contrib/hbct/doc/en/charswap.txt
|
||||
* contrib/hbct/doc/en/color.txt
|
||||
* contrib/hbct/doc/en/count.txt
|
||||
* contrib/hbct/doc/en/ct.txt
|
||||
* contrib/hbct/doc/en/ctc.txt
|
||||
* contrib/hbct/doc/en/ctmath.txt
|
||||
* contrib/hbct/doc/en/ctmath2.txt
|
||||
* contrib/hbct/doc/en/ctpad.txt
|
||||
* contrib/hbct/doc/en/ctstr.txt
|
||||
* contrib/hbct/doc/en/datetime.txt
|
||||
* contrib/hbct/doc/en/dattime2.txt
|
||||
* contrib/hbct/doc/en/dattime3.txt
|
||||
* contrib/hbct/doc/en/exponent.txt
|
||||
* contrib/hbct/doc/en/finan.txt
|
||||
* contrib/hbct/doc/en/justify.txt
|
||||
* contrib/hbct/doc/en/keyset.txt
|
||||
* contrib/hbct/doc/en/num1.txt
|
||||
* contrib/hbct/doc/en/numat.txt
|
||||
* contrib/hbct/doc/en/numconv.txt
|
||||
* contrib/hbct/doc/en/pos1.txt
|
||||
* contrib/hbct/doc/en/pos2.txt
|
||||
* contrib/hbct/doc/en/posdiff.txt
|
||||
* contrib/hbct/doc/en/print.txt
|
||||
* contrib/hbct/doc/en/range.txt
|
||||
* contrib/hbct/doc/en/relation.txt
|
||||
* contrib/hbct/doc/en/remove.txt
|
||||
* contrib/hbct/doc/en/replace.txt
|
||||
* contrib/hbct/doc/en/screen1.txt
|
||||
* contrib/hbct/doc/en/strdiff.txt
|
||||
* contrib/hbct/doc/en/strswap.txt
|
||||
* contrib/hbct/doc/en/tab.txt
|
||||
* contrib/hbct/doc/en/token1.txt
|
||||
* contrib/hbct/doc/en/token2.txt
|
||||
* contrib/hbct/doc/en/trig.txt
|
||||
* contrib/hbct/doc/en/video.txt
|
||||
* contrib/hbct/doc/en/wordrepl.txt
|
||||
* contrib/hbct/doc/en/wordtoch.txt
|
||||
* code formatting, minor cleanups
|
||||
|
||||
2012-07-30 01:40 UTC+0200 Viktor Szakats (harbour syenar.net)
|
||||
* contrib/hbide/resources/b_1.png
|
||||
* contrib/hbide/resources/b_10.png
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Add an integer value to an ascii value of a string
|
||||
* $SYNTAX$
|
||||
* ADDASCII (<[@]cString>, <nValue>, [<nPosition>], [<lCarryOver>]) --> cString
|
||||
* ADDASCII( <[@]cString>, <nValue>, [<nPosition>], [<lCarryOver>] ) --> cString
|
||||
* $ARGUMENTS$
|
||||
* <[@]cString> is the string that should be edited
|
||||
* <nValue> is a integer value that should be added to the
|
||||
@@ -40,17 +40,17 @@
|
||||
* // Add 32 to the ASCII value of the character at the last position
|
||||
* // in the string
|
||||
*
|
||||
* ? addascii ("SmitH", 32) --> "Smith"
|
||||
* ? addascii( "SmitH", 32 ) // --> "Smith"
|
||||
* $TESTS$
|
||||
* addascii ("0000", 1, 1) == "1000"
|
||||
* addascii ("0000", 1) == "0001"
|
||||
* addascii ("AAAA", -255, 1) == "BAAA"
|
||||
* addascii ("AAAA", -255) == "AAAB"
|
||||
* addascii ("AAAA", 1, 2, .T.) == "ABAA"
|
||||
* addascii ("AAAA", 257, 2, .T.) == "BBAA"
|
||||
* addascii ("AAAA", 257, 2, .F.) == "ABAA"
|
||||
* addascii ("AAAA", 258,, .T.) == "AABC"
|
||||
* addascii ("ABBA", -257, 3, .T.) == "AAAA"
|
||||
* addascii( "0000", 1, 1 ) == "1000"
|
||||
* addascii( "0000", 1 ) == "0001"
|
||||
* addascii( "AAAA", -255, 1 ) == "BAAA"
|
||||
* addascii( "AAAA", -255 ) == "AAAB"
|
||||
* addascii( "AAAA", 1, 2, .T. ) == "ABAA"
|
||||
* addascii( "AAAA", 257, 2, .T. ) == "BBAA"
|
||||
* addascii( "AAAA", 257, 2, .F. ) == "ABAA"
|
||||
* addascii( "AAAA", 258,, .T. ) == "AABC"
|
||||
* addascii( "ABBA", -257, 3, .T. ) == "AAAA"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* calculate the sum of the ASCII values of the characters in a string
|
||||
* $SYNTAX$
|
||||
* ASCIISUM (<cString>) --> nAsciiSum
|
||||
* ASCIISUM( <cString> ) --> nAsciiSum
|
||||
* $ARGUMENTS$
|
||||
* <cString> the string to be processed
|
||||
* $RETURNS$
|
||||
@@ -21,12 +21,12 @@
|
||||
* i.e. a change of position of a certain character in the string does
|
||||
* not change the ascii sum.
|
||||
* $EXAMPLES$
|
||||
* ? asciisum ("ABC") --> 197
|
||||
* ? asciisum ("ACB") --> 197
|
||||
* ? asciisum( "ABC" ) // --> 197
|
||||
* ? asciisum( "ACB" ) // --> 197
|
||||
* $TESTS$
|
||||
* asciisum (replicate ("A", 10000)) == 650000
|
||||
* asciisum ("0123456789") == 525
|
||||
* asciisum (nil) == 0
|
||||
* asciisum( Replicate( "A", 10000 ) ) == 650000
|
||||
* asciisum( "0123456789" ) == 525
|
||||
* asciisum( NIL ) == 0
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* ASCII value of a character at a certain position
|
||||
* $SYNTAX$
|
||||
* ASCPOS (<cString>, [<nPosition>]) --> nAsciiValue
|
||||
* ASCPOS( <cString>, [<nPosition>] ) --> nAsciiValue
|
||||
* $ARGUMENTS$
|
||||
* <cString> is the processed string
|
||||
* [<nPosition>] is an optional position within <cString>
|
||||
@@ -23,12 +23,12 @@
|
||||
* can be found at the position <nPosition> in <cString>. If <nPosition>
|
||||
* is larger than the length of <cString>, 0 is returned.
|
||||
* $EXAMPLES$
|
||||
* ? ascpos ("0123456789") --> 57
|
||||
* ? ascpos ("0123456789",1) --> 48
|
||||
* ? ascpos( "0123456789" ) // --> 57
|
||||
* ? ascpos( "0123456789", 1 ) // --> 48
|
||||
* $TESTS$
|
||||
* ascpos ("0123456789") == 57
|
||||
* ascpos ("0123456789",1) == 48
|
||||
* ascpos ("0123456789",11) == 0 // <nPosition> to large !
|
||||
* ascpos( "0123456789" ) == 57
|
||||
* ascpos( "0123456789", 1 ) == 48
|
||||
* ascpos( "0123456789", 11 ) == 0 // <nPosition> to large !
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -50,7 +50,7 @@
|
||||
* $ONELINER$
|
||||
* Numerical value of a character at a certain position
|
||||
* $SYNTAX$
|
||||
* VALPOS (<cString>, [<nPosition>]) --> nDigitValue
|
||||
* VALPOS( <cString>, [<nPosition>] ) --> nDigitValue
|
||||
* $ARGUMENTS$
|
||||
* <cString> is the processed string
|
||||
* [<nPosition>] is an optional position within <cString>
|
||||
@@ -64,13 +64,13 @@
|
||||
* can be found at this position or if <nPosition>
|
||||
* is larger than the length of <cString>, 0 is returned.
|
||||
* $EXAMPLES$
|
||||
* ? valpos ("1234x56789") --> 9
|
||||
* ? valpos ("1234x56789",1) --> 1
|
||||
* ? valpos( "1234x56789" ) // --> 9
|
||||
* ? valpos( "1234x56789", 1 ) // --> 1
|
||||
* $TESTS$
|
||||
* valpos ("1234x56789") == 9
|
||||
* valpos ("1234x56789",1) == 1
|
||||
* valpos ("1234x56789",11) == 0 // <nPosition> to large !
|
||||
* valpos ("1234x56789",5) == 0 // "x" is not a digit !
|
||||
* valpos( "1234x56789" ) == 9
|
||||
* valpos( "1234x56789", 1 ) == 1
|
||||
* valpos( "1234x56789", 11 ) == 0 // <nPosition> to large !
|
||||
* valpos( "1234x56789", 5 ) == 0 // "x" is not a digit !
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -10,9 +10,9 @@
|
||||
* $ONELINER$
|
||||
* Adjusts a sequence within a string to a specified position
|
||||
* $SYNTAX$
|
||||
* ATADJUST (<cStringToMatch>, <cString>, <nAdjustPosition>,
|
||||
* ATADJUST( <cStringToMatch>, <cString>, <nAdjustPosition>,
|
||||
* [<nCounter>], [<nIgnore>],
|
||||
* [<nFillChar|cFillChar>]) -> cString
|
||||
* [<nFillChar|cFillChar>] ) -> cString
|
||||
* $ARGUMENTS$
|
||||
* <cStringToMatch> is the sequence to be adjusted within <cString>
|
||||
* <cString> is the string that contains <cStringToMatch>
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Returns string portion after nth occurence of substring
|
||||
* $SYNTAX$
|
||||
* AFTERATNUM (<cStringToMatch>, <cString>, [<nCounter>],
|
||||
* AFTERATNUM( <cStringToMatch>, <cString>, [<nCounter>],
|
||||
* [<nIgnore>] ) --> cRestString
|
||||
* $ARGUMENTS$
|
||||
* <cStringToMatch> is the substring scanned for
|
||||
@@ -38,13 +38,13 @@
|
||||
* second character of the matched substring otherwise.
|
||||
* The function will also consider the settings of SETATLIKE().
|
||||
* $EXAMPLES$
|
||||
* ? AFTERATNUM ("!", "What is the answer ? 4 ! 5 !") -> ""
|
||||
* ? AFTERATNUM ("!", "What is the answer ? 4 ! 5 ?") -> " 5 ?"
|
||||
* ? AFTERATNUM( "!", "What is the answer ? 4 ! 5 !" ) // -> ""
|
||||
* ? AFTERATNUM( "!", "What is the answer ? 4 ! 5 ?" ) // -> " 5 ?"
|
||||
* <TODO: add some examples here with csetatmupa() and setatlike()>
|
||||
* $TESTS$
|
||||
* AFTERATNUM ("..", "..This..is..a..test!") == "test!"
|
||||
* AFTERATNUM ("..", "..This..is..a..test!", 2) == "is..a..test!"
|
||||
* AFTERATNUM ("..", "..This..is..a..test!", 2, 2) == "a..test!"
|
||||
* AFTERATNUM( "..", "..This..is..a..test!" ) == "test!"
|
||||
* AFTERATNUM( "..", "..This..is..a..test!", 2 ) == "is..a..test!"
|
||||
* AFTERATNUM( "..", "..This..is..a..test!", 2, 2 ) == "a..test!"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -66,7 +66,7 @@
|
||||
* $ONELINER$
|
||||
* Returns string portion before nth occurence of substring
|
||||
* $SYNTAX$
|
||||
* BEFORATNUM (<cStringToMatch>, <cString>, [<nCounter>],
|
||||
* BEFORATNUM( <cStringToMatch>, <cString>, [<nCounter>],
|
||||
* [<nIgnore>] ) --> cRestString
|
||||
* $ARGUMENTS$
|
||||
* <cStringToMatch> is the substring scanned for
|
||||
@@ -94,13 +94,13 @@
|
||||
* second character of the matched substring otherwise.
|
||||
* The function will also consider the settings of SETATLIKE().
|
||||
* $EXAMPLES$
|
||||
* ? BEFORATNUM ("!", "What is the answer ? 4 ! 5 !") -> "What is the answer ? 4 ! 5 "
|
||||
* ? BEFORATNUM ("!", "What is the answer ? 4 ! 5 ?") -> "What is the answer ? 4 "
|
||||
* ? BEFORATNUM( "!", "What is the answer ? 4 ! 5 !" ) // -> "What is the answer ? 4 ! 5 "
|
||||
* ? BEFORATNUM( "!", "What is the answer ? 4 ! 5 ?" ) // -> "What is the answer ? 4 "
|
||||
* <TODO: add some examples here with csetatmupa() and setatlike()>
|
||||
* $TESTS$
|
||||
* BEFORATNUM ("..", "..This..is..a..test!") == "..This..is..a"
|
||||
* BEFORATNUM ("..", "..This..is..a..test!", 2) == "..This"
|
||||
* BEFORATNUM ("..", "..This..is..a..test!", 2, 2) == "..This..is"
|
||||
* BEFORATNUM( "..", "..This..is..a..test!" ) == "..This..is..a"
|
||||
* BEFORATNUM( "..", "..This..is..a..test!", 2 ) == "..This"
|
||||
* BEFORATNUM( "..", "..This..is..a..test!", 2, 2 ) == "..This..is"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -149,13 +149,13 @@
|
||||
* second character of the matched substring otherwise.
|
||||
* The function will also consider the settings of SETATLIKE().
|
||||
* $EXAMPLES$
|
||||
* ? ATNUM ("!", "What is the answer ? 4 ! 5 !") -> 28
|
||||
* ? ATNUM ("!", "What is the answer ? 4 ! 5 ?") -> 24
|
||||
* ? ATNUM( "!", "What is the answer ? 4 ! 5 !" ) // -> 28
|
||||
* ? ATNUM( "!", "What is the answer ? 4 ! 5 ?" ) // -> 24
|
||||
* <TODO: add some examples here with csetatmupa() and setatlike()>
|
||||
* $TESTS$
|
||||
* ATNUM ("..", "..This..is..a..test!") == 14
|
||||
* ATNUM ("..", "..This..is..a..test!", 2) == 7
|
||||
* ATNUM ("..", "..This..is..a..test!", 2, 2) == 11
|
||||
* ATNUM( "..", "..This..is..a..test!" ) == 14
|
||||
* ATNUM( "..", "..This..is..a..test!", 2 ) == 7
|
||||
* ATNUM( "..", "..This..is..a..test!", 2, 2 ) == 11
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -10,8 +10,8 @@
|
||||
* $ONELINER$
|
||||
* Search and replace sequences in a string
|
||||
* $SYNTAX$
|
||||
* ATREPL (<cStringToMatch>, <cString>, <cReplacement>, [<nCounter>],
|
||||
* [<lMode>], [<nIgnore>]) --> cString
|
||||
* ATREPL( <cStringToMatch>, <cString>, <cReplacement>, [<nCounter>],
|
||||
* [<lMode>], [<nIgnore>] ) --> cString
|
||||
* $ARGUMENTS$
|
||||
* <cStringToMatch> is the substring searched for in <cString>
|
||||
* <cString> is the processed string
|
||||
@@ -44,15 +44,15 @@
|
||||
* The function allows the use of wildcards in <cStringToMatch>
|
||||
* and looks for the settings of SETATLIKE().
|
||||
* $EXAMPLES$
|
||||
* ? ATREPL("ABC", "ABCDABCDABC", "xx") --> "xxDxxDxx"
|
||||
* ? ATREPL("ABC", "ABCDABC", "ZYXW") --> "ZYXWDZYXW"
|
||||
* ? ATREPL("ABC", "ABCDABCDABC", "xx", 2) --> "xxDxxDABC"
|
||||
* ? ATREPL("ABC", "ABCDABCDABC", "xx", 2, .T.) --> "ABCDxxDABC"
|
||||
* ? ATREPL( "ABC", "ABCDABCDABC", "xx" ) // --> "xxDxxDxx"
|
||||
* ? ATREPL( "ABC", "ABCDABC", "ZYXW" ) // --> "ZYXWDZYXW"
|
||||
* ? ATREPL( "ABC", "ABCDABCDABC", "xx", 2 ) // --> "xxDxxDABC"
|
||||
* ? ATREPL( "ABC", "ABCDABCDABC", "xx", 2, .T. ) // --> "ABCDxxDABC"
|
||||
* $TESTS$
|
||||
* ATREPL("ABC", "ABCDABCDABC", "xx") == "xxDxxDxx"
|
||||
* ATREPL("ABC", "ABCDABC", "ZYXW") == "ZYXWDZYXW"
|
||||
* ATREPL("ABC", "ABCDABCDABC", "xx", 2) == "xxDxxDABC"
|
||||
* ATREPL("ABC", "ABCDABCDABC", "xx", 2, .T.) == "ABCDxxDABC"
|
||||
* ATREPL( "ABC", "ABCDABCDABC", "xx" ) == "xxDxxDxx"
|
||||
* ATREPL( "ABC", "ABCDABC", "ZYXW" ) == "ZYXWDZYXW"
|
||||
* ATREPL( "ABC", "ABCDABCDABC", "xx", 2 ) == "xxDxxDABC"
|
||||
* ATREPL( "ABC", "ABCDABCDABC", "xx", 2, .T. ) == "ABCDxxDABC"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Returns the characters on the even positions in a string
|
||||
* $SYNTAX$
|
||||
* CHAREVEN (<cString>) --> cEvenString
|
||||
* CHAREVEN( <cString> ) --> cEvenString
|
||||
* $ARGUMENTS$
|
||||
* <cString> processed string
|
||||
* $RETURNS$
|
||||
@@ -20,11 +20,11 @@
|
||||
* The CHAREVEN() function looks for the characters on the even positions
|
||||
* in a given string, collects them and returns them as a string.
|
||||
* $EXAMPLES$
|
||||
* ? CHAREVEN (" H E L L O !") -> "HELLO!"
|
||||
* ? CHAREVEN( " H E L L O !" ) // -> "HELLO!"
|
||||
* $TESTS$
|
||||
* CHAREVEN (" 1 2 3 4 5") == "12345"
|
||||
* CHAREVEN (" 1 2 3 4 ") == "1234"
|
||||
* CHAREVEN (" ") == ""
|
||||
* CHAREVEN( " 1 2 3 4 5" ) == "12345"
|
||||
* CHAREVEN( " 1 2 3 4 " ) == "1234"
|
||||
* CHAREVEN( " " ) == ""
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -46,7 +46,7 @@
|
||||
* $ONELINER$
|
||||
* Returns the characters on the odd positions in a string
|
||||
* $SYNTAX$
|
||||
* CHARODD (<cString>) --> cOddString
|
||||
* CHARODD( <cString> ) --> cOddString
|
||||
* $ARGUMENTS$
|
||||
* <cString> processed string
|
||||
* $RETURNS$
|
||||
@@ -56,10 +56,10 @@
|
||||
* The CHARODD() function looks for the characters on the odd positions
|
||||
* in a given string, collects them and returns them as a string.
|
||||
* $EXAMPLES$
|
||||
* ? CHARODD ("H E L L O ! ") -> "HELLO!"
|
||||
* ? CHARODD( "H E L L O ! " ) // -> "HELLO!"
|
||||
* $TESTS$
|
||||
* CHARODD ("1A2B3C4D5E") == "12345"
|
||||
* CHARODD ("1A2B3C4D5") == "12345"
|
||||
* CHARODD( "1A2B3C4D5E" ) == "12345"
|
||||
* CHARODD( "1A2B3C4D5" ) == "12345"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Generates a sorted list of all characters in a string
|
||||
* $SYNTAX$
|
||||
* CHARSLIST ([<cString>]) -> cSortedCharacterList
|
||||
* CHARSLIST( [<cString>] ) -> cSortedCharacterList
|
||||
* $ARGUMENTS$
|
||||
* [<cString>] is the string for whom the function generates a
|
||||
* sorted list of all characters
|
||||
@@ -23,11 +23,11 @@
|
||||
* only once, so that its maximum length is 256. The function
|
||||
* gives the same result as CHARSORT(CHARLIST(<cString>))
|
||||
* $EXAMPLES$
|
||||
* ? charslist ("Hello World !") --> " !HWdelor"
|
||||
* ? charslist( "Hello World !" ) // --> " !HWdelor"
|
||||
* $TESTS$
|
||||
* charslist ("Hello World !") == " !HWdelor"
|
||||
* charslist ("Hello World !") == charsort (charlist ("Hello World !"))
|
||||
* charslist (nil) == ""
|
||||
* charslist( "Hello World !" ) == " !HWdelor"
|
||||
* charslist( "Hello World !" ) == charsort (charlist ("Hello World !"))
|
||||
* charslist( NIL ) == ""
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -49,7 +49,7 @@
|
||||
* $ONELINER$
|
||||
* Generates a character histogram of a string
|
||||
* $SYNTAX$
|
||||
* CHARHIST ([<cString>]) -> aCharacterCount
|
||||
* CHARHIST( [<cString>] ) -> aCharacterCount
|
||||
* $ARGUMENTS$
|
||||
* [<cString>] is the string for whom the function generates a
|
||||
* character histogram
|
||||
@@ -63,10 +63,10 @@
|
||||
* in an 256-element array where the nth element contains the count
|
||||
* of ASCII character #(n-1) in <cString>.
|
||||
* $EXAMPLES$
|
||||
* ? charhist ("Hello World !")[109] --> 3 // chr(108)=="l"
|
||||
* ? charhist( "Hello World !" )[ 109 ] // --> 3 // Chr( 108 ) == "l"
|
||||
* $TESTS$
|
||||
* charhist ("Hello World !")[109] == 3
|
||||
* eval ({||aeval (charhist ("Hello World !"),{|x|nTotal+=x}),nTotal==len("Hello World !")}
|
||||
* charhist( "Hello World !" )[ 109 ] == 3
|
||||
* eval( {|| AEval( charhist( "Hello World !" ), {| x | nTotal += x } ), nTotal == Len( "Hello World !" ) }
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Generates a list of all characters in a string
|
||||
* $SYNTAX$
|
||||
* CHARLIST ([<cString>]) -> cCharacterList
|
||||
* CHARLIST( [<cString>] ) -> cCharacterList
|
||||
* $ARGUMENTS$
|
||||
* [<cString>] is the string for whom the function generates a list
|
||||
* of all characters
|
||||
@@ -23,10 +23,10 @@
|
||||
* only once, so that its maximum length is 256. The list lists those
|
||||
* characters first that are occuring in <cString> first.
|
||||
* $EXAMPLES$
|
||||
* ? charlist ("Hello World !") --> "Helo Wrd!"
|
||||
* ? charlist( "Hello World !" ) // --> "Helo Wrd!"
|
||||
* $TESTS$
|
||||
* charlist ("Hello World !") == "Helo Wrd!"
|
||||
* charlist (nil) == ""
|
||||
* charlist( "Hello World !" ) == "Helo Wrd!"
|
||||
* charlist( NIL ) == ""
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -48,7 +48,7 @@
|
||||
* $ONELINER$
|
||||
* Generates a list of all characters not contained in a string
|
||||
* $SYNTAX$
|
||||
* CHARNOLIST ([<cString>]) -> cCharacterList
|
||||
* CHARNOLIST( [<cString>] ) -> cCharacterList
|
||||
* $ARGUMENTS$
|
||||
* [<cString>] is the string for whom the function generates a list
|
||||
* of all characters not contained in that string
|
||||
@@ -61,10 +61,10 @@
|
||||
* only once, so that its maximum length is 256. The list is alphabetically
|
||||
* sorted.
|
||||
* $EXAMPLES$
|
||||
* ? charnolist (charnolist ("Hello World !")) --> " !HWdelor"
|
||||
* ? charnolist( charnolist( "Hello World !" ) ) // --> " !HWdelor"
|
||||
* $TESTS$
|
||||
* charnolist (charnolist ("Hello World !")) == charslist ("Hello World !")
|
||||
* charnolist (charnolist (nil)) == ""
|
||||
* charnolist( charnolist( "Hello World !" ) ) == charslist( "Hello World !" )
|
||||
* charnolist( charnolist( NIL ) ) == ""
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Mirror a string
|
||||
* $SYNTAX$
|
||||
* CHARMIRR (<[@]cString>, [<lDontMirrorSpaces>]) -> cMirroredString
|
||||
* CHARMIRR( <[@]cString>, [<lDontMirrorSpaces>] ) -> cMirroredString
|
||||
* $ARGUMENTS$
|
||||
* <[@]cString> is the string that should be mirrored
|
||||
* [<lDontMirrorSpaces>] if set to .T., spaces at the end of
|
||||
@@ -27,13 +27,13 @@
|
||||
* switch to .T., but <cString> must then be passed by reference to get
|
||||
* a result.
|
||||
* $EXAMPLES$
|
||||
* ? charmirr ("racecar") // "racecar"
|
||||
* ? charmirr ("racecar ", .T.) // "racecar "
|
||||
* ? charmirr ("racecar ", .F.) // " racecar"
|
||||
* ? charmirr( "racecar" ) // "racecar"
|
||||
* ? charmirr( "racecar ", .T. ) // "racecar "
|
||||
* ? charmirr( "racecar ", .F. ) // " racecar"
|
||||
* $TESTS$
|
||||
* charmirr ("racecar") == "racecar"
|
||||
* charmirr ("racecar ", .T.) == "racecar "
|
||||
* charmirr ("racecar ", .F.) == " racecar"
|
||||
* charmirr( "racecar" ) == "racecar"
|
||||
* charmirr( "racecar ", .T. ) == "racecar "
|
||||
* charmirr( "racecar ", .F. ) == " racecar"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Mix two strings
|
||||
* $SYNTAX$
|
||||
* CHARMIX (<cString1>[, <cString2>]) --> cMixedString
|
||||
* CHARMIX( <cString1>[, <cString2>] ) --> cMixedString
|
||||
* $ARGUMENTS$
|
||||
* <cString1> String that will be mixed with the characters from <cString2>
|
||||
* [<cString2>] String whose characters will be mixed with the one from
|
||||
@@ -27,17 +27,17 @@
|
||||
* the begin of <cString2> again. If on the other hand <cString2> is
|
||||
* longer than <cString1>, the surplus characters will be omitted.
|
||||
* $EXAMPLES$
|
||||
* ? CHARMIX("ABC", "123") // "A1B2C3"
|
||||
* ? CHARMIX("ABCDE", "12") // "A1B2C1D2E1"
|
||||
* ? CHARMIX("AB", "12345") // "A1B2"
|
||||
* ? CHARMIX("HELLO", " ") // "H E L L O "
|
||||
* ? CHARMIX("HELLO", "") // "HELLO"
|
||||
* ? CHARMIX( "ABC", "123" ) // "A1B2C3"
|
||||
* ? CHARMIX( "ABCDE", "12" ) // "A1B2C1D2E1"
|
||||
* ? CHARMIX( "AB", "12345" ) // "A1B2"
|
||||
* ? CHARMIX( "HELLO", " " ) // "H E L L O "
|
||||
* ? CHARMIX( "HELLO", "" ) // "HELLO"
|
||||
* $TESTS$
|
||||
* CHARMIX("ABC", "123") == "A1B2C3"
|
||||
* CHARMIX("ABCDE", "12") == "A1B2C1D2E1"
|
||||
* CHARMIX("AB", "12345") == "A1B2"
|
||||
* CHARMIX("HELLO", " ") == "H E L L O "
|
||||
* CHARMIX("HELLO", "") == "HELLO"
|
||||
* CHARMIX( "ABC", "123" ) == "A1B2C3"
|
||||
* CHARMIX( "ABCDE", "12" ) == "A1B2C1D2E1"
|
||||
* CHARMIX( "AB", "12345") == "A1B2"
|
||||
* CHARMIX( "HELLO", " " ) == "H E L L O "
|
||||
* CHARMIX( "HELLO", "" ) == "HELLO"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Reduce multiple occurences of a character to one
|
||||
* $SYNTAX$
|
||||
* CHARONE ([<cCharactersToReduce>,] <cString>) -> cReducedString
|
||||
* CHARONE( [<cCharactersToReduce>,] <cString> ) -> cReducedString
|
||||
* $ARGUMENTS$
|
||||
* [<cCharactersToReduce>] specifies the characters the multiple
|
||||
* occurences of which should be reduced to one
|
||||
@@ -24,15 +24,15 @@
|
||||
* occurences must occur directly one behind the other. This behaviour is
|
||||
* is in contrast to the CHARLIST() function.
|
||||
* $EXAMPLES$
|
||||
* ? CHARONE("122333a123") // "123a123"
|
||||
* ? CHARONE("A B CCCD") // "A B CD"
|
||||
* ? CHARONE(" ", "A B A B") // "A B A B"
|
||||
* ? CHARONE("o", "122oooB12o") // "122oB12o"
|
||||
* ? CHARONE( "122333a123" ) // "123a123"
|
||||
* ? CHARONE( "A B CCCD" ) // "A B CD"
|
||||
* ? CHARONE( " ", "A B A B" ) // "A B A B"
|
||||
* ? CHARONE( "o", "122oooB12o" ) // "122oB12o"
|
||||
* $TESTS$
|
||||
* CHARONE("122333a123") == "123a123"
|
||||
* CHARONE("A B CCCD") == "A B CD"
|
||||
* CHARONE(" ", "A B A B") == "A B A B"
|
||||
* CHARONE("o", "122oooB12o") == "122oB12o"
|
||||
* CHARONE( "122333a123" ) == "123a123"
|
||||
* CHARONE( "A B CCCD" ) == "A B CD"
|
||||
* CHARONE( " ", "A B A B" ) == "A B A B"
|
||||
* CHARONE( "o", "122oooB12o" ) == "122oB12o"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -54,7 +54,7 @@
|
||||
* $ONELINER$
|
||||
* Reduce multiple occurences of a double character to one
|
||||
* $SYNTAX$
|
||||
* WORDONE ([<cDoubleCharactersToReduce>,] <cString>) -> cReducedString
|
||||
* WORDONE( [<cDoubleCharactersToReduce>,] <cString> ) -> cReducedString
|
||||
* $ARGUMENTS$
|
||||
* [<cDoubleCharactersToReduce>] specifies the double characters the multiple
|
||||
* occurences of which should be reduced to one
|
||||
@@ -67,13 +67,13 @@
|
||||
* <cString> to a single one. It is important to note that the multiple
|
||||
* occurences must occur directly one behind the other.
|
||||
* $EXAMPLES$
|
||||
* ? WORDONE("12ABAB12") // "12AB12"
|
||||
* ? WORDONE("1AAAA2") // "1AAAA2"
|
||||
* ? WORDONE("12", "1212ABAB") // "12ABAB"
|
||||
* ? WORDONE( "12ABAB12" ) // "12AB12"
|
||||
* ? WORDONE( "1AAAA2" ) // "1AAAA2"
|
||||
* ? WORDONE( "12", "1212ABAB" ) // "12ABAB"
|
||||
* $TESTS$
|
||||
* WORDONE("12ABAB12") == "12AB12"
|
||||
* WORDONE("1AAAA2") == "1AAAA2"
|
||||
* WORDONE("12", "1212ABAB") == "12ABAB"
|
||||
* WORDONE( "12ABAB12" ) == "12AB12"
|
||||
* WORDONE( "1AAAA2" ) == "1AAAA2"
|
||||
* WORDONE( "12", "1212ABAB" ) == "12ABAB"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Intersectional set of two strings based on characters
|
||||
* $SYNTAX$
|
||||
* CHARONLY (<cThisCharactersOnly>, <cString>) -> cReducedString
|
||||
* CHARONLY( <cThisCharactersOnly>, <cString> ) -> cReducedString
|
||||
* $ARGUMENTS$
|
||||
* <cThisCharactersOnly> specifies the characters that must not be
|
||||
* deleted in <cString>.
|
||||
@@ -23,11 +23,11 @@
|
||||
* strings. To do this, it deletes all characters from <cString> that
|
||||
* do not appear in <cThisCharacterOnly>.
|
||||
* $EXAMPLES$
|
||||
* ? CHARONLY("0123456789", "0211 - 38 99 77") // "0211389977"
|
||||
* ? CHARONLY("0123456789", "0211/ 389 977") // "0211389977"
|
||||
* ? CHARONLY( "0123456789", "0211 - 38 99 77" ) // "0211389977"
|
||||
* ? CHARONLY( "0123456789", "0211/ 389 977" ) // "0211389977"
|
||||
* $TESTS$
|
||||
* CHARONLY("0123456789", "0211 - 38 99 77") == "0211389977"
|
||||
* CHARONLY("0123456789", "0211/ 389 977") == "0211389977"
|
||||
* CHARONLY( "0123456789", "0211 - 38 99 77" ) == "0211389977"
|
||||
* CHARONLY( "0123456789", "0211/ 389 977" ) == "0211389977"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -49,7 +49,7 @@
|
||||
* $ONELINER$
|
||||
* Intersectional set of two strings based on double characters
|
||||
* $SYNTAX$
|
||||
* WORDONLY (<cThisDoubleCharactersOnly>, <cString>) -> cReducedString
|
||||
* WORDONLY( <cThisDoubleCharactersOnly>, <cString> ) -> cReducedString
|
||||
* $ARGUMENTS$
|
||||
* <cThisDoubleCharactersOnly> specifies the double characters that must
|
||||
* not be deleted in <cString>.
|
||||
@@ -62,11 +62,11 @@
|
||||
* strings based on double characters. To do this, it deletes all double
|
||||
* characters from <cString> that do not appear in <cThisDoubleCharacterOnly>.
|
||||
* $EXAMPLES$
|
||||
* ? WORDONLY("AABBCCDD", "XXAAYYBBZZ") // "AABB"
|
||||
* ? WORDONLY("AABBCCDD", "XAAYYYBBZZ") // "BB"
|
||||
* ? WORDONLY( "AABBCCDD", "XXAAYYBBZZ" ) // "AABB"
|
||||
* ? WORDONLY( "AABBCCDD", "XAAYYYBBZZ" ) // "BB"
|
||||
* $TESTS$
|
||||
* WORDONLY("AABBCCDD", "XXAAYYBBZZ") == "AABB"
|
||||
* WORDONLY("AABBCCDD", "XAAYYYBBZZ") == "BB"
|
||||
* WORDONLY( "AABBCCDD", "XXAAYYBBZZ" ) == "AABB"
|
||||
* WORDONLY( "AABBCCDD", "XAAYYYBBZZ" ) == "BB"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -88,7 +88,7 @@
|
||||
* $ONELINER$
|
||||
* Removes characters from a string
|
||||
* $SYNTAX$
|
||||
* CHARREM (<cDeleteThisCharacters>, <cString>) -> cReducedString
|
||||
* CHARREM( <cDeleteThisCharacters>, <cString> ) -> cReducedString
|
||||
* $ARGUMENTS$
|
||||
* <cDeleteThisCharacters> specifies the characters that should
|
||||
* be deleted in <cString>
|
||||
@@ -100,11 +100,11 @@
|
||||
* The CHARREM() function deletes the characters specified in
|
||||
* <cDeleteThisCharacters> from <cString>.
|
||||
* $EXAMPLES$
|
||||
* ? CHARREM(" ", " 1 2 ") // "12"
|
||||
* ? CHARREM("3y", "xyz123") // "xz12"
|
||||
* ? CHARREM( " ", " 1 2 " ) // "12"
|
||||
* ? CHARREM( "3y", "xyz123" ) // "xz12"
|
||||
* $TESTS$
|
||||
* CHARREM(" ", " 1 2 ") == "12"
|
||||
* CHARREM("3y", "xyz123") == "xz12"
|
||||
* CHARREM( " ", " 1 2 " ) == "12"
|
||||
* CHARREM( "3y", "xyz123" ) == "xz12"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -126,7 +126,7 @@
|
||||
* $ONELINER$
|
||||
* Removes characters from a string
|
||||
* $SYNTAX$
|
||||
* WORDREM (<cDeleteThisDoubleCharacters>, <cString>) -> cReducedString
|
||||
* WORDREM( <cDeleteThisDoubleCharacters>, <cString> ) -> cReducedString
|
||||
* $ARGUMENTS$
|
||||
* <cDeleteThisDoubleCharacters> specifies the double characters that
|
||||
* should be deleted in <cString>
|
||||
@@ -139,11 +139,11 @@
|
||||
* The WORDREM() function deletes the double characters specified in
|
||||
* <cDeleteThisDoubleCharacters> from <cString>.
|
||||
* $EXAMPLES$
|
||||
* ? WORDREM("abcd", "0ab1cd") // "0ab1"
|
||||
* ? WORDREM("abcd", "ab0cd1") // "0cd1"
|
||||
* ? WORDREM( "abcd", "0ab1cd" ) // "0ab1"
|
||||
* ? WORDREM( "abcd", "ab0cd1" ) // "0cd1"
|
||||
* $TESTS$
|
||||
* WORDREM("abcd", "0ab1cd") == "0ab1"
|
||||
* WORDREM("abcd", "ab0cd1") == "0cd1"
|
||||
* WORDREM( "abcd", "0ab1cd" ) == "0ab1"
|
||||
* WORDREM( "abcd", "ab0cd1" ) == "0cd1"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Adds corresponding ASCII value of two strings
|
||||
* $SYNTAX$
|
||||
* CHARADD (<[@]cString1>, <cString2>) --> cAddString
|
||||
* CHARADD( <[@]cString1>, <cString2> ) --> cAddString
|
||||
* $ARGUMENTS$
|
||||
* <[@]cString1> first string
|
||||
* <cString2> second string
|
||||
@@ -28,14 +28,14 @@
|
||||
* <cString2> has been processed, the function restarts with the first
|
||||
* character of <cString2>.
|
||||
* $EXAMPLES$
|
||||
* ? charadd ("012345678", chr(1)) --> "123456789"
|
||||
* ? charadd ("123456789", chr(255)) --> "012345678"
|
||||
* ? charadd ("0000", chr(0)+chr(1)+chr(2)+chr(3)) --> "0123"
|
||||
* ? charadd( "012345678", chr( 1 ) ) // --> "123456789"
|
||||
* ? charadd( "123456789", chr( 255 ) ) // --> "012345678"
|
||||
* ? charadd( "0000", chr( 0 ) + chr( 1 ) + chr( 2 ) + chr( 3 ) ) // --> "0123"
|
||||
* $TESTS$
|
||||
* charadd ("012345678", chr(1)) == "123456789"
|
||||
* charadd ("012345678", chr(1)+chr(2)) == "133557799"
|
||||
* charadd ("123456789", chr(255)) == "012345678"
|
||||
* charadd ("123456789", chr(255)+chr(254)) == "002244668"
|
||||
* charadd( "012345678", chr( 1 ) ) == "123456789"
|
||||
* charadd( "012345678", chr( 1 ) + chr( 2 ) ) == "133557799"
|
||||
* charadd( "123456789", chr( 255 ) ) == "012345678"
|
||||
* charadd( "123456789", chr( 255 ) + chr( 254 ) ) == "002244668"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -60,7 +60,7 @@
|
||||
* $ONELINER$
|
||||
* Combine corresponding ASCII value of two strings with bitwise AND
|
||||
* $SYNTAX$
|
||||
* CHARAND (<[@]cString1>, <cString2>) --> cAndString
|
||||
* CHARAND( <[@]cString1>, <cString2> ) --> cAndString
|
||||
* $ARGUMENTS$
|
||||
* <[@]cString1> first string
|
||||
* <cString2> second string
|
||||
@@ -80,11 +80,11 @@
|
||||
* character of <cString2>.
|
||||
* $EXAMPLES$
|
||||
* // clear the LSB
|
||||
* ? charand ("012345678", chr(254)) --> "002244668"
|
||||
* ? charand ("012345678", chr(254)+chr(252)) --> "002044648"
|
||||
* ? charand( "012345678", chr( 254 ) ) // --> "002244668"
|
||||
* ? charand( "012345678", chr( 254 ) + chr( 252 ) ) // --> "002044648"
|
||||
* $TESTS$
|
||||
* charand ("012345678", chr(254)) == "002244668"
|
||||
* charand ("012345678", chr(254)+chr(252)) == "002044648"
|
||||
* charand( "012345678", chr( 254 ) ) == "002244668"
|
||||
* charand( "012345678", chr( 254 ) + chr( 252 ) ) == "002044648"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -109,7 +109,7 @@
|
||||
* $ONELINER$
|
||||
* Process each character in a string with bitwise NOT operation
|
||||
* $SYNTAX$
|
||||
* CHARNOT (<[@]cString>) --> cNotString
|
||||
* CHARNOT( <[@]cString> ) --> cNotString
|
||||
* $ARGUMENTS$
|
||||
* <[@]cString> string to be processed
|
||||
* $RETURNS$
|
||||
@@ -125,11 +125,11 @@
|
||||
* stored in <cString>, too. By setting the CSETREF()-switch to .T.,
|
||||
* the return value can be omitted.
|
||||
* $EXAMPLES$
|
||||
* ? charnot (chr(85)+chr(128)+chr(170)+chr(1)) --> chr(170)+chr(127)+chr(85)+chr(254)
|
||||
* ? charnot (charnot ("This is a test!")) --> "This is a test!"
|
||||
* ? charnot( chr( 85 ) + chr( 128 ) + chr( 170 ) + chr( 1 ) ) // --> chr( 170 ) + chr( 127 ) + chr( 85 ) + chr( 254 )
|
||||
* ? charnot( charnot( "This is a test!" ) ) --> "This is a test!"
|
||||
* $TESTS$
|
||||
* charnot (chr(85)+chr(128)+chr(170)+chr(1)) == chr(170)+chr(127)+chr(85)+chr(254)
|
||||
* charnot (charnot ("This is a test!")) == "This is a test!"
|
||||
* charnot( chr( 85 ) + chr( 128 ) + chr( 170 ) + chr( 1 ) ) == chr( 170 ) + chr( 127 ) + chr( 85 ) + chr( 254 )
|
||||
* charnot( charnot( "This is a test!" ) ) == "This is a test!"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -154,7 +154,7 @@
|
||||
* $ONELINER$
|
||||
* Combine corresponding ASCII value of two strings with bitwise OR
|
||||
* $SYNTAX$
|
||||
* CHAROR (<[@]cString1>, <cString2>) --> cOrString
|
||||
* CHAROR( <[@]cString1>, <cString2> ) --> cOrString
|
||||
* $ARGUMENTS$
|
||||
* <[@]cString1> first string
|
||||
* <cString2> second string
|
||||
@@ -174,11 +174,11 @@
|
||||
* character of <cString2>.
|
||||
* $EXAMPLES$
|
||||
* // set the LSB
|
||||
* ? charor ("012345678", chr(1)) --> "113355779"
|
||||
* ? charor ("012345678", chr(1)+chr(3)) --> "133357779"
|
||||
* ? charor( "012345678", chr( 1 ) ) // --> "113355779"
|
||||
* ? charor( "012345678", chr( 1 ) + chr( 3 ) ) // --> "133357779"
|
||||
* $TESTS$
|
||||
* charor ("012345678", chr(1)) == "113355779"
|
||||
* charor ("012345678", chr(1)+chr(3)) == "133357779"
|
||||
* charor( "012345678", chr( 1 ) ) == "113355779"
|
||||
* charor( "012345678", chr( 1 ) + chr( 3 ) ) == "133357779"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -203,7 +203,7 @@
|
||||
* $ONELINER$
|
||||
* Combine corresponding ASCII value of two strings with bitwise XOR
|
||||
* $SYNTAX$
|
||||
* CHARXOR (<[@]cString1>, <cString2>) --> cXOrString
|
||||
* CHARXOR( <[@]cString1>, <cString2> ) --> cXOrString
|
||||
* $ARGUMENTS$
|
||||
* <[@]cString1> first string
|
||||
* <cString2> second string
|
||||
@@ -223,9 +223,9 @@
|
||||
* character of <cString2>.
|
||||
* $EXAMPLES$
|
||||
* // easy encryption
|
||||
* ? charxor ("This is top secret !", "My Password") --> <encrypted sentence>
|
||||
* ? charxor( "This is top secret !", "My Password" ) // --> <encrypted sentence>
|
||||
* $TESTS$
|
||||
* charxor (charxor ("This is top secret !", "My Password"), "My Password") == "This is top secret !"
|
||||
* charxor( charxor( "This is top secret !", "My Password" ), "My Password" ) == "This is top secret !"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Subtracts corresponding ASCII value of two strings
|
||||
* $SYNTAX$
|
||||
* CHARSUB (<[@]cString1>, <cString2>) --> cSubString
|
||||
* CHARSUB( <[@]cString1>, <cString2>) --> cSubString
|
||||
* $ARGUMENTS$
|
||||
* <[@]cString1> first string
|
||||
* <cString2> second string
|
||||
@@ -28,14 +28,14 @@
|
||||
* <cString2> has been processed, the function restarts with the first
|
||||
* character of <cString2>.
|
||||
* $EXAMPLES$
|
||||
* ? charsub ("012345678", chr(1)) --> "/01234567"
|
||||
* ? charsub ("123456789", chr(255)) --> "23456789:"
|
||||
* ? charsub ("9999", chr(0)+chr(1)+chr(2)+chr(3)) --> "9876"
|
||||
* ? charsub( "012345678", Chr( 1 ) ) // --> "/01234567"
|
||||
* ? charsub( "123456789", Chr( 255 ) ) // --> "23456789:"
|
||||
* ? charsub( "9999", Chr( 0 ) + Chr( 1 ) + Chr( 2 ) + Chr( 3 ) ) // --> "9876"
|
||||
* $TESTS$
|
||||
* charsub ("123456789", chr(1)) == "012345678"
|
||||
* charsub ("123456789", chr(1)+chr(2)) == "002244668"
|
||||
* charsub ("012345678", chr(255)) == "123456789"
|
||||
* charsub ("012345678", chr(255)+chr(254)) == "133557799"
|
||||
* charsub( "123456789", Chr( 1 ) ) == "012345678"
|
||||
* charsub( "123456789", Chr( 1 ) + Chr( 2 ) ) == "002244668"
|
||||
* charsub( "012345678", Chr( 255 ) ) == "123456789"
|
||||
* charsub( "012345678", Chr( 255 ) + Chr( 254 ) ) == "133557799"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -60,7 +60,7 @@
|
||||
* $ONELINER$
|
||||
* Process each character in a string with bitwise SHIFT LEFT operation
|
||||
* $SYNTAX$
|
||||
* CHARSHL (<[@]cString>, <nBitsToSHL> ) --> cSHLString
|
||||
* CHARSHL( <[@]cString>, <nBitsToSHL> ) --> cSHLString
|
||||
* $ARGUMENTS$
|
||||
* <[@]cString> string to be processed
|
||||
* <nBitsToSHL> number of bit positions to be shifted to the left
|
||||
@@ -78,10 +78,10 @@
|
||||
* stored in <cString>, too. By setting the CSETREF()-switch to .T.,
|
||||
* the return value can be omitted.
|
||||
* $EXAMPLES$
|
||||
* ? charshl (chr(1)+chr(2)+chr(4)+chr(8)+chr(16)+chr(32)+chr(64)+chr(128), 3)
|
||||
* --> chr(8)+chr(16)+chr(32)+chr(64)+chr(128)+chr(0)+chr(0)+chr(0)
|
||||
* ? charshl( Chr(1)+Chr(2)+Chr(4)+Chr(8)+Chr(16)+Chr(32)+Chr(64)+Chr(128), 3 )
|
||||
* // --> Chr(8)+Chr(16)+Chr(32)+Chr(64)+Chr(128)+Chr(0)+Chr(0)+Chr(0)
|
||||
* $TESTS$
|
||||
* charshl (chr(1)+chr(2)+chr(4)+chr(8)+chr(16)+chr(32)+chr(64)+chr(128), 3) == chr(8)+chr(16)+chr(32)+chr(64)+chr(128)+chr(0)+chr(0)+chr(0)
|
||||
* charshl( Chr(1)+Chr(2)+Chr(4)+Chr(8)+Chr(16)+Chr(32)+Chr(64)+Chr(128), 3 ) == Chr(8)+Chr(16)+Chr(32)+Chr(64)+Chr(128)+Chr(0)+Chr(0)+Chr(0)
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -106,7 +106,7 @@
|
||||
* $ONELINER$
|
||||
* Process each character in a string with bitwise SHIFT RIGHT operation
|
||||
* $SYNTAX$
|
||||
* CHARSHR (<[@]cString>, <nBitsToSHR> ) --> cSHRString
|
||||
* CHARSHR( <[@]cString>, <nBitsToSHR> ) --> cSHRString
|
||||
* $ARGUMENTS$
|
||||
* <[@]cString> string to be processed
|
||||
* <nBitsToSHR> number of bit positions to be shifted to the right
|
||||
@@ -124,10 +124,10 @@
|
||||
* stored in <cString>, too. By setting the CSETREF()-switch to .T.,
|
||||
* the return value can be omitted.
|
||||
* $EXAMPLES$
|
||||
* ? charshr (chr(1)+chr(2)+chr(4)+chr(8)+chr(16)+chr(32)+chr(64)+chr(128), 3)
|
||||
* --> chr(0)+chr(0)+chr(0)+chr(1)+chr(2)+chr(4)+chr(8)+chr(16)
|
||||
* ? charshr( Chr(1)+Chr(2)+Chr(4)+Chr(8)+Chr(16)+Chr(32)+Chr(64)+Chr(128), 3 )
|
||||
* // --> Chr(0)+Chr(0)+Chr(0)+Chr(1)+Chr(2)+Chr(4)+Chr(8)+Chr(16)
|
||||
* $TESTS$
|
||||
* charshr (chr(1)+chr(2)+chr(4)+chr(8)+chr(16)+chr(32)+chr(64)+chr(128), 3) == chr(0)+chr(0)+chr(0)+chr(1)+chr(2)+chr(4)+chr(8)+chr(16)
|
||||
* charshr( Chr(1)+Chr(2)+Chr(4)+Chr(8)+Chr(16)+Chr(32)+Chr(64)+Chr(128), 3 ) == Chr(0)+Chr(0)+Chr(0)+Chr(1)+Chr(2)+Chr(4)+Chr(8)+Chr(16)
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -152,7 +152,7 @@
|
||||
* $ONELINER$
|
||||
* Process each character in a string with bitwise ROLL LEFT operation
|
||||
* $SYNTAX$
|
||||
* CHARRLL (<[@]cString>, <nBitsToRLL> ) --> cRLLString
|
||||
* CHARRLL( <[@]cString>, <nBitsToRLL> ) --> cRLLString
|
||||
* $ARGUMENTS$
|
||||
* <[@]cString> string to be processed
|
||||
* <nBitsToRLL> number of bit positions to be rolled to the left
|
||||
@@ -170,10 +170,10 @@
|
||||
* stored in <cString>, too. By setting the CSETREF()-switch to .T.,
|
||||
* the return value can be omitted.
|
||||
* $EXAMPLES$
|
||||
* ? charrll (chr(1)+chr(2)+chr(4)+chr(8)+chr(16)+chr(32)+chr(64)+chr(128), 3)
|
||||
* --> chr(8)+chr(16)+chr(32)+chr(64)+chr(128)+chr(1)+chr(2)+chr(4)
|
||||
* ? charrll( Chr(1)+Chr(2)+Chr(4)+Chr(8)+Chr(16)+Chr(32)+Chr(64)+Chr(128), 3 )
|
||||
* // --> Chr(8)+Chr(16)+Chr(32)+Chr(64)+Chr(128)+Chr(1)+Chr(2)+Chr(4)
|
||||
* $TESTS$
|
||||
* charrll (chr(1)+chr(2)+chr(4)+chr(8)+chr(16)+chr(32)+chr(64)+chr(128), 3) == chr(8)+chr(16)+chr(32)+chr(64)+chr(128)+chr(1)+chr(2)+chr(4)
|
||||
* charrll( Chr(1)+Chr(2)+Chr(4)+Chr(8)+Chr(16)+Chr(32)+Chr(64)+Chr(128), 3 ) == Chr(8)+Chr(16)+Chr(32)+Chr(64)+Chr(128)+Chr(1)+Chr(2)+Chr(4)
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -198,7 +198,7 @@
|
||||
* $ONELINER$
|
||||
* Process each character in a string with bitwise ROLL RIGHT operation
|
||||
* $SYNTAX$
|
||||
* CHARRLR (<[@]cString>, <nBitsToRLR> ) --> cRLRString
|
||||
* CHARRLR( <[@]cString>, <nBitsToRLR> ) --> cRLRString
|
||||
* $ARGUMENTS$
|
||||
* <[@]cString> string to be processed
|
||||
* <nBitsToRLR> number of bit positions to be rolled to the right
|
||||
@@ -216,10 +216,10 @@
|
||||
* stored in <cString>, too. By setting the CSETREF()-switch to .T.,
|
||||
* the return value can be omitted.
|
||||
* $EXAMPLES$
|
||||
* ? charrlr (chr(1)+chr(2)+chr(4)+chr(8)+chr(16)+chr(32)+chr(64)+chr(128), 3)
|
||||
* --> chr(32)+chr(64)+chr(128)+chr(1)+chr(2)+chr(4)+chr(8)+chr(16)
|
||||
* ? charrlr( Chr(1)+Chr(2)+Chr(4)+Chr(8)+Chr(16)+Chr(32)+Chr(64)+Chr(128), 3 )
|
||||
* // --> Chr(32)+Chr(64)+Chr(128)+Chr(1)+Chr(2)+Chr(4)+Chr(8)+Chr(16)
|
||||
* $TESTS$
|
||||
* charrlr (chr(1)+chr(2)+chr(4)+chr(8)+chr(16)+chr(32)+chr(64)+chr(128), 3) == chr(32)+chr(64)+chr(128)+chr(1)+chr(2)+chr(4)+chr(8)+chr(16)
|
||||
* charrlr( Chr(1)+Chr(2)+Chr(4)+Chr(8)+Chr(16)+Chr(32)+Chr(64)+Chr(128), 3 ) == Chr(32)+Chr(64)+Chr(128)+Chr(1)+Chr(2)+Chr(4)+Chr(8)+Chr(16)
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -10,8 +10,8 @@
|
||||
* $ONELINER$
|
||||
* Replacement of characters
|
||||
* $SYNTAX$
|
||||
* CHARREPL (<cSearchString>, <[@]cString>,
|
||||
* <cReplaceString>, [<lMode>]) -> cString
|
||||
* CHARREPL( <cSearchString>, <[@]cString>,
|
||||
* <cReplaceString>, [<lMode>] ) -> cString
|
||||
* $ARGUMENTS$
|
||||
* <cSearchString> is a string of characters that should be replaced
|
||||
* <[@]cString> is the processed string
|
||||
@@ -41,17 +41,17 @@
|
||||
* One can omit the return value by setting the CSETREF() switch to .T.,
|
||||
* but then one must pass <cString> by reference to get the result.
|
||||
* $EXAMPLES$
|
||||
* ? charrepl ("1234", "1x2y3z", "abcd") // "axbycz"
|
||||
* ? charrepl ("abcdefghij", "jhfdb", "1234567890") // "08642"
|
||||
* ? charrepl ("abcdefghij", "jhfdb", "12345") // "55542"
|
||||
* ? charrepl ("1234", "1234", "234A") // "AAAA"
|
||||
* ? charrepl ("1234", "1234", "234A", .T.) // "234A"
|
||||
* ? charrepl( "1234", "1x2y3z", "abcd" ) // "axbycz"
|
||||
* ? charrepl( "abcdefghij", "jhfdb", "1234567890" ) // "08642"
|
||||
* ? charrepl( "abcdefghij", "jhfdb", "12345" ) // "55542"
|
||||
* ? charrepl( "1234", "1234", "234A" ) // "AAAA"
|
||||
* ? charrepl( "1234", "1234", "234A", .T. ) // "234A"
|
||||
* $TESTS$
|
||||
* charrepl ("1234", "1x2y3z", "abcd") == "axbycz"
|
||||
* charrepl ("abcdefghij", "jhfdb", "1234567890") == "08642"
|
||||
* charrepl ("abcdefghij", "jhfdb", "12345") == "55542"
|
||||
* charrepl ("1234", "1234", "234A") == "AAAA"
|
||||
* charrepl ("1234", "1234", "234A", .T.) == "234A"
|
||||
* charrepl( "1234", "1x2y3z", "abcd" ) == "axbycz"
|
||||
* charrepl( "abcdefghij", "jhfdb", "1234567890" ) == "08642"
|
||||
* charrepl( "abcdefghij", "jhfdb", "12345" ) == "55542"
|
||||
* charrepl( "1234", "1234", "234A" ) == "AAAA"
|
||||
* charrepl( "1234", "1234", "234A", .T. ) == "234A"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -10,9 +10,9 @@
|
||||
* $ONELINER$
|
||||
* Sort sequences within a string.
|
||||
* $SYNTAX$
|
||||
* CHARSORT (<[@]cString>, [<nElementLength>], [<nCompareLength>],
|
||||
* CHARSORT( <[@]cString>, [<nElementLength>], [<nCompareLength>],
|
||||
* [<nIgnoreCharacters>], [<nElemenOffset>], [<nSortLength>],
|
||||
* [<lDescending>]) -> cSortedString
|
||||
* [<lDescending>] ) -> cSortedString
|
||||
* $ARGUMENTS$
|
||||
* <[@]cString> is the string that should be processed
|
||||
* [<nElementLength>] specifies the length of the elements that
|
||||
@@ -55,21 +55,21 @@
|
||||
* By setting the CSETREF() switch to .T., one can omit the return value
|
||||
* of the function, but one must then pass <cString> by reference.
|
||||
* $EXAMPLES$
|
||||
* ? CHARSORT("qwert") // "eqrtw"
|
||||
* ? CHARSORT("qwert", 2) // "erqwt"
|
||||
* ? CHARSORT("b1a4a3a2a1", 2, 1) // "a2a1a3a4b1"
|
||||
* ? CHARSORT("XXXqwert", 1, 1, 3) // "XXXeqrtw"
|
||||
* ? CHARSORT("b1a4a3a2a1", 2, 1, 0, 1) // "a1b1a2a3a4"
|
||||
* ? CHARSORT("384172852", 1, 1, 0, 0, 4) // "134872852"
|
||||
* ? CHARSORT("qwert", .T.) // "wtrqe"
|
||||
* ? CHARSORT( "qwert" ) // "eqrtw"
|
||||
* ? CHARSORT( "qwert", 2 ) // "erqwt"
|
||||
* ? CHARSORT( "b1a4a3a2a1", 2, 1 ) // "a2a1a3a4b1"
|
||||
* ? CHARSORT( "XXXqwert", 1, 1, 3 ) // "XXXeqrtw"
|
||||
* ? CHARSORT( "b1a4a3a2a1", 2, 1, 0, 1 ) // "a1b1a2a3a4"
|
||||
* ? CHARSORT( "384172852", 1, 1, 0, 0, 4 ) // "134872852"
|
||||
* ? CHARSORT( "qwert", .T. ) // "wtrqe"
|
||||
* $TESTS$
|
||||
* CHARSORT("qwert") == "eqrtw"
|
||||
* CHARSORT("qwert", 2) == "erqwt"
|
||||
* CHARSORT("b1a4a3a2a1", 2, 1) == "a2a1a3a4b1"
|
||||
* CHARSORT("XXXqwert", 1, 1, 3) == "XXXeqrtw"
|
||||
* CHARSORT("b1a4a3a2a1", 2, 1, 0, 1) == "a1b1a2a3a4"
|
||||
* CHARSORT("384172852", 1, 1, 0, 0, 4) == "134872852"
|
||||
* CHARSORT("qwert", .T.) == "wtrqe"
|
||||
* CHARSORT( "qwert" ) == "eqrtw"
|
||||
* CHARSORT( "qwert", 2 ) == "erqwt"
|
||||
* CHARSORT( "b1a4a3a2a1", 2, 1 ) == "a2a1a3a4b1"
|
||||
* CHARSORT( "XXXqwert", 1, 1, 3 ) == "XXXeqrtw"
|
||||
* CHARSORT( "b1a4a3a2a1", 2, 1, 0, 1 ) == "a1b1a2a3a4"
|
||||
* CHARSORT( "384172852", 1, 1, 0, 0, 4 ) == "134872852"
|
||||
* CHARSORT( "qwert", .T. ) == "wtrqe"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Swap neighbouring characters in a string
|
||||
* $SYNTAX$
|
||||
* CHARSWAP (<[@]cString>) -> cSwappedString
|
||||
* CHARSWAP( <[@]cString> ) -> cSwappedString
|
||||
* $ARGUMENTS$
|
||||
* <[@]cString> is the string that should be processed
|
||||
* $RETURNS$
|
||||
@@ -22,11 +22,11 @@
|
||||
* By setting the CSETREF() switch to .T., one can omit the return value
|
||||
* of this functin, but one must then pass <cString> by reference.
|
||||
* $EXAMPLES$
|
||||
* ? CHARSWAP("0123456789") // "1032547698"
|
||||
* ? CHARSWAP("ABCDEFGHIJK") // "BADCFEHGJIK"
|
||||
* ? CHARSWAP( "0123456789" ) // "1032547698"
|
||||
* ? CHARSWAP( "ABCDEFGHIJK" ) // "BADCFEHGJIK"
|
||||
* $TESTS$
|
||||
* CHARSWAP("0123456789") == "1032547698"
|
||||
* CHARSWAP("ABCDEFGHIJK") == "BADCFEHGJIK"
|
||||
* CHARSWAP( "0123456789" ) == "1032547698"
|
||||
* CHARSWAP( "ABCDEFGHIJK" ) == "BADCFEHGJIK"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -48,7 +48,7 @@
|
||||
* $ONELINER$
|
||||
* Swap neighbouring double characters in a string
|
||||
* $SYNTAX$
|
||||
* WORDSWAP (<[@]cString> [, <lSwapCharacters>]) -> cSwappedString
|
||||
* WORDSWAP( <[@]cString> [, <lSwapCharacters>] ) -> cSwappedString
|
||||
* $ARGUMENTS$
|
||||
* <[@]cString> is the string that should be processed
|
||||
* [<lSwapCharacters>] specifies whether an additional swap should be
|
||||
@@ -66,11 +66,11 @@
|
||||
* By setting the CSETREF() switch to .T., one can omit the return value
|
||||
* of this functin, but one must then pass <cString> by reference.
|
||||
* $EXAMPLES$
|
||||
* ? WORDSWAP("1234567890") // "3412785690"
|
||||
* ? WORDSWAP("1234567890", .t.) // "4321876590"
|
||||
* ? WORDSWAP( "1234567890" ) // "3412785690"
|
||||
* ? WORDSWAP( "1234567890", .T. ) // "4321876590"
|
||||
* $TESTS$
|
||||
* WORDSWAP("1234567890") == "3412785690"
|
||||
* WORDSWAP("1234567890", .t.) == "4321876590"
|
||||
* WORDSWAP( "1234567890" ) == "3412785690"
|
||||
* WORDSWAP( "1234567890", .T. ) == "4321876590"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -42,7 +42,7 @@
|
||||
* $ONELINER$
|
||||
*
|
||||
* $SYNTAX$
|
||||
* COLORTON ( <cAttr> ) -> <nAttr>
|
||||
* COLORTON( <cAttr> ) -> <nAttr>
|
||||
* $ARGUMENTS$
|
||||
* <cAttr> Designates the alphanumeric color attribute that is
|
||||
* converted in NN/NN or CC/CC form.
|
||||
@@ -85,7 +85,7 @@
|
||||
* $ONELINER$
|
||||
*
|
||||
* $SYNTAX$
|
||||
* NTOCOLOR ( <nAttr>, [<lColorCode>] ) -> <cAttr>
|
||||
* NTOCOLOR( <nAttr>, [<lColorCode>] ) -> <cAttr>
|
||||
* $ARGUMENTS$
|
||||
* <nAttr> Designates the value for the combined numeric color
|
||||
* attributes.
|
||||
@@ -130,7 +130,7 @@
|
||||
* $ONELINER$
|
||||
* Select the "ENHANCED" color value for output
|
||||
* $SYNTAX$
|
||||
* ENHANCED () -> <cEmptyString>
|
||||
* ENHANCED() -> <cEmptyString>
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -162,7 +162,7 @@
|
||||
* $ONELINER$
|
||||
* Select the "STANDARD" color value for output
|
||||
* $SYNTAX$
|
||||
* STANDARD () -> <cEmptyString>
|
||||
* STANDARD() -> <cEmptyString>
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -194,7 +194,7 @@
|
||||
* $ONELINER$
|
||||
* Select the "UNSELECTED" color value for output
|
||||
* $SYNTAX$
|
||||
* UNSELECTED () -> <cEmptyString>
|
||||
* UNSELECTED() -> <cEmptyString>
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Count a certain character at the beginning of a string
|
||||
* $SYNTAX$
|
||||
* COUNTLEFT (<cString>, [<cSearch|nSearch>]) -> nCount
|
||||
* COUNTLEFT( <cString>, [<cSearch|nSearch>] ) -> nCount
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -42,7 +42,7 @@
|
||||
* $ONELINER$
|
||||
* Count a certain character at the end of a string
|
||||
* $SYNTAX$
|
||||
* COUNTRIGHT (<cString>, [<cSearch|nSearch>]) -> nCount
|
||||
* COUNTRIGHT( <cString>, [<cSearch|nSearch>] ) -> nCount
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Initializes the CT3 library
|
||||
* $SYNTAX$
|
||||
* CTINIT () -> lInitialized
|
||||
* CTINIT() -> lInitialized
|
||||
* $ARGUMENTS$
|
||||
* None
|
||||
* $RETURNS$
|
||||
@@ -46,7 +46,7 @@
|
||||
* $ONELINER$
|
||||
* Uninitializes the CT3 library
|
||||
* $SYNTAX$
|
||||
* CTEXIT () -> nil
|
||||
* CTEXIT() -> nil
|
||||
* $ARGUMENTS$
|
||||
* none
|
||||
* $RETURNS$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Sets argument error behaviour
|
||||
* $SYNTAX$
|
||||
* CSETARGERR ([<nNewMode>]) -> <nOldMode>
|
||||
* CSETARGERR( [<nNewMode>] ) -> <nOldMode>
|
||||
* $ARGUMENTS$
|
||||
* [<nNewMode>] New argument error throwing mode
|
||||
* $RETURNS$
|
||||
@@ -53,7 +53,7 @@
|
||||
* $ONELINER$
|
||||
* Initializes the CT3 library, C part
|
||||
* $SYNTAX$
|
||||
* CTCINIT () -> lInitialized
|
||||
* CTCINIT() -> lInitialized
|
||||
* $ARGUMENTS$
|
||||
* None
|
||||
* $RETURNS$
|
||||
@@ -86,7 +86,7 @@
|
||||
* $ONELINER$
|
||||
* Uninitializes the CT3 library, C part
|
||||
* $SYNTAX$
|
||||
* CTCEXIT () -> nil
|
||||
* CTCEXIT() -> NIL
|
||||
* $ARGUMENTS$
|
||||
* none
|
||||
* $RETURNS$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Set precision of math functions
|
||||
* $SYNTAX$
|
||||
* SETPREC (<nPrecision>) -> cEmptyString
|
||||
* SETPREC( <nPrecision> ) -> cEmptyString
|
||||
* $ARGUMENTS$
|
||||
* <nPrecision> digit count between 1 and 16, defaults to 16
|
||||
* $RETURNS$
|
||||
@@ -43,7 +43,7 @@
|
||||
* $ONELINER$
|
||||
* Get precision of math functions
|
||||
* $SYNTAX$
|
||||
* GETPREC () -> nDigits
|
||||
* GETPREC() -> nDigits
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Rounds down a number to the next integer
|
||||
* $SYNTAX$
|
||||
* FLOOR (nNumber) -> nDownRoundedNumber
|
||||
* FLOOR( <nNumber> ) -> nDownRoundedNumber
|
||||
* $ARGUMENTS$
|
||||
* <nNumber> number to round down
|
||||
* $RETURNS$
|
||||
@@ -19,11 +19,11 @@
|
||||
* The function FLOOR() determines the biggest integer that is smaller
|
||||
* than <nNumber>.
|
||||
* $EXAMPLES$
|
||||
* ? floor (1.1) --> 1.0
|
||||
* ? floor (-1.1) --> -2.0
|
||||
* ? floor( 1.1 ) // --> 1.0
|
||||
* ? floor( -1.1 ) // --> -2.0
|
||||
* $TESTS$
|
||||
* floor (1.1) == 1.0
|
||||
* floor (-1.1) == -2.0
|
||||
* floor( 1.1 ) == 1.0
|
||||
* floor( -1.1 ) == -2.0
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -45,7 +45,7 @@
|
||||
* $ONELINER$
|
||||
* Rounds up a number to the next integer
|
||||
* $SYNTAX$
|
||||
* CEILING (nNumber) -> nUpRoundedNumber
|
||||
* CEILING( <nNumber> ) -> nUpRoundedNumber
|
||||
* $ARGUMENTS$
|
||||
* <nNumber> number to round up
|
||||
* $RETURNS$
|
||||
@@ -54,11 +54,11 @@
|
||||
* The function CEILING() determines the smallest integer that is bigger
|
||||
* than <nNumber>.
|
||||
* $EXAMPLES$
|
||||
* ? ceiling (1.1) --> 2.0
|
||||
* ? ceiling (-1.1) --> -1.0
|
||||
* ? ceiling( 1.1 ) // --> 2.0
|
||||
* ? ceiling( -1.1 ) // --> -1.0
|
||||
* $TESTS$
|
||||
* ceiling (1.1) == 2.0
|
||||
* ceiling (-1.1) == -1.0
|
||||
* ceiling( 1.1 ) == 2.0
|
||||
* ceiling( -1.1 ) == -1.0
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -80,7 +80,7 @@
|
||||
* $ONELINER$
|
||||
* Sign of a number
|
||||
* $SYNTAX$
|
||||
* SIGN (nNumber) -> nSign
|
||||
* SIGN( <nNumber> ) -> nSign
|
||||
* $ARGUMENTS$
|
||||
* <nNumber> a number
|
||||
* $RETURNS$
|
||||
@@ -91,13 +91,13 @@
|
||||
* If <nNumber> is < 0, then SIGN(<nNumber>) returns -1
|
||||
* If <nNumber> is == 0, then SIGN(<nNumber>) returns 0
|
||||
* $EXAMPLES$
|
||||
* ? sign (1.1) --> 1
|
||||
* ? sign (-1.1) --> -1
|
||||
* ? sign (0.0) --> 0
|
||||
* ? sign( 1.1 ) // --> 1
|
||||
* ? sign( -1.1 ) // --> -1
|
||||
* ? sign( 0.0 ) // --> 0
|
||||
* $TESTS$
|
||||
* sign (1.1) == 1
|
||||
* sign (-1.1) == -1
|
||||
* sign (0.0) == 0
|
||||
* sign( 1.1 ) == 1
|
||||
* sign( -1.1 ) == -1
|
||||
* sign( 0.0 ) == 0
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -119,7 +119,7 @@
|
||||
* $ONELINER$
|
||||
* Decadic logarithm of a number
|
||||
* $SYNTAX$
|
||||
* LOG10 (nNumber) -> nLogarithm
|
||||
* LOG10( <nNumber> ) -> nLogarithm
|
||||
* $ARGUMENTS$
|
||||
* <nNumber> number to logarithm
|
||||
* $RETURNS$
|
||||
@@ -128,11 +128,11 @@
|
||||
* The function LOG10() calculates the decadic logarithm of <nNumber>,
|
||||
* i.e. 10^<nLogarithm> == <nNumber>.
|
||||
* $EXAMPLES$
|
||||
* ? log10 (10.0) --> 1.0
|
||||
* ? log10 (sqrt(10.0)) --> 0.5
|
||||
* ? log10( 10.0 ) // --> 1.0
|
||||
* ? log10( sqrt( 10.0 ) ) // --> 0.5
|
||||
* $TESTS$
|
||||
* log10 (10.0) == 1.0
|
||||
* log10 (sqrt(10.0)) == 0.5
|
||||
* log10( 10.0 ) == 1.0
|
||||
* log10( sqrt( 10.0 ) ) == 0.5
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -154,7 +154,7 @@
|
||||
* $ONELINER$
|
||||
* Calculates faculty
|
||||
* $SYNTAX$
|
||||
* FACT (nNumber) -> nFaculty
|
||||
* FACT( <nNumber> ) -> nFaculty
|
||||
* $ARGUMENTS$
|
||||
* <nNumber> number between 0 and 21
|
||||
* $RETURNS$
|
||||
@@ -165,13 +165,13 @@
|
||||
* used in statistics. Note, that faculties above 21 are too big
|
||||
* so that the function must return a -1.
|
||||
* $EXAMPLES$
|
||||
* ? fact (0) --> 1
|
||||
* ? fact (1) --> 1
|
||||
* ? fact (4) --> 24
|
||||
* ? fact( 0 ) // --> 1
|
||||
* ? fact( 1 ) // --> 1
|
||||
* ? fact( 4 ) // --> 24
|
||||
* $TESTS$
|
||||
* fact (0) == 1
|
||||
* fact (1) == 1
|
||||
* fact (4) == 24
|
||||
* fact( 0 ) == 1
|
||||
* fact( 1 ) == 1
|
||||
* fact( 4 ) == 24
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Fills string to a certain length on the left
|
||||
* $SYNTAX$
|
||||
* PADLEFT (<cString>,<nLength>, [<cChar|nChar>]) -> cString
|
||||
* PADLEFT( <cString>, <nLength>, [<cChar|nChar>] ) -> cString
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -42,7 +42,7 @@
|
||||
* $ONELINER$
|
||||
* Fills string to a certain length on the right
|
||||
* $SYNTAX$
|
||||
* PADRIGHT (<cString>,<nLength>, [<cChar|nChar>]) -> cString
|
||||
* PADRIGHT( <cString>, <nLength>, [<cChar|nChar>] ) -> cString
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Determine return value of reference sensitive CT3 string functions
|
||||
* $SYNTAX$
|
||||
* CSETREF ([<lNewSwitch>]) -> lOldSwitch
|
||||
* CSETREF( [<lNewSwitch>] ) -> lOldSwitch
|
||||
* $ARGUMENTS$
|
||||
* [<lNewSwitch>] .T. -> suppress return value
|
||||
* .F. -> do not suppress return value
|
||||
@@ -72,7 +72,7 @@
|
||||
* $ONELINER$
|
||||
* Determine "multi-pass" behaviour in some string functions
|
||||
* $SYNTAX$
|
||||
* CSETATMUPA ([<lNewSwitch>]) -> lOldSwitch
|
||||
* CSETATMUPA( [<lNewSwitch>] ) -> lOldSwitch
|
||||
* $ARGUMENTS$
|
||||
* [<lNewSwitch>] .T. -> turn "multi-pass" on
|
||||
* .F. -> turn "multi-pass" off
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* _B_egin _O_f _M_onth
|
||||
* $SYNTAX$
|
||||
* BOM ([<dDate>]) -> dDateBeginOfMonth
|
||||
* BOM( [<dDate>] ) -> dDateBeginOfMonth
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -42,7 +42,7 @@
|
||||
* $ONELINER$
|
||||
* _E_nd _O_f _M_onth
|
||||
* $SYNTAX$
|
||||
* EOM ([<dDate>]) -> dDateEndOfMonth
|
||||
* EOM( [<dDate>] ) -> dDateEndOfMonth
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -74,7 +74,7 @@
|
||||
* $ONELINER$
|
||||
* _B_egin _O_f _Q_uarter
|
||||
* $SYNTAX$
|
||||
* BOQ ([<dDate>]) -> dDateBeginOfQuarter
|
||||
* BOQ( [<dDate>] ) -> dDateBeginOfQuarter
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -106,7 +106,7 @@
|
||||
* $ONELINER$
|
||||
* _E_nd _O_f _Q_uarter
|
||||
* $SYNTAX$
|
||||
* EOQ ([<dDate>]) -> dDateEndOfQuarter
|
||||
* EOQ( [<dDate>] ) -> dDateEndOfQuarter
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -138,7 +138,7 @@
|
||||
* $ONELINER$
|
||||
* _B_egin _O_f _Y_ear
|
||||
* $SYNTAX$
|
||||
* BOY ([<dDate>]) -> dDateBeginOfYear
|
||||
* BOY( [<dDate>] ) -> dDateBeginOfYear
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -170,7 +170,7 @@
|
||||
* $ONELINER$
|
||||
* _E_nd _O_f _Y_ear
|
||||
* $SYNTAX$
|
||||
* EOY ([<dDate>]) -> dDateEndOfYear
|
||||
* EOY( [<dDate>] ) -> dDateEndOfYear
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* convert name of day of the week to its ordinal number
|
||||
* $SYNTAX$
|
||||
* CTODOW (<cName>) -> nOrdinal
|
||||
* CTODOW( <cName> ) -> nOrdinal
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -42,7 +42,7 @@
|
||||
* $ONELINER$
|
||||
* convert name of month to its ordinal number
|
||||
* $SYNTAX$
|
||||
* CTOMONTH (<cName>) -> nOrdinal
|
||||
* CTOMONTH( <cName> ) -> nOrdinal
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -74,7 +74,7 @@
|
||||
* $ONELINER$
|
||||
* Returns the date as a string in DD Month YY format
|
||||
* $SYNTAX$
|
||||
* DMY ([<dDate>][, <lMode>]) -> cDateString
|
||||
* DMY( [<dDate>][, <lMode>] ) -> cDateString
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -108,7 +108,7 @@
|
||||
* $ONELINER$
|
||||
* Returns the date as a string in Month DD, YY or Month DD, YYYY
|
||||
* $SYNTAX$
|
||||
* MDY ([<dDate>]) -> cDateString
|
||||
* MDY( [<dDate>] ) -> cDateString
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -142,7 +142,7 @@
|
||||
* $ONELINER$
|
||||
* add months to a date
|
||||
* $SYNTAX$
|
||||
* ADDMONTH ([<dDate>,] <nMonths>) -> dShiftedDate
|
||||
* ADDMONTH( [<dDate>,] <nMonths> ) -> dShiftedDate
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -174,7 +174,7 @@
|
||||
* $ONELINER$
|
||||
* Determines the day of the year for a specific date
|
||||
* $SYNTAX$
|
||||
* DMY ([<dDate>]) -> nDayOfYear
|
||||
* DMY( [<dDate>] ) -> nDayOfYear
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -208,7 +208,7 @@
|
||||
* $ONELINER$
|
||||
* determines of year of date is a leap year
|
||||
* $SYNTAX$
|
||||
* ISLEAP ([<dDate>]) -> lIsLeap
|
||||
* ISLEAP( [<dDate>] ) -> lIsLeap
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -240,7 +240,7 @@
|
||||
* $ONELINER$
|
||||
* Total number of days from first of Jan to beginning of nMonth.
|
||||
* $SYNTAX$
|
||||
* DAYSTOMONTH (<nMonth>, <lLeapYear>) -> nDaysToMonth
|
||||
* DAYSTOMONTH( <nMonth>, <lLeapYear> ) -> nDaysToMonth
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -306,7 +306,7 @@
|
||||
* $ONELINER$
|
||||
* Returns a number equal to the quarter in which a date falls
|
||||
* $SYNTAX$
|
||||
* QUARTER ([<dDate>]) -> nQuarter
|
||||
* QUARTER( [<dDate>] ) -> nQuarter
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -340,7 +340,7 @@
|
||||
* $ONELINER$
|
||||
* Returns the the number of days in the month.
|
||||
* $SYNTAX$
|
||||
* LASTDAYOM ([<dDate|nMonth>]) -> nDaysInMonth
|
||||
* LASTDAYOM( [<dDate|nMonth>] ) -> nDaysInMonth
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -375,7 +375,7 @@
|
||||
* $ONELINER$
|
||||
* (num of day) -> day name
|
||||
* $SYNTAX$
|
||||
* NTOCDOW (<nDay>) -> cDay
|
||||
* NTOCDOW( <nDay> ) -> cDay
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -407,7 +407,7 @@
|
||||
* $ONELINER$
|
||||
* (num of month ) -> Month Name
|
||||
* $SYNTAX$
|
||||
* NTOCMONTH (<nMonth>) -> cMonth
|
||||
* NTOCMONTH( <nMonth> ) -> cMonth
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -439,14 +439,14 @@
|
||||
* $ONELINER$
|
||||
* Returns the calendar week a number
|
||||
* $SYNTAX$
|
||||
* WEEK ([<dDate>][, <lSWN>]) -> nWeek
|
||||
* WEEK( [<dDate>][, <lSWN>] ) -> nWeek
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
*
|
||||
* $DESCRIPTION$
|
||||
* Returns the calendar week a number. If no date is specified,
|
||||
* the system date is used. An empty date viz ctod(" / / ")
|
||||
* the system date is used. An empty date via hb_SToD("")
|
||||
* returns 0.
|
||||
* If <lSWN> is .T., week() will calculate the "simple week number", defined by
|
||||
* - week #1 starts on January, 1st
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Pauses a specified time in increments of 1/100 seconds
|
||||
* $SYNTAX$
|
||||
* WAITPERIOD([<nDelay>]) --> lNotElapsed
|
||||
* WAITPERIOD( [<nDelay>] ) --> lNotElapsed
|
||||
* $ARGUMENTS$
|
||||
* <nDelay> Designates the waiting period at initialization in
|
||||
* 1/100ths of seconds. Values from 1 to 8, 640, 000 (one day) are
|
||||
@@ -35,9 +35,9 @@
|
||||
* $EXAMPLES$
|
||||
* Run a loop for 5 seconds:
|
||||
*
|
||||
* WAITPERIOD(500) // Initialization, 5 seconds
|
||||
* WAITPERIOD( 500 ) // Initialization, 5 seconds
|
||||
* DO WHILE <cond1> .AND. <cond2> .AND. WAITPERIOD()
|
||||
* *...
|
||||
* *...
|
||||
* ENDDO
|
||||
* $TESTS$
|
||||
*
|
||||
@@ -62,7 +62,7 @@
|
||||
* $ONELINER$
|
||||
* Determines whether a specIFied time is valid
|
||||
* $SYNTAX$
|
||||
* TIMEVALID(<cTime>) --> lValid
|
||||
* TIMEVALID( <cTime> ) --> lValid
|
||||
* $ARGUMENTS$
|
||||
* <cTime> Designates a character string that contains the time to
|
||||
* test.
|
||||
@@ -89,17 +89,17 @@
|
||||
* Using the VALID clause with TRIM, all valid times are
|
||||
* accepted, even IF no seconds or minutes are specIFied:
|
||||
*
|
||||
* cBegin := SPACE(11)
|
||||
* cBegin := SPACE( 11 )
|
||||
* @ 5, 10 SAY "Please input time for beginning work:";
|
||||
* GET cBegin VALID TIMEVALID(TRIM(cBegin))
|
||||
* GET cBegin VALID TIMEVALID( TRIM( cBegin ) )
|
||||
* READ
|
||||
*
|
||||
* Using a VALID clause without TRIM, hours and minutes must be
|
||||
* specified, so that TIMEVALID() can confirm a valid time:
|
||||
*
|
||||
* cBegin := SPACE(5)
|
||||
* cBegin := SPACE( 5 )
|
||||
* @ 5, 10 SAY "Please input time for beginning work:";
|
||||
* GET cBegin VALID TIMEVALID(cBegin)
|
||||
* GET cBegin VALID TIMEVALID( cBegin )
|
||||
* READ
|
||||
* $TESTS$
|
||||
*
|
||||
@@ -124,7 +124,7 @@
|
||||
* $ONELINER$
|
||||
* Sets the system clock
|
||||
* $SYNTAX$
|
||||
* SETTIME(<cTime>, [<lMode>]) --> lSet
|
||||
* SETTIME( <cTime>, [<lMode>] ) --> lSet
|
||||
* $ARGUMENTS$
|
||||
* <cTime> Designates a character string that contains the time that
|
||||
* is to become the system time.
|
||||
@@ -143,16 +143,16 @@
|
||||
* Set the system time in each case; but the hardware clock only
|
||||
* on an AT:
|
||||
*
|
||||
* cNewTime := "10:20:00"
|
||||
* cNewTime := "10:20:00"
|
||||
* IF ISAT()
|
||||
* SETTIME(cNewTime, .T.)
|
||||
* SETTIME( cNewTime, .T. )
|
||||
* ELSE
|
||||
* SETTIME(cNewTime)
|
||||
* SETTIME( cNewTime )
|
||||
* ENDIF
|
||||
*
|
||||
* Or, more compactly:
|
||||
*
|
||||
* SETTIME(cNewTime, ISAT())
|
||||
* SETTIME( cNewTime, ISAT() )
|
||||
* $TESTS$
|
||||
*
|
||||
* $STATUS$
|
||||
@@ -176,7 +176,7 @@
|
||||
* $ONELINER$
|
||||
* Sets the system date
|
||||
* $SYNTAX$
|
||||
* SETDATE(<dDate>, [<lMode>]) --> lSet
|
||||
* SETDATE( <dDate>, [<lMode>] ) --> lSet
|
||||
* $ARGUMENTS$
|
||||
* <dDate> Designates which date to use to set the system date.
|
||||
*
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
*
|
||||
* The following calculation reproduces the original value:
|
||||
*
|
||||
* MANTISSA(<nFloatingPointNumber>)* 2^EXPONENT(<nFloatingPointNumber>) =
|
||||
* MANTISSA( <nFloatingPointNumber> ) * 2 ^ EXPONENT( <nFloatingPointNumber> ) =
|
||||
* <nFloatingPointNumber>
|
||||
*
|
||||
* TODO: add documentation
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Future value of a capital
|
||||
* $SYNTAX$
|
||||
* FV (nDeposit, nInterest, nPeriods) --> nFutureValue
|
||||
* FV( nDeposit, nInterest, nPeriods ) --> nFutureValue
|
||||
* $ARGUMENTS$
|
||||
* <nDeposit> amount of money invested per period
|
||||
* <nInterest> rate of interest per period, 1 == 100%
|
||||
@@ -37,10 +37,10 @@
|
||||
* // Payment of 1000 per year for 10 years at a interest rate
|
||||
* // of 5 per cent per year
|
||||
*
|
||||
* ? fv (1000, 0.05, 10) --> 12577.893
|
||||
* ? fv( 1000, 0.05, 10 ) // --> 12577.893
|
||||
* $TESTS$
|
||||
* fv (1000, 0.00, 10) == 10000.0
|
||||
* fv (1000, 0.05, 10) == 12577.893
|
||||
* fv( 1000, 0.00, 10 ) == 10000.0
|
||||
* fv( 1000, 0.05, 10 ) == 12577.893
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -62,7 +62,7 @@
|
||||
* $ONELINER$
|
||||
* Present value of a loan
|
||||
* $SYNTAX$
|
||||
* PV (nPayment, nInterest, nPeriods) --> nPresentValue
|
||||
* PV( nPayment, nInterest, nPeriods ) --> nPresentValue
|
||||
* $ARGUMENTS$
|
||||
* <nPayment> amount of money paid back per period
|
||||
* <nInterest> rate of interest per period, 1 == 100%
|
||||
@@ -88,10 +88,10 @@
|
||||
* // of 6000 Dollars (the amount you will pay back) the bank will pay
|
||||
* // you
|
||||
*
|
||||
* ? pv (100, 0.005, 60) --> 5172.56
|
||||
* ? pv( 100, 0.005, 60 ) // --> 5172.56
|
||||
* $TESTS$
|
||||
* pv (100, 0.0, 60) == 6000.0
|
||||
* pv (100, 0.005, 60) == 5172.56
|
||||
* pv( 100, 0.0, 60 ) == 6000.0
|
||||
* pv( 100, 0.005, 60 ) == 5172.56
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -113,7 +113,7 @@
|
||||
* $ONELINER$
|
||||
* Payments for a loan
|
||||
* $SYNTAX$
|
||||
* PAYMENT (nLoan, nInterest, nPeriods) --> nPayment
|
||||
* PAYMENT( nLoan, nInterest, nPeriods ) --> nPayment
|
||||
* $ARGUMENTS$
|
||||
* <nLoan> amount of money you get from the bank
|
||||
* <nInterest> rate of interest per period, 1 == 100%
|
||||
@@ -137,10 +137,10 @@
|
||||
* // month (6% per year).
|
||||
* // For 5 years, you have to pay back every month
|
||||
*
|
||||
* ? payment (5172.56, 0.005, 60) --> 100.00
|
||||
* ? payment( 5172.56, 0.005, 60 ) // --> 100.00
|
||||
* $TESTS$
|
||||
* payment (5172.56, 0.0, 60) == 86.21
|
||||
* payment (5172.56, 0.005, 60) == 100.00
|
||||
* payment( 5172.56, 0.0, 60 ) == 86.21
|
||||
* payment( 5172.56, 0.005, 60 ) == 100.00
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -162,7 +162,7 @@
|
||||
* $ONELINER$
|
||||
* Number of periods for a loan
|
||||
* $SYNTAX$
|
||||
* PERIODS (nLoan, nPayment, nInterest) --> nPeriods
|
||||
* PERIODS( nLoan, nPayment, nInterest ) --> nPeriods
|
||||
* $ARGUMENTS$
|
||||
* <nLoan> amount of money you get from the bank
|
||||
* <nPayment> amount of money you pay back per period
|
||||
@@ -189,12 +189,12 @@
|
||||
* // month (6% per year).
|
||||
* // You can afford to pay 100 back every month, so you need
|
||||
*
|
||||
* ? periods (5172.56, 100, 0.005) --> 60.0
|
||||
* ? periods( 5172.56, 100, 0.005 ) // --> 60.0
|
||||
*
|
||||
* // months to cancel the loan.
|
||||
* $TESTS$
|
||||
* periods (5172.56, 100, 0.005) == 60.0
|
||||
* periods (5172.56, 100, 0.0) == 51.7256
|
||||
* periods( 5172.56, 100, 0.005 ) == 60.0
|
||||
* periods( 5172.56, 100, 0.0 ) == 51.7256
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -216,7 +216,7 @@
|
||||
* $ONELINER$
|
||||
* Estimate rate of interest for a loan
|
||||
* $SYNTAX$
|
||||
* RATE (nLoan, nPayment, nPeriods) --> nRate
|
||||
* RATE( nLoan, nPayment, nPeriods ) --> nRate
|
||||
* $ARGUMENTS$
|
||||
* <nLoan> amount of money you get from the bank
|
||||
* <nPayment> amount of money you pay back per period
|
||||
@@ -237,11 +237,11 @@
|
||||
* // 5 years (60 months). The effective interest rate per
|
||||
* // period (=month) is
|
||||
*
|
||||
* ? rate (5172.56, 100, 60) --> 0.005
|
||||
* ? rate( 5172.56, 100, 60 ) // --> 0.005
|
||||
*
|
||||
* $TESTS$
|
||||
* rate (5172.56, 100, 60.0) == 0.005
|
||||
* rate (6000.0, 100, 60.0) == 0.0
|
||||
* rate( 5172.56, 100, 60.0 ) == 0.005
|
||||
* rate( 6000.0, 100, 60.0 ) == 0.0
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Move characters from the beginning to the end of a string
|
||||
* $SYNTAX$
|
||||
* JUSTLEFT (<[@]cString>, [<cChar>|<nChar>]) -> cJustifiedString
|
||||
* JUSTLEFT( <[@]cString>, [<cChar>|<nChar>] ) -> cJustifiedString
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -42,7 +42,7 @@
|
||||
* $ONELINER$
|
||||
* Move characters from the end to the beginning of a string
|
||||
* $SYNTAX$
|
||||
* JUSTRIGHT (<[@]cString>, [<cChar>|<nChar>]) -> cJustifiedString
|
||||
* JUSTRIGHT( <[@]cString>, [<cChar>|<nChar>] ) -> cJustifiedString
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
*
|
||||
* $SYNTAX$
|
||||
* KSETINS ([<lNewSwitch>]) -> lOldSwitch
|
||||
* KSETINS( [<lNewSwitch>] ) -> lOldSwitch
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -42,7 +42,7 @@
|
||||
* $ONELINER$
|
||||
*
|
||||
* $SYNTAX$
|
||||
* KSETCAPS ([<lNewSwitch>]) -> lOldSwitch
|
||||
* KSETCAPS( [<lNewSwitch>] ) -> lOldSwitch
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -74,7 +74,7 @@
|
||||
* $ONELINER$
|
||||
*
|
||||
* $SYNTAX$
|
||||
* KSETNUM ([<lNewSwitch>]) -> lOldSwitch
|
||||
* KSETNUM( [<lNewSwitch>] ) -> lOldSwitch
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -106,7 +106,7 @@
|
||||
* $ONELINER$
|
||||
*
|
||||
* $SYNTAX$
|
||||
* KSETSCROLL ([<lNewSwitch>]) -> lOldSwitch
|
||||
* KSETSCROLL( [<lNewSwitch>] ) -> lOldSwitch
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Temperature conversion Fahrenheit to Celsius
|
||||
* $SYNTAX$
|
||||
* CELSIUS (nDegreeFahrenheit) --> nDegreeCelsius
|
||||
* CELSIUS( nDegreeFahrenheit ) --> nDegreeCelsius
|
||||
* $ARGUMENTS$
|
||||
* <nDegreeFahrenheit> temperature in degree Fahrenheit
|
||||
* $RETURNS$
|
||||
@@ -20,12 +20,12 @@
|
||||
* to the Celsius scale.
|
||||
* $EXAMPLES$
|
||||
* // melting point of water in standard conditions
|
||||
* ? celsius (32.0) --> 0.0
|
||||
* ? celsius( 32.0 ) // --> 0.0
|
||||
* // boiling point of water in standard conditions
|
||||
* ? celsius (212.0) --> 100.0
|
||||
* ? celsius( 212.0 ) // --> 100.0
|
||||
* $TESTS$
|
||||
* celsius (32.0) == 0.0
|
||||
* celsius (212.0) == 100.0
|
||||
* celsius( 32.0 ) == 0.0
|
||||
* celsius( 212.0 ) == 100.0
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -47,7 +47,7 @@
|
||||
* $ONELINER$
|
||||
* Temperature conversion Celsius to Fahrenheit
|
||||
* $SYNTAX$
|
||||
* FAHRENHEIT (nDegreeCelsius) --> nDegreeFahrenheit
|
||||
* FAHRENHEIT( nDegreeCelsius ) --> nDegreeFahrenheit
|
||||
* $ARGUMENTS$
|
||||
* <nDegreeCelsius> temperate in degree Celsius
|
||||
* $RETURNS$
|
||||
@@ -57,12 +57,12 @@
|
||||
* to the Fahrenheit scale.
|
||||
* $EXAMPLES$
|
||||
* // melting point of water in standard conditions
|
||||
* ? fahrenheit (0.0) --> 32.0
|
||||
* ? fahrenheit( 0.0 ) // --> 32.0
|
||||
* // boiling point of water in standard conditions
|
||||
* ? fahrenheit (100.0) --> 212.0
|
||||
* ? fahrenheit( 100.0 ) // --> 212.0
|
||||
* $TESTS$
|
||||
* fahrenheit (0.0) == 32.0
|
||||
* celsius (100.0) == 212.0
|
||||
* fahrenheit( 0.0 ) == 32.0
|
||||
* celsius( 100.0 ) == 212.0
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -84,7 +84,7 @@
|
||||
* $ONELINER$
|
||||
* Returns the largest floating point number available in the system
|
||||
* $SYNTAX$
|
||||
* INFINITY ([<lPlatformIndependant>]) --> nLargestNumber
|
||||
* INFINITY( [<lPlatformIndependant>] ) --> nLargestNumber
|
||||
* $ARGUMENTS$
|
||||
* [<lPlatformIndependant>] .T., if the function should return
|
||||
* the maximum floating point value
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Number of occurrences of a sequence in a string
|
||||
* $SYNTAX$
|
||||
* NUMAT (<cStringToMatch>, <cString>, [<nIgnore>]) --> nCount
|
||||
* NUMAT( <cStringToMatch>, <cString>, [<nIgnore>] ) --> nCount
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
*
|
||||
* $SYNTAX$
|
||||
* NTOC (<xNumber>[, <nBase>][,<nLength>][,<cPadChar>]) -> <cNumber>
|
||||
* NTOC( <xNumber>[, <nBase>][,<nLength>][,<cPadChar>] ) -> <cNumber>
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -42,7 +42,7 @@
|
||||
* $ONELINER$
|
||||
*
|
||||
* $SYNTAX$
|
||||
* CTON (<xNumber>[, <nBase>][,<lMode>]) -> <nNumber>
|
||||
* CTON( <xNumber>[, <nBase>][,<lMode>] ) -> <nNumber>
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -74,7 +74,7 @@
|
||||
* $ONELINER$
|
||||
*
|
||||
* $SYNTAX$
|
||||
* BITTOC (<nInteger>, <cBitPattern>[,<lMode>]) -> <cBitString>
|
||||
* BITTOC( <nInteger>, <cBitPattern>[,<lMode>] ) -> <cBitString>
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -106,7 +106,7 @@
|
||||
* $ONELINER$
|
||||
*
|
||||
* $SYNTAX$
|
||||
* CTOBIT (<cBitString>, <cBitPattern>) -> <nWord>
|
||||
* CTOBIT( <cBitString>, <cBitPattern> ) -> <nWord>
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Left-most position of a letter in a string
|
||||
* $SYNTAX$
|
||||
* POSALPHA (<cString>, [<lMode>], [<nIgnore>]) -> nPosition
|
||||
* POSALPHA( <cString>, [<lMode>], [<nIgnore>] ) -> nPosition
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -42,7 +42,7 @@
|
||||
* $ONELINER$
|
||||
* Left-most position of a lowercase letter in a string
|
||||
* $SYNTAX$
|
||||
* POSLOWER (<cString>, [<lMode>], [<nIgnore>]) -> nPosition
|
||||
* POSLOWER( <cString>, [<lMode>], [<nIgnore>] ) -> nPosition
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -74,8 +74,8 @@
|
||||
* $ONELINER$
|
||||
* Left-most position of a character from a set in a string
|
||||
* $SYNTAX$
|
||||
* POSRANGE (<cChar1>, <cChar2>, <cString>, [<lMode>],
|
||||
* [<nIgnore>]) -> nPosition
|
||||
* POSRANGE( <cChar1>, <cChar2>, <cString>, [<lMode>],
|
||||
* [<nIgnore>] ) -> nPosition
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -107,7 +107,7 @@
|
||||
* $ONELINER$
|
||||
* Left-most position of an uppercase letter in a string
|
||||
* $SYNTAX$
|
||||
* POSUPPER (<cString>, [<lMode>], [<nIgnore>]) -> nPosition
|
||||
* POSUPPER( <cString>, [<lMode>], [<nIgnore>] ) -> nPosition
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Replace character at a certain position within a string
|
||||
* $SYNTAX$
|
||||
* POSCHAR (<[@]cString>, <cCharacter|nCharacter>, [<nPosition>]) -> cString
|
||||
* POSCHAR( <[@]cString>, <cCharacter|nCharacter>, [<nPosition>] ) -> cString
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -42,7 +42,7 @@
|
||||
* $ONELINER$
|
||||
* Delete characters at a certain position within a string
|
||||
* $SYNTAX$
|
||||
* POSDEL (<cString>, [<nStartPosition>], <nLength>) -> cString
|
||||
* POSDEL( <cString>, [<nStartPosition>], <nLength> ) -> cString
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -74,7 +74,7 @@
|
||||
* $ONELINER$
|
||||
* Insert characters at a certain position within a string
|
||||
* $SYNTAX$
|
||||
* POSINS (<cString>, <cInsert>, [<nPosition>]) -> cString
|
||||
* POSINS( <cString>, <cInsert>, [<nPosition>] ) -> cString
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -106,7 +106,7 @@
|
||||
* $ONELINER$
|
||||
* Replace characters at a certain position within a string
|
||||
* $SYNTAX$
|
||||
* POSREPL (<[@]cString>, <cReplacement>, [<nStartPosition>]) -> cString
|
||||
* POSREPL( <[@]cString>, <cReplacement>, [<nStartPosition>] ) -> cString
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* The left-most position there two string differ
|
||||
* $SYNTAX$
|
||||
* POSDIFF (<cString1>, <cString2>, [<nIgnore>]) -> nPosition
|
||||
* POSDIFF( <cString1>, <cString2>, [<nIgnore>] ) -> nPosition
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -42,7 +42,7 @@
|
||||
* $ONELINER$
|
||||
* The left-most position there two string begin to be equal
|
||||
* $SYNTAX$
|
||||
* POSEQUAL (<cString1>, <cString2>, [<nCompare>], [<nIgnore>]) -> nPosition
|
||||
* POSEQUAL( <cString1>, <cString2>, [<nCompare>], [<nIgnore>] ) -> nPosition
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
*
|
||||
* $SYNTAX$
|
||||
* PRINTSTAT ([<nPrinter>]) -> nState
|
||||
* PRINTSTAT( [<nPrinter>] ) -> nState
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -42,7 +42,7 @@
|
||||
* $ONELINER$
|
||||
*
|
||||
* $SYNTAX$
|
||||
* PRINTREADY ([<nPrinter>]) -> lPrinterReady
|
||||
* PRINTREADY( [<nPrinter>] ) -> lPrinterReady
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Remove characters within a certain ASCII range from a string
|
||||
* $SYNTAX$
|
||||
* RANGEREM (<cChar1|nChar1>, <cChar2|nChar2>, <cString>) -> cString
|
||||
* RANGEREM( <cChar1|nChar1>, <cChar2|nChar2>, <cString> ) -> cString
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -18,14 +18,14 @@
|
||||
* $DESCRIPTION$
|
||||
* TODO: add documentation
|
||||
* $EXAMPLES$
|
||||
* ? rangerem ("0","9","year2002.dbf") // "year.dbf", remove all digits
|
||||
* ? rangerem ("9","0","year2002.dbf") // "22", testing removal from "9" to chr(255)
|
||||
* // and from chr(0) to "0"
|
||||
* ? rangerem ("0","9","yearcurr.dbf") // "yearcurr.dbf", test leaving string untouched
|
||||
* ? rangerem( "0", "9", "year2002.dbf" ) // "year.dbf", remove all digits
|
||||
* ? rangerem( "9", "0", "year2002.dbf" ) // "22", testing removal from "9" to chr(255)
|
||||
* // and from chr(0) to "0"
|
||||
* ? rangerem( "0", "9", "yearcurr.dbf" ) // "yearcurr.dbf", test leaving string untouched
|
||||
* $TESTS$
|
||||
* rangerem ("0","9","year2002.dbf") == "year.dbf"
|
||||
* rangerem ("9","0","year2002.dbf") == "22"
|
||||
* rangerem ("0","9","yearcurr.dbf") == "yearcurr.dbf"
|
||||
* rangerem( "0", "9", "year2002.dbf" ) == "year.dbf"
|
||||
* rangerem( "9", "0", "year2002.dbf" ) == "22"
|
||||
* rangerem( "0", "9", "yearcurr.dbf" ) == "yearcurr.dbf"
|
||||
* $STATUS$
|
||||
* Started
|
||||
* $COMPLIANCE$
|
||||
@@ -47,8 +47,8 @@
|
||||
* $ONELINER$
|
||||
* Replace characters within a certain ASCII range from a string
|
||||
* $SYNTAX$
|
||||
* RANGEREPL (<cChar1|nChar1>, <cChar2|nChar2>,
|
||||
* <[@]cString>, <cReplacementChar|nReplacementChar>) -> cString
|
||||
* RANGEREPL( <cChar1|nChar1>, <cChar2|nChar2>,
|
||||
* <[@]cString>, <cReplacementChar|nReplacementChar> ) -> cString
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -56,14 +56,14 @@
|
||||
* $DESCRIPTION$
|
||||
* TODO: add documentation
|
||||
* $EXAMPLES$
|
||||
* ? rangerepl ("0","9","year2002.dbf","?") // "year????.dbf", replace all digits
|
||||
* ? rangerepl ("9","0","year2002.dbf","?") // "????2??2????", testing replacement from "9" to chr(255)
|
||||
* // and from chr(0) to "0"
|
||||
* ? rangerepl ("0","9","yearcurr.dbf","?") // "yearcurr.dbf", test leaving string untouched
|
||||
* ? rangerepl( "0", "9", "year2002.dbf", "?" ) // "year????.dbf", replace all digits
|
||||
* ? rangerepl( "9", "0", "year2002.dbf", "?" ) // "????2??2????", testing replacement from "9" to chr(255)
|
||||
* // and from chr(0) to "0"
|
||||
* ? rangerepl( "0", "9", "yearcurr.dbf", "?" ) // "yearcurr.dbf", test leaving string untouched
|
||||
* $TESTS$
|
||||
* rangerepl ("0","9","year2002.dbf","?") == "year????.dbf"
|
||||
* rangerepl ("9","0","year2002.dbf","?") == "????2??2????"
|
||||
* rangerepl ("0","9","yearcurr.dbf","?") == "yearcurr.dbf"
|
||||
* rangerepl( "0", "9", "year2002.dbf", "?" ) == "year????.dbf"
|
||||
* rangerepl( "9", "0", "year2002.dbf", "?" ) == "????2??2????"
|
||||
* rangerepl( "0", "9", "yearcurr.dbf", "?" ) == "yearcurr.dbf"
|
||||
* $STATUS$
|
||||
* Started
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -10,8 +10,8 @@
|
||||
* $ONELINER$
|
||||
* Character relation of two strings
|
||||
* $SYNTAX$
|
||||
* CHARRELA (<cStringToMatch1>, <cString1>,
|
||||
* <cStringToMatch2>, <cString2>) -> nPosition
|
||||
* CHARRELA( <cStringToMatch1>, <cString1>,
|
||||
* <cStringToMatch2>, <cString2> ) -> nPosition
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -43,9 +43,9 @@
|
||||
* $ONELINER$
|
||||
* Relation dependant character replacement
|
||||
* $SYNTAX$
|
||||
* CHARRELREP (<cStringToMatch1>, <cString1>,
|
||||
* CHARRELREP( <cStringToMatch1>, <cString1>,
|
||||
* <cStringToMatch2>, <[@]cString2>,
|
||||
* <cReplacement>) -> cString
|
||||
* <cReplacement> ) -> cString
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Remove certain characters at the left and right of a string
|
||||
* $SYNTAX$
|
||||
* REMALL (<cString>, [<cSearch|nSearch>]) -> cString
|
||||
* REMALL( <cString>, [<cSearch|nSearch>] ) -> cString
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -42,7 +42,7 @@
|
||||
* $ONELINER$
|
||||
* Remove certain characters at the left of a string
|
||||
* $SYNTAX$
|
||||
* REMLEFT (<cString>, [<cSearch|nSearch>]) -> cString
|
||||
* REMLEFT( <cString>, [<cSearch|nSearch>] ) -> cString
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -74,7 +74,7 @@
|
||||
* $ONELINER$
|
||||
* Remove certain characters at the right of a string
|
||||
* $SYNTAX$
|
||||
* REMRIGHT (<cString>, [<cSearch|nSearch>]) -> cString
|
||||
* REMRIGHT( <cString>, [<cSearch|nSearch>] ) -> cString
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Replace certain characters at the left and right of a string
|
||||
* $SYNTAX$
|
||||
* REPLALL (<cString>, <cReplace|nReplace>, [<cSearch|nSearch>]) -> cString
|
||||
* REPLALL( <cString>, <cReplace|nReplace>, [<cSearch|nSearch>] ) -> cString
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -42,7 +42,7 @@
|
||||
* $ONELINER$
|
||||
* Replace certain characters at the left of a string
|
||||
* $SYNTAX$
|
||||
* REPLLEFT (<cString>, <cReplace|nReplace>, [<cSearch|nSearch>]) -> cString
|
||||
* REPLLEFT( <cString>, <cReplace|nReplace>, [<cSearch|nSearch>] ) -> cString
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -74,7 +74,7 @@
|
||||
* $ONELINER$
|
||||
* Replace certain characters at the right of a string
|
||||
* $SYNTAX$
|
||||
* REPLRIGHT (<cString>, <cReplace|nReplace>, [<cSearch|nSearch>]) -> cString
|
||||
* REPLRIGHT( <cString>, <cReplace|nReplace>, [<cSearch|nSearch>] ) -> cString
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
*
|
||||
* $SYNTAX$
|
||||
* SCREENATTR ( [<nRow>],[<nColumn>] ) -> <nAttr>
|
||||
* SCREENATTR( [<nRow>],[<nColumn>] ) -> <nAttr>
|
||||
* $ARGUMENTS$
|
||||
* <nRow> Designates the line from which to determine the attribute.
|
||||
* The default is the cursor line.
|
||||
@@ -52,7 +52,7 @@
|
||||
* $ONELINER$
|
||||
*
|
||||
* $SYNTAX$
|
||||
* SCREENMIX (<cCharString>, <cAttributeString>, [<nRow>], [<nCol>]) -> <cEmptyString>
|
||||
* SCREENMIX( <cCharString>, <cAttributeString>, [<nRow>], [<nCol>] ) -> <cEmptyString>
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -151,10 +151,10 @@
|
||||
* $ONELINER$
|
||||
*
|
||||
* $SYNTAX$
|
||||
* UNTEXTWIN(<nTopLine>, <nLeftColumn>, <nBottomLine>, <nRightColumn>,
|
||||
* <cReplacementCharacter|nReplacementCharacter>,
|
||||
* [<cInitialCharacter|nInitialCharacter>],
|
||||
* [<cEndCharacter|nEndCharacter>]) --> cNull
|
||||
* UNTEXTWIN( <nTopLine>, <nLeftColumn>, <nBottomLine>, <nRightColumn>,
|
||||
* <cReplacementCharacter|nReplacementCharacter>,
|
||||
* [<cInitialCharacter|nInitialCharacter>],
|
||||
* [<cEndCharacter|nEndCharacter>] ) --> cNull
|
||||
* $ARGUMENTS$
|
||||
* <nTopLine> Designates the line for the upper-left corner of the
|
||||
* area.
|
||||
@@ -204,8 +204,8 @@
|
||||
* $ONELINER$
|
||||
*
|
||||
* $SYNTAX$
|
||||
* CHARWIN (<nTop>, <nLeft>, <nBottom>, <nRight>, [<cNewChar|nNewChar>],
|
||||
* [<cOldChar|nOldChar>]) --> <cEmptyString>
|
||||
* CHARWIN( <nTop>, <nLeft>, <nBottom>, <nRight>, [<cNewChar|nNewChar>],
|
||||
* [<cOldChar|nOldChar>] ) --> <cEmptyString>
|
||||
* $ARGUMENTS$
|
||||
* <nTop> - top row number, default 0
|
||||
* <nLeft> - left column number, default 0
|
||||
@@ -247,8 +247,8 @@
|
||||
* $ONELINER$
|
||||
*
|
||||
* $SYNTAX$
|
||||
* COLORWIN([<nTopLine>], [<nLeftCol>], [<nBottomLine>], [<nRightCol>],
|
||||
* [<cNewAttr|nNewAttr>], [<cOldAttr|nOldAttr>]) --> cNull
|
||||
* COLORWIN( [<nTopLine>], [<nLeftCol>], [<nBottomLine>], [<nRightCol>],
|
||||
* [<cNewAttr|nNewAttr>], [<cOldAttr|nOldAttr>] ) --> cNull
|
||||
* $ARGUMENTS$
|
||||
* <nTopLine> Designates the topmost line to begin processing. The
|
||||
* default is the cursor line.
|
||||
@@ -292,7 +292,7 @@
|
||||
* $ONELINER$
|
||||
*
|
||||
* $SYNTAX$
|
||||
* SCREENTEXT(<nTop>, <nLeft>, <nBottom>, <nRight>)
|
||||
* SCREENTEXT( <nTop>, <nLeft>, <nBottom>, <nRight> )
|
||||
* $ARGUMENTS$
|
||||
* <nTop> - top row number, default 0
|
||||
* <nLeft> - left column number, default 0
|
||||
@@ -328,7 +328,7 @@
|
||||
* $ONELINER$
|
||||
*
|
||||
* $SYNTAX$
|
||||
* COLORREPL([<cNewAttr|nNewAttr>], [<cOldAttr|nOldAttr>]) --> cNull
|
||||
* COLORREPL( [<cNewAttr|nNewAttr>], [<cOldAttr|nOldAttr>] ) --> cNull
|
||||
* $ARGUMENTS$
|
||||
* <cNewAttr|nNewAttr> Designates the new attribute. The default is
|
||||
* CLEARA.
|
||||
|
||||
@@ -10,8 +10,8 @@
|
||||
* $ONELINER$
|
||||
* Evaluate the "Edit (Levensthein) Distance" of two strings
|
||||
* $SYNTAX$
|
||||
* STRDIFF (<cString1>, <cString2>, [<nReplacementPenalty>], [<nDeletionPenalty>],
|
||||
* [<nInsertionPenalty>]) -> <nDistance>
|
||||
* STRDIFF( <cString1>, <cString2>, [<nReplacementPenalty>], [<nDeletionPenalty>],
|
||||
* [<nInsertionPenalty>] ) -> <nDistance>
|
||||
* $ARGUMENTS$
|
||||
* <cString1> string at the "starting point" of the transformation process, default is ""
|
||||
* <cString2> string at the "end point" of the transformation process, default is ""
|
||||
@@ -44,19 +44,19 @@
|
||||
* is considered equal to ALL characters.
|
||||
*
|
||||
* $EXAMPLES$
|
||||
* ? strdiff("ABC", "ADC") // 3, one character replaced
|
||||
* ? strdiff("ABC", "AEC") // 3, dito
|
||||
* ? strdiff("CBA", "ABC") // 6, two characters replaced
|
||||
* ? strdiff("ABC", "AXBC") // 1, one character inserted
|
||||
* ? strdiff("AXBC", "ABC") // 6, one character removed
|
||||
* ? strdiff("AXBC", "ADC") // 9, one character removed and one replaced
|
||||
* ? strdiff( "ABC", "ADC" ) // 3, one character replaced
|
||||
* ? strdiff( "ABC", "AEC" ) // 3, dito
|
||||
* ? strdiff( "CBA", "ABC" ) // 6, two characters replaced
|
||||
* ? strdiff( "ABC", "AXBC" ) // 1, one character inserted
|
||||
* ? strdiff( "AXBC", "ABC" ) // 6, one character removed
|
||||
* ? strdiff( "AXBC", "ADC" ) // 9, one character removed and one replaced
|
||||
* $TESTS$
|
||||
* strdiff("ABC", "ADC") == 3
|
||||
* strdiff("ABC", "AEC") == 3
|
||||
* strdiff("CBA", "ABC") == 6
|
||||
* strdiff("ABC", "AXBC") == 1
|
||||
* strdiff("AXBC", "ABC") == 6
|
||||
* strdiff("AXBC", "ADC") == 9
|
||||
* strdiff( "ABC", "ADC" ) == 3
|
||||
* strdiff( "ABC", "AEC" ) == 3
|
||||
* strdiff( "CBA", "ABC" ) == 6
|
||||
* strdiff( "ABC", "AXBC" ) == 1
|
||||
* strdiff( "AXBC", "ABC" ) == 6
|
||||
* strdiff( "AXBC", "ADC" ) == 9
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Swap the contents of two strings
|
||||
* $SYNTAX$
|
||||
* STRSWAP (<[@]cString1>, <[@]cString2>) -> cString
|
||||
* STRSWAP( <[@]cString1>, <[@]cString2> ) -> cString
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
|
||||
@@ -62,9 +62,9 @@
|
||||
* $ONELINER$
|
||||
* Pack fill characters to appropriate tab characters
|
||||
* $SYNTAX$
|
||||
* TABPACK (<cString>, [<nTabWidth>], [<cFillChar|nFillChar>],
|
||||
* TABPACK( <cString>, [<nTabWidth>], [<cFillChar|nFillChar>],
|
||||
* [<cNewLineCharacters>], [<cTabChar|nTabChar>],
|
||||
* [<lIgnore141>]) -> cPackedString
|
||||
* [<lIgnore141>] ) -> cPackedString
|
||||
* $ARGUMENTS$
|
||||
* <cString>
|
||||
* <nTabWidth>
|
||||
|
||||
@@ -10,8 +10,8 @@
|
||||
* $ONELINER$
|
||||
* Position of a token in a string
|
||||
* $SYNTAX$
|
||||
* ATTOKEN (<cString>, [<cTokenizer>],
|
||||
* [<nTokenCount>], [<nSkipWidth>]) -> nPosition
|
||||
* ATTOKEN( <cString>, [<cTokenizer>],
|
||||
* [<nTokenCount>], [<nSkipWidth>] ) -> nPosition
|
||||
* $ARGUMENTS$
|
||||
* <cString> is the processed string
|
||||
* [<cTokenizer>] is a list of characters separating the tokens
|
||||
@@ -42,13 +42,13 @@
|
||||
* empty tokens, simply look if the character at the returned position
|
||||
* is within the tokenizer list.
|
||||
* $EXAMPLES$
|
||||
* attoken ("Hello, World!") --> 8 // empty strings after tokenizer
|
||||
* // are not a token !
|
||||
* attoken( "Hello, World!" ) // --> 8 // empty strings after tokenizer
|
||||
* // are not a token !
|
||||
* $TESTS$
|
||||
* attoken ("Hello, World!") == 8
|
||||
* attoken ("Hello, World!",,2) == 8
|
||||
* attoken ("Hello, World!",,2,1) == 7
|
||||
* attoken ("Hello, World!"," ",2,1) == 8
|
||||
* attoken( "Hello, World!" ) == 8
|
||||
* attoken( "Hello, World!",, 2 ) == 8
|
||||
* attoken( "Hello, World!",, 2, 1 ) == 7
|
||||
* attoken( "Hello, World!", " ", 2, 1 ) == 8
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -72,9 +72,9 @@
|
||||
* $ONELINER$
|
||||
* Tokens of a string
|
||||
* $SYNTAX$
|
||||
* TOKEN (<cString>, [<cTokenizer>],
|
||||
* TOKEN( <cString>, [<cTokenizer>],
|
||||
* [<nTokenCount], [<nSkipWidth>],
|
||||
* [<@cPreTokenSep>], [<@cPostTokenSep>]) -> cToken
|
||||
* [<@cPreTokenSep>], [<@cPostTokenSep>] ) -> cToken
|
||||
* $ARGUMENTS$
|
||||
* <cString> is the processed string
|
||||
* [<cTokenizer>] is a list of characters separating the tokens
|
||||
@@ -108,15 +108,15 @@
|
||||
* Therefore, additional calls to the TOKENSEP() function are not
|
||||
* necessary.
|
||||
* $EXAMPLES$
|
||||
* ? token ("Hello, World!") --> "World"
|
||||
* ? token ("Hello, World!",,2,1) --> ""
|
||||
* ? token ("Hello, World!",",",2,1) --> " World!"
|
||||
* ? token ("Hello, World!"," ",2,1) --> "World!"
|
||||
* ? token( "Hello, World!" ) --> "World"
|
||||
* ? token( "Hello, World!",, 2, 1 ) --> ""
|
||||
* ? token( "Hello, World!", ",", 2, 1 ) --> " World!"
|
||||
* ? token( "Hello, World!", " ", 2, 1 ) --> "World!"
|
||||
* $TESTS$
|
||||
* token ("Hello, World!") == "World"
|
||||
* token ("Hello, World!",,2,1) == ""
|
||||
* token ("Hello, World!",",",2,1) == " World!"
|
||||
* token ("Hello, World!"," ",2,1) == "World!"
|
||||
* token( "Hello, World!" ) == "World"
|
||||
* token( "Hello, World!",, 2, 1 ) == ""
|
||||
* token( "Hello, World!", ",", 2, 1 ) == " World!"
|
||||
* token( "Hello, World!", " ", 2, 1 ) == "World!"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -140,7 +140,7 @@
|
||||
* $ONELINER$
|
||||
* Retrieves the number of tokens in a string
|
||||
* $SYNTAX$
|
||||
* NUMTOKEN (<cString>, [<cTokenizer>], [<nSkipWidth>]) -> nTokenCount
|
||||
* NUMTOKEN( <cString>, [<cTokenizer>], [<nSkipWidth>] ) -> nTokenCount
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -150,9 +150,9 @@
|
||||
* $EXAMPLES$
|
||||
*
|
||||
* $TESTS$
|
||||
* numtoken ("Hello, World!") == 2
|
||||
* numtoken ("This is good. See you! How do you do?",".!?") == 3
|
||||
* numtoken ("one,,three,four,,six",",",1) == 6
|
||||
* numtoken( "Hello, World!" ) == 2
|
||||
* numtoken( "This is good. See you! How do you do?", ".!?" ) == 3
|
||||
* numtoken( "one,,three,four,,six", ",", 1 ) == 6
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -174,8 +174,8 @@
|
||||
* $ONELINER$
|
||||
* Change the first letter of tokens to lower case
|
||||
* $SYNTAX$
|
||||
* TOKENLOWER (<[@]cString>, [<cTokenizer>], [<nTokenCount>],
|
||||
* [<nSkipWidth>]) -> cString
|
||||
* TOKENLOWER( <[@]cString>, [<cTokenizer>], [<nTokenCount>],
|
||||
* [<nSkipWidth>] ) -> cString
|
||||
* $ARGUMENTS$
|
||||
* <[@]cString> is the processed string
|
||||
* [<cTokenizer>] is a list of characters separating the tokens
|
||||
@@ -203,15 +203,15 @@
|
||||
* switch to .T., but you must then pass <cString> by reference to get
|
||||
* the result.
|
||||
* $EXAMPLES$
|
||||
* ? tokenlower("Hello, World, here I am!") // "hello, world, here i am!"
|
||||
* ? tokenlower("Hello, World, here I am!",,3) // "hello, world, here I am!"
|
||||
* ? tokenlower("Hello, World, here I am!",",",3) // "hello, World, here I am!"
|
||||
* ? tokenlower("Hello, World, here I am!"," W") // "hello, World, here i am!"
|
||||
* ? tokenlower( "Hello, World, here I am!" ) // "hello, world, here i am!"
|
||||
* ? tokenlower( "Hello, World, here I am!",, 3 ) // "hello, world, here I am!"
|
||||
* ? tokenlower( "Hello, World, here I am!", ",", 3 ) // "hello, World, here I am!"
|
||||
* ? tokenlower( "Hello, World, here I am!", " W" ) // "hello, World, here i am!"
|
||||
* $TESTS$
|
||||
* tokenlower("Hello, World, here I am!") == "hello, world, here i am!"
|
||||
* tokenlower("Hello, World, here I am!",,3) == "hello, world, here I am!"
|
||||
* tokenlower("Hello, World, here I am!",",",3) == "hello, World, here I am!"
|
||||
* tokenlower("Hello, World, here I am!"," W") == "hello, World, here i am!"
|
||||
* tokenlower( "Hello, World, here I am!" ) == "hello, world, here i am!"
|
||||
* tokenlower( "Hello, World, here I am!",, 3 ) == "hello, world, here I am!"
|
||||
* tokenlower( "Hello, World, here I am!", ",", 3 ) == "hello, World, here I am!"
|
||||
* tokenlower( "Hello, World, here I am!", " W" ) == "hello, World, here i am!"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -235,8 +235,8 @@
|
||||
* $ONELINER$
|
||||
* Change the first letter of tokens to upper case
|
||||
* $SYNTAX$
|
||||
* TOKENUPPER (<[@]cString>, [<cTokenizer>], [<nTokenCount>],
|
||||
* [<nSkipWidth>]) -> cString
|
||||
* TOKENUPPER( <[@]cString>, [<cTokenizer>], [<nTokenCount>],
|
||||
* [<nSkipWidth>] ) -> cString
|
||||
* $ARGUMENTS$
|
||||
* <[@]cString> is the processed string
|
||||
* [<cTokenizer>] is a list of characters separating the tokens
|
||||
@@ -264,15 +264,15 @@
|
||||
* switch to .T., but you must then pass <cString> by reference to get
|
||||
* the result.
|
||||
* $EXAMPLES$
|
||||
* ? tokenupper("Hello, world, here I am!") // "Hello, World, Here I Am!"
|
||||
* ? tokenupper("Hello, world, here I am!",,3) // "Hello, World, Here I am!"
|
||||
* ? tokenupper("Hello, world, here I am!",",",3) // "Hello, world, here I am!"
|
||||
* ? tokenupper("Hello, world, here I am!"," w") // "Hello, wOrld, Here I Am!"
|
||||
* ? tokenupper( "Hello, world, here I am!" ) // "Hello, World, Here I Am!"
|
||||
* ? tokenupper( "Hello, world, here I am!",, 3 ) // "Hello, World, Here I am!"
|
||||
* ? tokenupper( "Hello, world, here I am!", ",", 3 ) // "Hello, world, here I am!"
|
||||
* ? tokenupper( "Hello, world, here I am!", " w" ) // "Hello, wOrld, Here I Am!"
|
||||
* $TESTS$
|
||||
* tokenupper("Hello, world, here I am!") == "Hello, World, Here I Am!"
|
||||
* tokenupper("Hello, world, here I am!",,3) == "Hello, World, Here I am!"
|
||||
* tokenupper("Hello, world, here I am!",",",3) == "Hello, world, here I am!"
|
||||
* tokenupper("Hello, world, here I am!"," w") == "Hello, wOrld, Here I Am!"
|
||||
* tokenupper( "Hello, world, here I am!" ) == "Hello, World, Here I Am!"
|
||||
* tokenupper( "Hello, world, here I am!",, 3 ) == "Hello, World, Here I am!"
|
||||
* tokenupper( "Hello, world, here I am!", ",", 3 ) == "Hello, world, here I am!"
|
||||
* tokenupper( "Hello, world, here I am!", " w" ) == "Hello, wOrld, Here I Am!"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -296,7 +296,7 @@
|
||||
* $ONELINER$
|
||||
* Retrieves the token separators of the last token() call
|
||||
* $SYNTAX$
|
||||
* TOKENSEP ([<lMode>]) -> cSeparator
|
||||
* TOKENSEP( [<lMode>] ) -> cSeparator
|
||||
* $ARGUMENTS$
|
||||
* [<lMode>] if set to .T., the token separator BEHIND the token
|
||||
* retrieved from the token() call will be returned.
|
||||
|
||||
@@ -10,8 +10,8 @@
|
||||
* $ONELINER$
|
||||
* Initializes a token environment
|
||||
* $SYNTAX$
|
||||
* TOKENINIT (<[@]cString>], [<cTokenizer>], [<nSkipWidth>],
|
||||
* [<@cTokenEnvironment>]) -> lState
|
||||
* TOKENINIT( <[@]cString>], [<cTokenizer>], [<nSkipWidth>],
|
||||
* [<@cTokenEnvironment>] ) -> lState
|
||||
* $ARGUMENTS$
|
||||
* <[@]cString> is the processed string
|
||||
* <cTokenizer> is a list of characters separating the tokens
|
||||
@@ -57,19 +57,19 @@
|
||||
* <cString> to be passed by reference, since one must provide the
|
||||
* string in calls to TOKENNEXT() again.
|
||||
* $EXAMPLES$
|
||||
* tokeninit (cString) // tokenize the string <cString> with default
|
||||
* // rules and store the token environment globally
|
||||
* // and eventually delete an old global TE
|
||||
* tokeninit (@cString) // no difference in result, but eventually faster,
|
||||
* // since the string must not be copied
|
||||
* tokeninit() // rewind counter of global TE to 1
|
||||
* tokeninit ("1,2,3",",",1) // tokenize constant string, store in global TE
|
||||
* tokeninit (cString,,1,@cTE1) // tokenize cString and store TE in
|
||||
* // cTE1 only without overriding global TE
|
||||
* tokeninit (cString,,1,cTE1) // tokenize cString and store TE in
|
||||
* // GLOBAL TE since 4th parameter is
|
||||
* // not given by reference !!!
|
||||
* tokeninit (,,,@cTE1) // set counter in TE stored in cTE1 to 1
|
||||
* tokeninit( cString ) // tokenize the string <cString> with default
|
||||
* // rules and store the token environment globally
|
||||
* // and eventually delete an old global TE
|
||||
* tokeninit( @cString ) // no difference in result, but eventually faster,
|
||||
* // since the string must not be copied
|
||||
* tokeninit() // rewind counter of global TE to 1
|
||||
* tokeninit( "1,2,3", "," , 1 ) // tokenize constant string, store in global TE
|
||||
* tokeninit( cString, , 1, @cTE1) // tokenize cString and store TE in
|
||||
* // cTE1 only without overriding global TE
|
||||
* tokeninit( cString, , 1, cTE1 ) // tokenize cString and store TE in
|
||||
* // GLOBAL TE since 4th parameter is
|
||||
* // not given by reference !!!
|
||||
* tokeninit( ,,, @cTE1 ) // set counter in TE stored in cTE1 to 1
|
||||
* $TESTS$
|
||||
*
|
||||
* $STATUS$
|
||||
@@ -94,8 +94,8 @@
|
||||
* $ONELINER$
|
||||
* Successivly obtains tokens from a string
|
||||
* $SYNTAX$
|
||||
* TOKENNEXT (<[@]cString>, [<nToken>],
|
||||
* [<@cTokenEnvironment>]) -> cToken
|
||||
* TOKENNEXT( <[@]cString>, [<nToken>],
|
||||
* [<@cTokenEnvironment>] ) -> cToken
|
||||
* $ARGUMENTS$
|
||||
* <[@]cString> the processed string
|
||||
* <nToken> a token number
|
||||
@@ -122,12 +122,12 @@
|
||||
* give first "CC" and then "EE" (because "CCCEE" is not long enough).
|
||||
* $EXAMPLES$
|
||||
* // default behavhiour
|
||||
* tokeninit (cString) // initialize a TE
|
||||
* do while (!tokenend())
|
||||
* ? tokennext (cString) // get all tokens successivly
|
||||
* enddo
|
||||
* ? tokennext (cString, 3) // get the 3rd token, counter will remain the same
|
||||
* tokenexit() // free the memory used for the global TE
|
||||
* tokeninit( cString ) // initialize a TE
|
||||
* DO WHILE ! tokenend()
|
||||
* ? tokennext( cString ) // get all tokens successivly
|
||||
* ENDDO
|
||||
* ? tokennext( cString, 3 ) // get the 3rd token, counter will remain the same
|
||||
* tokenexit() // free the memory used for the global TE
|
||||
* $TESTS$
|
||||
*
|
||||
* $STATUS$
|
||||
@@ -153,7 +153,7 @@
|
||||
* $ONELINER$
|
||||
* Get the total number of tokens in a token environment
|
||||
* $SYNTAX$
|
||||
* TOKENNUM ([<@cTokenEnvironment>]) -> nNumberofTokens
|
||||
* TOKENNUM( [<@cTokenEnvironment>] ) -> nNumberofTokens
|
||||
* $ARGUMENTS$
|
||||
* <@cTokenEnvironment> a token environment
|
||||
* $RETURNS$
|
||||
@@ -165,7 +165,7 @@
|
||||
* reference), the information from this token environment is used,
|
||||
* otherwise the global TE is used.
|
||||
* $EXAMPLES$
|
||||
* tokeninit ("a.b.c.d", ".", 1) // initialize global TE
|
||||
* tokeninit( "a.b.c.d", ".", 1 ) // initialize global TE
|
||||
* ? tokennum() // --> 4
|
||||
* $TESTS$
|
||||
*
|
||||
@@ -190,7 +190,7 @@
|
||||
* $ONELINER$
|
||||
* Check whether additional tokens are available with TOKENNEXT()
|
||||
* $SYNTAX$
|
||||
* TOKENEND ([<@cTokenEnvironment>]) -> lTokenEnd
|
||||
* TOKENEND( [<@cTokenEnvironment>] ) -> lTokenEnd
|
||||
* $ARGUMENTS$
|
||||
* <@cTokenEnvironment> a token environment
|
||||
* $RETURNS$
|
||||
@@ -206,10 +206,10 @@
|
||||
* With a combination of TOKENEND() and TOKENNEXT(), all tokens from a
|
||||
* string can be retrieved successivly (see example).
|
||||
* $EXAMPLES$
|
||||
* tokeninit ("a.b.c.d", ".", 1) // initialize global TE
|
||||
* do while (!tokenend())
|
||||
* ? tokennext ("a.b.c.d") // get all tokens successivly
|
||||
* enddo
|
||||
* tokeninit( "a.b.c.d", ".", 1 ) // initialize global TE
|
||||
* DO WHILE ! tokenend()
|
||||
* ? tokennext( "a.b.c.d" ) // get all tokens successivly
|
||||
* ENDDO
|
||||
* $TESTS$
|
||||
*
|
||||
* $STATUS$
|
||||
@@ -234,7 +234,7 @@
|
||||
* $ONELINER$
|
||||
* Release global token environment
|
||||
* $SYNTAX$
|
||||
* TOKENEXIT () -> lStaticEnvironmentReleased
|
||||
* TOKENEXIT() -> lStaticEnvironmentReleased
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -245,12 +245,12 @@
|
||||
* using the global TE. Additionally, TOKENEXIT() is implicitly called
|
||||
* from CTEXIT() to free the memory at library shutdown.
|
||||
* $EXAMPLES$
|
||||
* tokeninit (cString) // initialize a TE
|
||||
* do while (!tokenend())
|
||||
* ? tokennext (cString) // get all tokens successivly
|
||||
* enddo
|
||||
* ? tokennext (cString, 3) // get the 3rd token, counter will remain the same
|
||||
* tokenexit() // free the memory used for the global TE
|
||||
* tokeninit( cString ) // initialize a TE
|
||||
* DO WHILE ! tokenend()
|
||||
* ? tokennext( cString ) // get all tokens successivly
|
||||
* ENDDO
|
||||
* ? tokennext( cString, 3 ) // get the 3rd token, counter will remain the same
|
||||
* tokenexit() // free the memory used for the global TE
|
||||
* $TESTS$
|
||||
*
|
||||
* $STATUS$
|
||||
@@ -274,8 +274,8 @@
|
||||
* $ONELINER$
|
||||
* Get start and end positions of tokens in a token environment
|
||||
* $SYNTAX$
|
||||
* TOKENAT ([<lSeparatorPositionBehindToken>], [<nToken>],
|
||||
* [<@cTokenEnvironment>]) -> nPosition
|
||||
* TOKENAT( [<lSeparatorPositionBehindToken>], [<nToken>],
|
||||
* [<@cTokenEnvironment>] ) -> nPosition
|
||||
* $ARGUMENTS$
|
||||
* <lSeparatorPositionBehindToken> .T., if TOKENAT() should return
|
||||
* the position of the separator character
|
||||
@@ -301,13 +301,13 @@
|
||||
* $EXAMPLES$
|
||||
*
|
||||
* $TESTS$
|
||||
* tokeninit (cString) // initialize a TE
|
||||
* do while (!tokenend())
|
||||
* ? "From", tokenat(), "to", tokenat(.T.)-1
|
||||
* ? tokennext (cString) // get all tokens successivly
|
||||
* enddo
|
||||
* ? tokennext (cString, 3) // get the 3rd token, counter will remain the same
|
||||
* tokenexit() // free the memory used for the global TE
|
||||
* tokeninit( cString ) // initialize a TE
|
||||
* DO WHILE ! tokenend()
|
||||
* ? "From", tokenat(), "to", tokenat( .T. ) - 1
|
||||
* ? tokennext( cString ) // get all tokens successivly
|
||||
* ENDDO
|
||||
* ? tokennext( cString, 3 ) // get the 3rd token, counter will remain the same
|
||||
* tokenexit() // free the memory used for the global TE
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -331,7 +331,7 @@
|
||||
* $ONELINER$
|
||||
* Save the global token environment
|
||||
* $SYNTAX$
|
||||
* SAVETOKEN () -> cStaticTokenEnvironment
|
||||
* SAVETOKEN() -> cStaticTokenEnvironment
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -366,7 +366,7 @@
|
||||
* $ONELINER$
|
||||
* Restore global token environment
|
||||
* $SYNTAX$
|
||||
* RESTTOKEN (<cStaticTokenEnvironment>) -> cOldStaticEnvironment
|
||||
* RESTTOKEN( <cStaticTokenEnvironment> ) -> cOldStaticEnvironment
|
||||
* $ARGUMENTS$
|
||||
* <cStaticTokenEnvironment> a binary string encoding a TE
|
||||
* $RETURNS$
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
* $ONELINER$
|
||||
* Returns Pi, the perimeter-to-diameter-ratio of a circle
|
||||
* $SYNTAX$
|
||||
* PI () -> nPi
|
||||
* PI() -> nPi
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
@@ -23,7 +23,7 @@
|
||||
* // the diameter of a circle-like swimming pool is 3.4 meters, how
|
||||
* // long is the perimeter ?
|
||||
*
|
||||
* ? str(PI()*3.4,5,3)+" meters" --> 10.681 meters
|
||||
* ? Str( PI() * 3.4, 5, 3 ) + " meters" // --> 10.681 meters
|
||||
* $TESTS$
|
||||
*
|
||||
* $STATUS$
|
||||
@@ -59,13 +59,13 @@
|
||||
* A common geometric interpretation of the SIN() function is the
|
||||
* counterkathede-hypotenuse-ratio of a right-angled triangle.
|
||||
* $EXAMPLES$
|
||||
* ? sin (0.0) --> 0.0
|
||||
* ? sin (1.0) --> 0.8414...
|
||||
* ? sin( 0.0 ) // --> 0.0
|
||||
* ? sin( 1.0 ) // --> 0.8414...
|
||||
* $TESTS$
|
||||
* sin (0.0) == 0.0
|
||||
* sin (PI()/4) == sqrt(1/2)
|
||||
* sin (PI()/2) == 1.0
|
||||
* sin (PI()) == 0.0
|
||||
* sin( 0.0 ) == 0.0
|
||||
* sin( PI() / 4 ) == sqrt( 1 / 2 )
|
||||
* sin( PI() / 2 ) == 1.0
|
||||
* sin( PI() ) == 0.0
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -87,7 +87,7 @@
|
||||
* $ONELINER$
|
||||
* Cosine of the argument
|
||||
* $SYNTAX$
|
||||
* COS (nRadiant) -> nCosine
|
||||
* COS( nRadiant ) -> nCosine
|
||||
* $ARGUMENTS$
|
||||
* <nRadiant> an angle size given in radiants
|
||||
* $RETURNS$
|
||||
@@ -99,13 +99,13 @@
|
||||
* A common geometric interpretation of the COS() function is the
|
||||
* ankathede-hypotenuse-ratio of a right-angled triangle.
|
||||
* $EXAMPLES$
|
||||
* ? cos (0.0) --> 1.0
|
||||
* ? cos (1.0) --> 0.5403...
|
||||
* ? cos( 0.0 ) // --> 1.0
|
||||
* ? cos( 1.0 ) // --> 0.5403...
|
||||
* $TESTS$
|
||||
* cos (0.0) == 1.0
|
||||
* cos (PI()/4) == sqrt(1/2)
|
||||
* cos (PI()/2) == 0.0
|
||||
* cos (PI()) == -1.0
|
||||
* cos( 0.0) == 1.0
|
||||
* cos( PI() / 4 ) == sqrt( 1 / 2 )
|
||||
* cos( PI() / 2 ) == 0.0
|
||||
* cos( PI() ) == -1.0
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -127,7 +127,7 @@
|
||||
* $ONELINER$
|
||||
* Tangent of the argument
|
||||
* $SYNTAX$
|
||||
* TAN (nRadiant) -> nTangent
|
||||
* TAN( nRadiant ) -> nTangent
|
||||
* $ARGUMENTS$
|
||||
* <nRadiant> an angle size given in radiants
|
||||
* $RETURNS$
|
||||
@@ -140,12 +140,12 @@
|
||||
* counterkathede-ankathede-ratio of a right-angled triangle, or,
|
||||
* tan(x) = sin(x)/cos(x).
|
||||
* $EXAMPLES$
|
||||
* ? tan (0.0) --> 0.0
|
||||
* ? tan (1.0) --> 1.5574...
|
||||
* ? tan( 0.0 ) // --> 0.0
|
||||
* ? tan( 1.0 ) // --> 1.5574...
|
||||
* $TESTS$
|
||||
* tan (0.0) == 0.0
|
||||
* tan (PI()/4) == 1
|
||||
* tan (PI()) == 0.0
|
||||
* tan( 0.0 ) == 0.0
|
||||
* tan( PI() / 4 ) == 1
|
||||
* tan( PI() ) == 0.0
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -167,7 +167,7 @@
|
||||
* $ONELINER$
|
||||
* Cotangent of the argument
|
||||
* $SYNTAX$
|
||||
* COT (nRadiant) -> nCotangent
|
||||
* COT( nRadiant ) -> nCotangent
|
||||
* $ARGUMENTS$
|
||||
* <nRadiant> an angle size given in radiants
|
||||
* $RETURNS$
|
||||
@@ -180,10 +180,10 @@
|
||||
* ankathede-counterkathede-ratio of a right-angled triangle, or,
|
||||
* cot(x) = cos(x)/sin(x)=1/tan(x).
|
||||
* $EXAMPLES$
|
||||
* ? cot (1.0) --> 0.6420...
|
||||
* ? cot( 1.0 ) // --> 0.6420...
|
||||
* $TESTS$
|
||||
* cot (PI()/4) == 1
|
||||
* cot (PI()/2) == 0
|
||||
* cot( PI() / 4 ) == 1
|
||||
* cot( PI() / 2 ) == 0
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -205,7 +205,7 @@
|
||||
* $ONELINER$
|
||||
* Arcus sine of the argument
|
||||
* $SYNTAX$
|
||||
* ASIN (nSine) -> nRadiant
|
||||
* ASIN( nSine ) -> nRadiant
|
||||
* $ARGUMENTS$
|
||||
* <nSine> the sine of an angle
|
||||
* $RETURNS$
|
||||
@@ -218,13 +218,13 @@
|
||||
* Note, that <nSine> must be between -1 and 1 and that <nRadiant>
|
||||
* is always between -PI()/2 and PI()/2.
|
||||
* $EXAMPLES$
|
||||
* ? asin (0.0) --> 0.0
|
||||
* ? asin (0.5) --> 0.5235...
|
||||
* ? asin( 0.0 ) // --> 0.0
|
||||
* ? asin( 0.5 ) // --> 0.5235...
|
||||
* $TESTS$
|
||||
* asin (0.0) == 0.0
|
||||
* asin (sqrt(1/2)) == PI()/4
|
||||
* asin (1.0) == PI()/2
|
||||
* asin (0.0) == 0.0 // and not PI(), since the smallest angle is returned !
|
||||
* asin( 0.0 ) == 0.0
|
||||
* asin( sqrt( 1 / 2 ) ) == PI() / 4
|
||||
* asin( 1.0 ) == PI() / 2
|
||||
* asin( 0.0 ) == 0.0 // and not PI(), since the smallest angle is returned !
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -246,7 +246,7 @@
|
||||
* $ONELINER$
|
||||
* Arcus cosine of the argument
|
||||
* $SYNTAX$
|
||||
* ACOS (nCosine) -> nRadiant
|
||||
* ACOS( nCosine ) -> nRadiant
|
||||
* $ARGUMENTS$
|
||||
* <nCosine> the cosine of an angle
|
||||
* $RETURNS$
|
||||
@@ -259,14 +259,14 @@
|
||||
* Note, that <nCosine> must be between -1 and 1 and that <nRadiant>
|
||||
* is always between 0 and PI().
|
||||
* $EXAMPLES$
|
||||
* ? acos (0.0) --> PI()/2
|
||||
* ? acos (0.5) --> 1.04719...
|
||||
* ? acos( 0.0 ) // --> PI() / 2
|
||||
* ? acos( 0.5 ) // --> 1.04719...
|
||||
* $TESTS$
|
||||
* acos (0.0) == PI()/2
|
||||
* acos (sqrt(1/2)) == PI()/4
|
||||
* acos (1.0) == 0.0
|
||||
* acos (-1.0) == PI()
|
||||
* acos (0.0) == PI()/2 // and not -PI()/2, although cos (-PI()/2) == 0.0 !
|
||||
* acos( 0.0 ) == PI() / 2
|
||||
* acos( sqrt( 1 / 2 ) ) == PI() / 4
|
||||
* acos( 1.0 ) == 0.0
|
||||
* acos( -1.0 ) == PI()
|
||||
* acos( 0.0 ) == PI() / 2 // and not -PI()/2, although cos (-PI()/2) == 0.0 !
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -288,7 +288,7 @@
|
||||
* $ONELINER$
|
||||
* Arcus tangent of the argument
|
||||
* $SYNTAX$
|
||||
* ACOS (nTangent) -> nRadiant
|
||||
* ACOS( nTangent ) -> nRadiant
|
||||
* $ARGUMENTS$
|
||||
* <nTangent> the tangent of an angle
|
||||
* $RETURNS$
|
||||
@@ -299,12 +299,12 @@
|
||||
* The return value is given in radiants between -PI()/2 and PI()/2
|
||||
* (full angle equals 2*Pi - see DTOR() if you need to convert it into degress).
|
||||
* $EXAMPLES$
|
||||
* ? atan (0.0) --> 0.0
|
||||
* ? atan (0.5) --> 0.4636...
|
||||
* ? atan( 0.0 ) // --> 0.0
|
||||
* ? atan( 0.5 ) // --> 0.4636...
|
||||
* $TESTS$
|
||||
* atan (0.0) == 0.0
|
||||
* atan (1.0) == PI()/4
|
||||
* atan (0.0) == 0.0 // and not PI(), although tan (PI()) == 0.0 !
|
||||
* atan( 0.0 ) == 0.0
|
||||
* atan( 1.0 ) == PI() / 4
|
||||
* atan( 0.0 ) == 0.0 // and not PI(), although tan( PI() ) == 0.0 !
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -326,7 +326,7 @@
|
||||
* $ONELINER$
|
||||
* Arcus tangent a sine and a cosine argument
|
||||
* $SYNTAX$
|
||||
* ATN2 (nSine, nCosine) -> nRadiant
|
||||
* ATN2( nSine, nCosine ) -> nRadiant
|
||||
* $ARGUMENTS$
|
||||
* <nSine> the sine of an angle
|
||||
* <nCosine> the cosine of an angle
|
||||
@@ -344,12 +344,12 @@
|
||||
* The return value is given in radiants (full angle equals 2*Pi -
|
||||
* see DTOR() if you need to convert it into degress).
|
||||
* $EXAMPLES$
|
||||
* ? atn2 (0.0, 1.0) --> 0.0
|
||||
* ? atn2 (sqrt(1/2), sqrt(1/2)) --> PI()/4
|
||||
* ? atn2( 0.0, 1.0 ) // --> 0.0
|
||||
* ? atn2( sqrt( 1 / 2 ), sqrt( 1 / 2 ) ) // --> PI() / 4
|
||||
* $TESTS$
|
||||
* atn2 (0.0, 1.0) == 0.0
|
||||
* atn2 (sqrt(1/2),sqrt(1/2)) == PI()/4
|
||||
* atn2 (-sqrt(1/2),-sqrt(1/2)) == -3/4*PI() // atan() would return PI()/4 !
|
||||
* atn2( 0.0, 1.0 ) == 0.0
|
||||
* atn2( sqrt( 1 / 2 ), sqrt( 1 / 2 ) ) == PI() / 4
|
||||
* atn2( -sqrt( 1 / 2 ), -sqrt( 1 / 2 ) ) == -3 / 4 * PI() // atan() would return PI() / 4 !
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -371,7 +371,7 @@
|
||||
* $ONELINER$
|
||||
* Hyperbolic Sine of the argument
|
||||
* $SYNTAX$
|
||||
* SINH (nArea) -> nHyperbolicSine
|
||||
* SINH( nArea ) -> nHyperbolicSine
|
||||
* $ARGUMENTS$
|
||||
* <nArea> the size of the area (see below)
|
||||
* $RETURNS$
|
||||
@@ -384,11 +384,11 @@
|
||||
* that is bound by the x axis, a straight line through the point of
|
||||
* origin (this one is fixed by the area) and the hyperbola x^2-y^2=1.
|
||||
* $EXAMPLES$
|
||||
* ? sinh (0.0) --> 0.0
|
||||
* ? sinh (1.0) --> 1.1752...
|
||||
* ? sinh( 0.0 ) // --> 0.0
|
||||
* ? sinh( 1.0 ) // --> 1.1752...
|
||||
* $TESTS$
|
||||
* sinh (0.0) == 0.0
|
||||
* sinh (-0.5) == -sinh(0.5)
|
||||
* sinh( 0.0 ) == 0.0
|
||||
* sinh( -0.5 ) == -sinh( 0.5 )
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -410,7 +410,7 @@
|
||||
* $ONELINER$
|
||||
* Hyperbolic Cosine of the argument
|
||||
* $SYNTAX$
|
||||
* COSH (nArea) -> nHyperbolicCosine
|
||||
* COSH( nArea ) -> nHyperbolicCosine
|
||||
* $ARGUMENTS$
|
||||
* <nArea> the size of the area (see below)
|
||||
* $RETURNS$
|
||||
@@ -423,11 +423,11 @@
|
||||
* that is bound by the x axis, a straight line through the point of
|
||||
* origin (this one is fixed by the area) and the hyperbola x^2-y^2=1.
|
||||
* $EXAMPLES$
|
||||
* ? cosh (0.0) --> 1.0
|
||||
* ? cosh (1.0) --> 1.5430...
|
||||
* ? cosh( 0.0 ) // --> 1.0
|
||||
* ? cosh( 1.0 ) // --> 1.5430...
|
||||
* $TESTS$
|
||||
* cosh (0.0) == 1.0
|
||||
* cosh (-0.5) == cosh(0.5)
|
||||
* cosh( 0.0 ) == 1.0
|
||||
* cosh( -0.5 ) == cosh( 0.5 )
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -449,7 +449,7 @@
|
||||
* $ONELINER$
|
||||
* Hyperbolic Tangent of the argument
|
||||
* $SYNTAX$
|
||||
* TANH (nArea) -> nHyperbolicTangent
|
||||
* TANH( nArea ) -> nHyperbolicTangent
|
||||
* $ARGUMENTS$
|
||||
* <nArea> the size of the area (see below)
|
||||
* $RETURNS$
|
||||
@@ -458,11 +458,11 @@
|
||||
* The function TANH() calculates the hyperbolic tangent of the argument.
|
||||
* In analytical mathematics it is defined as SINH(x)/COSH(x).
|
||||
* $EXAMPLES$
|
||||
* ? tanh (0.0) --> 0.0
|
||||
* ? tanh (1.0) --> 0.7615...
|
||||
* ? tanh( 0.0 ) // --> 0.0
|
||||
* ? tanh( 1.0 ) // --> 0.7615...
|
||||
* $TESTS$
|
||||
* tanh (0.0) == 0.0
|
||||
* tanh (-0.5) == -tanh(0.5)
|
||||
* tanh( 0.0 ) == 0.0
|
||||
* tanh( -0.5 ) == -tanh( 0.5 )
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -484,7 +484,7 @@
|
||||
* $ONELINER$
|
||||
* Convert radiant to degree
|
||||
* $SYNTAX$
|
||||
* RTOD (nRadiant) -> nDegree
|
||||
* RTOD( nRadiant ) -> nDegree
|
||||
* $ARGUMENTS$
|
||||
* <nRadiant> the size of an angle in radiant
|
||||
* $RETURNS$
|
||||
@@ -494,11 +494,11 @@
|
||||
* in radiant (like those returned by the asin, acos or atan function)
|
||||
* to degrees that are commonly used geometry and technics.
|
||||
* $EXAMPLES$
|
||||
* ? rtod (PI()) --> 180
|
||||
* ? tanh (PI()/3) --> 60
|
||||
* ? rtod( PI() ) // --> 180
|
||||
* ? tanh( PI() / 3 ) // --> 60
|
||||
* $TESTS$
|
||||
* rtod (0.0) == 0.0
|
||||
* rtod (PI()) == 180.0
|
||||
* rtod( 0.0 ) == 0.0
|
||||
* rtod( PI() ) == 180.0
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
@@ -520,7 +520,7 @@
|
||||
* $ONELINER$
|
||||
* Convert degree to radiant
|
||||
* $SYNTAX$
|
||||
* DTOR (nDegree) -> nRadiant
|
||||
* DTOR( nDegree ) -> nRadiant
|
||||
* $ARGUMENTS$
|
||||
* <nDegree> the size of that angle in degree
|
||||
* $RETURNS$
|
||||
@@ -529,11 +529,11 @@
|
||||
* The function DTOR() can be used to convert sizes of angles given
|
||||
* in degrees to radiant (as expected by sin, cos or tan functions).
|
||||
* $EXAMPLES$
|
||||
* ? dtor (180) --> PI()
|
||||
* ? dtor (60) --> PI()/3
|
||||
* ? dtor( 180 ) // --> PI()
|
||||
* ? dtor( 60 ) // --> PI() / 3
|
||||
* $TESTS$
|
||||
* dtor (0.0) == 0.0
|
||||
* dtor (180.0) == PI()
|
||||
* dtor( 0.0 ) == 0.0
|
||||
* dtor( 180.0 ) == PI()
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -42,8 +42,8 @@
|
||||
* $ONELINER$
|
||||
* Changes VGA palette colors
|
||||
* $SYNTAX$
|
||||
* VGAPALETTE([<cColor|nColor>, [<nRedValue>, <nGreenValue>,
|
||||
* <nBlueValue]]) --> lValid
|
||||
* VGAPALETTE( [<cColor|nColor>, [<nRedValue>, <nGreenValue>,
|
||||
* <nBlueValue]] ) --> lValid
|
||||
* $ARGUMENTS$
|
||||
* <cColor|nColor> - the color to change in CA-Cl*pper color notation or
|
||||
* as a number from 0 to 15.
|
||||
@@ -114,9 +114,9 @@
|
||||
* $ONELINER$
|
||||
* Loads font from a string.
|
||||
* $SYNTAX$
|
||||
* SETFONT(<cFontString>, [<nFontArea>], [<nOffset>], [<nCounter>]) --> nError
|
||||
* SETFONT( <cFontString>, [<nFontArea>], [<nOffset>], [<nCounter>] ) --> nError
|
||||
* or:
|
||||
* SETFONT(<cFontString>, [<nFontArea>], [<lCompute>]) --> nError
|
||||
* SETFONT( <cFontString>, [<nFontArea>], [<lCompute>] ) --> nError
|
||||
* $ARGUMENTS$
|
||||
* <cFontString> Binary string containing a valid font definition.
|
||||
* <nFontArea> Number of a font area where the font must be loaded.
|
||||
|
||||
@@ -10,8 +10,8 @@
|
||||
* $ONELINER$
|
||||
* Replacement of double characters
|
||||
* $SYNTAX$
|
||||
* WORDREPL (<cDoubleCharacterSearchString>, <[@]cString>,
|
||||
* <cDoubleCharacterReplaceString>, [<lMode>]) -> cString
|
||||
* WORDREPL( <cDoubleCharacterSearchString>, <[@]cString>,
|
||||
* <cDoubleCharacterReplaceString>, [<lMode>] ) -> cString
|
||||
* $ARGUMENTS$
|
||||
* <cDoubleCharacterSearchString> is a string of double characters
|
||||
* that should be replaced
|
||||
@@ -41,18 +41,18 @@
|
||||
* One can omit the return value of this function by setting the CSETREF()
|
||||
* to .T., but one must then pass <cString> by reference to get a result.
|
||||
* $EXAMPLES$
|
||||
* ? wordrepl("CC", "AABBCCDDEE", "XX") // "AABBXXDDEE"
|
||||
* ? wordrepl("aa", "1aaaa", "ba") // "1abaa"
|
||||
* ? wordrepl("aa", "1aaaa", "ba", .T.) // "1baba"
|
||||
* csetatmupa(.T.)
|
||||
* ? wordrepl("aa", "1aaaa", "ba") // "1abaa"
|
||||
* ? wordrepl("aa", "1aaaa", "ba", .T.) // "1bbba"
|
||||
* ? wordrepl( "CC", "AABBCCDDEE", "XX" ) // "AABBXXDDEE"
|
||||
* ? wordrepl( "aa", "1aaaa", "ba" ) // "1abaa"
|
||||
* ? wordrepl( "aa", "1aaaa", "ba", .T. ) // "1baba"
|
||||
* csetatmupa( .T. )
|
||||
* ? wordrepl( "aa", "1aaaa", "ba" ) // "1abaa"
|
||||
* ? wordrepl( "aa", "1aaaa", "ba", .T. ) // "1bbba"
|
||||
* $TESTS$
|
||||
* wordrepl("CC", "AABBCCDDEE", "XX") == "AABBXXDDEE"
|
||||
* wordrepl("aa", "1aaaa", "ba") == "1abaa"
|
||||
* wordrepl("aa", "1aaaa", "ba", .T.) == "1baba"
|
||||
* eval ({||csetatmupa(.T.),wordrepl("aa", "1aaaa", "ba")}) == "1abaa"
|
||||
* eval ({||csetatmupa(.T.),wordrepl("aa", "1aaaa", "ba", .T.)}) == "1bbba"
|
||||
* wordrepl( "CC", "AABBCCDDEE", "XX" ) == "AABBXXDDEE"
|
||||
* wordrepl( "aa", "1aaaa", "ba" ) == "1abaa"
|
||||
* wordrepl( "aa", "1aaaa", "ba", .T. ) == "1baba"
|
||||
* Eval( {|| csetatmupa( .T. ), wordrepl( "aa", "1aaaa", "ba" ) } ) == "1abaa"
|
||||
* Eval( {|| csetatmupa( .T. ), wordrepl( "aa", "1aaaa", "ba", .T. ) } ) == "1bbba"
|
||||
* $STATUS$
|
||||
* Ready
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -10,8 +10,8 @@
|
||||
* $ONELINER$
|
||||
* Replace double with single characters
|
||||
* $SYNTAX$
|
||||
* WORDTOCHAR (<cDoubleCharacterSearchString>, <cString>,
|
||||
* <cSingleCharacterReplaceString>) -> cString
|
||||
* WORDTOCHAR( <cDoubleCharacterSearchString>, <cString>,
|
||||
* <cSingleCharacterReplaceString> ) -> cString
|
||||
* $ARGUMENTS$
|
||||
*
|
||||
* $RETURNS$
|
||||
|
||||
Reference in New Issue
Block a user