Audacious  $Id:Doxyfile42802007-03-2104:39:00Znenolod$
Macros | Functions | Variables
audstrings.c File Reference
#include <limits.h>
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
#include <glib.h>
#include <string.h>
#include <ctype.h>
#include <audacious/i18n.h>
#include "audstrings.h"
#include "config.h"

Go to the source code of this file.

Macros

#define FROM_HEX(c)   ((c) < 'A' ? (c) - '0' : (c) < 'a' ? 10 + (c) - 'A' : 10 + (c) - 'a')
#define TO_HEX(i)   ((i) < 10 ? '0' + (i) : 'A' + (i) - 10)
#define IS_LEGAL(c)

Functions

EXPORT bool_t str_has_prefix_nocase (const char *str, const char *prefix)
EXPORT bool_t str_has_suffix_nocase (const char *str, const char *suffix)
EXPORT void str_set_utf8_impl (char *(*stu_impl)(const char *), char *(*stuf_impl)(const char *, int, int *, int *))
EXPORT char * str_to_utf8 (const char *str)
EXPORT char * str_to_utf8_full (const char *str, int len, int *bytes_read, int *bytes_written)
EXPORT void string_replace_char (char *string, char old_c, char new_c)
EXPORT void str_decode_percent (const char *str, int len, char *out)
EXPORT void str_encode_percent (const char *str, int len, char *out)
EXPORT char * filename_to_uri (const char *name)
EXPORT char * uri_to_filename (const char *uri)
EXPORT char * uri_to_display (const char *uri)
EXPORT void uri_parse (const char *uri, const char **base_p, const char **ext_p, const char **sub_p, int *isub_p)
EXPORT bool_t uri_get_extension (const char *uri, char *buf, int buflen)
EXPORT int string_compare (const char *ap, const char *bp)
EXPORT int string_compare_encoded (const char *ap, const char *bp)
EXPORT char * str_replace_fragment (char *s, int size, const char *old, const char *new)
EXPORT bool_t string_to_int (const char *string, int *addr)
EXPORT bool_t string_to_double (const char *string, double *addr)
EXPORT char * int_to_string (int val)
EXPORT char * double_to_string (double val)
EXPORT bool_t string_to_double_array (const char *string, double *array, int count)
EXPORT char * double_array_to_string (const double *array, int count)

Variables

static char *(* str_to_utf8_impl )(const char *) = NULL
static char *(* str_to_utf8_full_impl )(const char *, int, int *, int *) = NULL

Macro Definition Documentation

#define FROM_HEX (   c)    ((c) < 'A' ? (c) - '0' : (c) < 'a' ? 10 + (c) - 'A' : 10 + (c) - 'a')

Definition at line 34 of file audstrings.c.

Referenced by str_decode_percent(), and string_compare_encoded().

#define IS_LEGAL (   c)
Value:
(((c) >= 'A' && (c) <= 'Z') || ((c) >= 'a' && (c) <= 'z') \
|| ((c) >= '0' && (c) <= '9') || (strchr ("-_.~/", (c))))

Definition at line 36 of file audstrings.c.

Referenced by str_encode_percent().

#define TO_HEX (   i)    ((i) < 10 ? '0' + (i) : 'A' + (i) - 10)

Definition at line 35 of file audstrings.c.

Referenced by str_encode_percent().

Function Documentation

EXPORT char* double_array_to_string ( const double *  array,
int  count 
)

Definition at line 559 of file audstrings.c.

Referenced by eq_set_bands().

EXPORT char* double_to_string ( double  val)

Definition at line 510 of file audstrings.c.

Referenced by double_array_to_string(), and set_double().

EXPORT char* filename_to_uri ( const char *  name)
EXPORT char* int_to_string ( int  val)

Definition at line 504 of file audstrings.c.

Referenced by set_int().

EXPORT void str_decode_percent ( const char *  str,
int  len,
char *  out 
)

Definition at line 87 of file audstrings.c.

Referenced by str_get_decoded(), tuple_set_filename(), uri_to_display(), and uri_to_filename().

EXPORT void str_encode_percent ( const char *  str,
int  len,
char *  out 
)

Definition at line 115 of file audstrings.c.

Referenced by construct_uri(), and filename_to_uri().

EXPORT bool_t str_has_prefix_nocase ( const char *  str,
const char *  prefix 
)

Definition at line 39 of file audstrings.c.

EXPORT bool_t str_has_suffix_nocase ( const char *  str,
const char *  suffix 
)

Definition at line 44 of file audstrings.c.

Referenced by scan_plugin_func().

EXPORT char* str_replace_fragment ( char *  s,
int  size,
const char *  old,
const char *  new 
)

Definition at line 376 of file audstrings.c.

EXPORT void str_set_utf8_impl ( char *(*)(const char *)  stu_impl,
char *(*)(const char *, int, int *, int *)  stuf_impl 
)

Definition at line 58 of file audstrings.c.

Referenced by chardet_init().

EXPORT char* str_to_utf8 ( const char *  str)

Definition at line 65 of file audstrings.c.

EXPORT char* str_to_utf8_full ( const char *  str,
int  len,
int bytes_read,
int bytes_written 
)

Definition at line 71 of file audstrings.c.

EXPORT int string_compare ( const char *  ap,
const char *  bp 
)

Definition at line 278 of file audstrings.c.

Referenced by add_folder(), plugin_compare(), and tuple_compare_string().

EXPORT int string_compare_encoded ( const char *  ap,
const char *  bp 
)

Definition at line 322 of file audstrings.c.

Referenced by filename_compare_basename().

EXPORT void string_replace_char ( char *  string,
char  old_c,
char  new_c 
)
EXPORT bool_t string_to_double ( const char *  string,
double *  addr 
)

Definition at line 450 of file audstrings.c.

Referenced by get_double(), and string_to_double_array().

EXPORT bool_t string_to_double_array ( const char *  string,
double *  array,
int  count 
)

Definition at line 539 of file audstrings.c.

Referenced by eq_get_bands().

EXPORT bool_t string_to_int ( const char *  string,
int addr 
)

Definition at line 423 of file audstrings.c.

Referenced by get_int(), and string_to_double().

EXPORT bool_t uri_get_extension ( const char *  uri,
char *  buf,
int  buflen 
)

Definition at line 256 of file audstrings.c.

Referenced by get_plugin_silent(), and probe_by_extension().

EXPORT void uri_parse ( const char *  uri,
const char **  base_p,
const char **  ext_p,
const char **  sub_p,
int isub_p 
)

Definition at line 219 of file audstrings.c.

Referenced by tuple_set_filename(), uri_get_extension(), and vfs_fopen().

EXPORT char* uri_to_display ( const char *  uri)

Definition at line 196 of file audstrings.c.

EXPORT char* uri_to_filename ( const char *  uri)

Variable Documentation

char*(* str_to_utf8_full_impl)(const char *, int, int *, int *) = NULL
static

Definition at line 56 of file audstrings.c.

Referenced by str_set_utf8_impl(), and str_to_utf8_full().

char*(* str_to_utf8_impl)(const char *) = NULL
static

Definition at line 55 of file audstrings.c.

Referenced by str_set_utf8_impl(), and str_to_utf8().