1
{$IfDef read_interface}
7
function gnome_libdir_file(filename:Pchar):pchar;cdecl;external libgnomedll name 'gnome_libdir_file';
8
function gnome_datadir_file(filename:Pchar):pchar;cdecl;external libgnomedll name 'gnome_datadir_file';
9
function gnome_sound_file(filename:Pchar):pchar;cdecl;external libgnomedll name 'gnome_sound_file';
10
function gnome_pixmap_file(filename:Pchar):pchar;cdecl;external libgnomedll name 'gnome_pixmap_file';
11
function gnome_config_file(filename:Pchar):pchar;cdecl;external libgnomedll name 'gnome_config_file';
12
function gnome_unconditional_libdir_file(filename:Pchar):pchar;cdecl;external libgnomedll name 'gnome_unconditional_libdir_file';
13
function gnome_unconditional_datadir_file(filename:Pchar):pchar;cdecl;external libgnomedll name 'gnome_unconditional_datadir_file';
14
function gnome_unconditional_sound_file(filename:Pchar):pchar;cdecl;external libgnomedll name 'gnome_unconditional_sound_file';
15
function gnome_unconditional_pixmap_file(filename:Pchar):pchar;cdecl;external libgnomedll name 'gnome_unconditional_pixmap_file';
16
function gnome_unconditional_config_file(filename:Pchar):pchar;cdecl;external libgnomedll name 'gnome_unconditional_config_file';
19
G_FILE_TEST_EXISTS = ((1 shl 0) or (1 shl 1)) or (1 shl 2);
20
G_FILE_TEST_ISFILE = 1 shl 0;
21
G_FILE_TEST_ISLINK = 1 shl 1;
22
G_FILE_TEST_ISDIR = 1 shl 2;
24
function g_file_test(filename:Pchar; test:longint):longint;cdecl;external libgnomedll name 'g_file_test';
25
function g_file_exists(filename:Pchar):longint;cdecl;external libgnomedll name 'g_file_exists';
26
function gnome_is_program_in_path(aprogram:Pgchar):Pgchar;cdecl;external libgnomedll name 'gnome_is_program_in_path';
28
function g_unix_error_string(error_num:longint):pchar;cdecl;external libgnomedll name 'g_unix_error_string';
29
function g_concat_dir_and_file(dir:Pchar; afile:Pchar):pchar;cdecl;external libgnomedll name 'g_concat_dir_and_file';
31
function g_extension_pointer(path:Pchar):pchar;cdecl;external libgnomedll name 'g_extension_pointer';
32
function g_copy_vector(vec:PPchar):Ppchar;cdecl;external libgnomedll name 'g_copy_vector';
34
function gnome_util_user_shell:pchar;cdecl;external libgnomedll name 'gnome_util_user_shell';
35
function g_is_image_filename(path:Pchar):gboolean;cdecl;external libgnomedll name 'g_is_image_filename';
37
//Function g_copy_strings(string1:Pgchar; args:array of const):Pgchar;
38
Function g_filename_index(path : Pgchar) : Pgchar;
39
Function g_filename_pointer(file_name:Pgchar):Pgchar;
40
Function g_flatten_vector(separator:Pgchar; str_array:PPgchar) : Pgchar;
41
Function gnome_util_user_home : Pgchar;
42
Function gnome_util_prepend_user_home(x : Pgchar) : Pgchar;
43
Function gnome_util_home_file(afile : Pgchar) : Pgchar;
45
{$EndIf read_interface}
47
{$Ifdef read_implementation}
48
{Function g_copy_strings(string1:Pgchar; args:array of const):Pgchar;
50
g_copy_strings := g_strconcat(string1, args);
53
Function g_filename_index(path : Pgchar) : Pgchar;
55
g_filename_index := Pointer(Longint(g_basename(path))-Longint(path));
58
Function g_filename_pointer(file_name:Pgchar):Pgchar;
60
g_filename_pointer := g_basename(file_name);
63
Function g_flatten_vector(separator:Pgchar; str_array:PPgchar) : Pgchar;
65
g_flatten_vector := g_strjoinv(separator, str_array);
68
Function gnome_util_user_home : Pgchar;
70
gnome_util_user_home := g_get_home_dir;
73
Function gnome_util_prepend_user_home(x : Pgchar) : PgChar;
75
gnome_util_prepend_user_home := g_concat_dir_and_file(gnome_util_user_home, x);
78
Function gnome_util_home_file(afile : Pgchar) : Pgchar;
80
gnome_util_home_file := g_strconcat(gnome_util_user_home, ['/.gnome/', afile, nil]);
83
{$Endif read_implementation}