#include "GArray.h"
Go to the source code of this file.
Typedefs | |
typedef bool(* | RecursiveFileSearch_Callback )(char *Path, class GDirectory *Dir) |
Returns 0 to end search. | |
Enumerations | |
enum | LgiSystemPath { LSP_OS, LSP_OS_LIB, LSP_TEMP, LSP_APP_DATA, LSP_LOCAL_APP_DATA, LSP_DESKTOP, LSP_HOME, LSP_EXE, LSP_TRASH } |
Types of system paths available for querying. More... | |
Functions | |
LgiFunc int | LgiBufConvertCp (void *Out, char *OutCp, int OutLen, void *&In, char *InCp, int &InLen) |
Converts a buffer of text to a different charset. | |
LgiFunc void * | LgiNewConvertCp (char *OutCp, void *In, char *InCp, int InLen=-1) |
Converts a string to a new charset. | |
LgiFunc char16 * | LgiNewUtf8To16 (char *In, int InLen=-1) |
Converts a utf-8 string into a wide character string. | |
LgiFunc char * | LgiNewUtf16To8 (char16 *In, int InLen=-1) |
Converts a wide character string into a utf-8 string. | |
LgiFunc bool | LgiIsCpImplemented (char *Cp) |
Return true if Lgi support the charset. | |
LgiFunc char * | LgiAnsiToLgiCp (int AnsiCodePage=-1) |
Converts the ANSI code page to a charset name. | |
LgiFunc char * | LgiDetectCharset (char *Utf8, int Len=-1, List< char > *Prefs=0) |
Returns the charset that best fits the input data. | |
LgiFunc int | LgiByteLen (void *Str, char *Cp) |
Calculate the byte length of a string. | |
LgiFunc int | LgiCharLen (void *Str, char *Cp, int Bytes=-1) |
Calculate the number of characters in a string. | |
LgiFunc char * | LgiSeekUtf8 (char *Ptr, int D, char *Start=0) |
Move a pointer along a utf-8 string by characters. | |
LgiFunc bool | LgiIsUtf8 (char *s, int len=-1) |
Return true if the string is valid utf-8. | |
LgiFunc char * | LgiToNativeCp (char *In, int InLen=-1) |
Converts a string to the native 8bit charset of the OS from utf-8. | |
LgiFunc char * | LgiFromNativeCp (char *In, int InLen=-1) |
Converts a string from the native 8bit charset of the OS to utf-8. | |
LgiFunc char * | LgiTokStr (char *&s) |
Returns the next token in a string, leaving the argument pointing to the end of the token. | |
LgiFunc void | LgiFormatSize (char *Str, uint64 Size) |
Formats a data size into appropriate units. | |
LgiFunc char * | LgiDecodeUri (char *uri, int len=-1) |
LgiFunc char * | LgiEncodeUri (char *uri, int len=-1) |
LgiFunc bool | LgiGetExeFile (char *Dst, int DstSize) |
Gets the path and file name of the currently running executable. | |
LgiFunc bool | LgiGetExePath (char *Dst, int DstSize) |
Gets the path of the currently running executable. | |
LgiFunc bool | LgiGetTempPath (char *Dst, int DstSize) |
Gets the path of the temporary file directory. | |
LgiFunc bool | LgiGetSystemPath (LgiSystemPath Which, char *Dst, int DstSize) |
Returns the system path specified. | |
LgiFunc char * | LgiFindFile (char *Name) |
Finds a file in the applications directory or nearby. | |
LgiFunc bool | LgiRecursiveFileSearch (char *Root, List< char > *Ext=0, List< char > *Files=0, uint64 *Size=0, uint64 *Count=0, RecursiveFileSearch_Callback Callback=0) |
Recursively search for files. | |
LgiFunc struct GLanguage * | LgiGetLanguageId () |
Gets the currently selected language. | |
LgiFunc char * | LgiLoadString (int Res, char *Default=0) |
Loads a string from the resource file. | |
LgiFunc int | LgiGetOs (int *Ver=0, int *Rev=0) |
Returns the operating system that Lgi is running on. | |
LgiFunc char * | LgiGetOsName () |
Gets the current operation systems name. | |
LgiFunc bool | LgiExecute (char *File, char *Arguments="", char *Dir=".") |
Opens a file or directory. | |
LgiFunc void | LgiRandomize (uint Seed) |
Initializes the random number generator. | |
LgiFunc uint | LgiRand (uint Max=0) |
Returns a random number between 0 and Max-1. | |
LgiFunc bool | LgiPlaySound (char *FileName, int Flags) |
Plays a sound. | |
LgiFunc bool | LgiGetFileMimeType (char *File, char *Mime, int MimeBufSize) |
Returns the mime type of the file. | |
LgiFunc bool | LgiGetAppForMimeType (char *Mime, char *AppPath, int BufSize) |
Returns the application associated with the mime type. | |
LgiFunc bool | LgiGetAppsForMimeType (char *Mime, GArray< GAppInfo * > &Apps, int Limit=-1) |
Returns the all applications that can open a given mime type. | |
LgiFunc uint64 | LgiCurrentTime () |
Gets the current clock in milli-seconds. | |
LgiFunc void | LgiTrace (char *Format,...) |
Writes a debug statement to a file in the executables directory. | |
LgiFunc int | LgiIsReleaseBuild () |
Returns true if the build is for release. |
|
Types of system paths available for querying.
|
|
Converts a string from URI encoding (ala 20 -> ' ')
|
|
Returns the charset that best fits the input data.
|
|
Converts a string to URI encoding (ala 20 -> ' ')
|
|
Opens a file or directory. If the input is an executable then it is run. If the input file is a document then an appropriate application is found to open the file and the file is passed to that application. If the input is a directory then the OS's file manager is openned to browse the directory.
|
|
Formats a data size into appropriate units.
|
|
Returns the application associated with the mime type.
|
|
Returns the all applications that can open a given mime type.
|
|
Returns the mime type of the file.
|
|
Returns the operating system that Lgi is running on.
|
|
Returns the system path specified.
|
|
Converts a string to a new charset.
|
|
Converts a wide character string into a utf-8 string.
|
|
Plays a sound.
|
|
Recursively search for files.
|
|
Move a pointer along a utf-8 string by characters.
|