Class Module
15 Members
Co Decs Class
Entisoft Tools 2.0 Object Library · CoDecs · 14 Functions · 0 Properties · 0 Subroutines
Declarations
Declarations
Compress and decompress strings using various text compression techniques such as run length encoding. Copyright 1998 Entisoft
Section
CompressString
Compress String
Compress a string using whichever text compression technique can compress it the most. This function will compress the string using either the RunLengthEncode function or SqueezeString function.
Function
DecompressString
Decompress String
Decompress a string which was compressed with the CompressString functions. Uses the first character of the string to identify which text decompression algorithm to use to decompress the string.
Function
DecompressStringLength
Decompress String Length
Returns the length of the decompressed version of a string that was compressed with the CompressString function.
Function
DeTab
De Tab
"Expand Tabs To Spaces" Replaces tab characters (Chr$(9)) with the number of spaces required to advance the print position to the next tab stop. Function assumes that there is a tab stop every vTabWidth characters.
Function
EnTab
En Tab
"Compress Spaces To Tabs" Replaces sequences of space characters which overlap tab stop positions with tab characters (Chr$(9)) thereby reducing the space required to store strings which contain many spaces. Function assumes that there is a tab stop every vTabWidth characters.
Function
EnTabTable
En Tab Table
"Compress Spaces To Tabs" Replaces sequences of space characters which overlap tab stop positions with tab characters (Chr$(9)) thereby reducing the space required to store strings which contain many spaces. Function assumes that there is a tab stop after every character position mentioned within array vTabStops.
Function
RunLengthDecode
Run Length Decode
Decode a string which was run length encoded (RLE) with a function like RunLengthEncode . Run length code strings are replaced by repeated runs of the specified character.
Function
RunLengthDecodeLength
Run Length Decode Length
Return the length of the decoded version of a run-length-encoded string.
Function
RunLengthDecodePrintable
Run Length Decode Printable
Decode a string which was encoded with RunLengthEncodePrintable . This function is mainly used to decompress Visual Basic Global/Public Constant strings which are to contain "non-printable" characters (or those characters which Microsoft recommends should not appear within Visual Basic nor VBA Modules).
Function
RunLengthEncode
Run Length Encode
Encode a string by replacing repeated runs of the same character with a run length code strings. The run length code strings describe the character which is repeated and the number of times it was repeated.
Function
RunLengthEncodePrintable
Run Length Encode Printable
Encode a string by replacing repeated runs of characters with a run length code. Accepts a string containing ASCII values between 0 and 255 and returns a run-length-encoded string whose characters all have ASCII values within the range from 32 to 126 inclusive.
Function
SqueezeString
Squeeze String
Compresses a string by replacing certain pairs of characters with a single character and by replacing certain infrequently-occurring characters with a two-character sequence. This function achieves an average of 40% compression on English language text strings.
Function
UnsqueezeString
Unsqueeze String
Decompresses a string which was "squeezed" with the SqueezeString function.
Function
UnsqueezeStringLength
Unsqueeze String Length
Return the length of the decoded version of a squeezed string.
Function