Implemented new function...
This commit is contained in:
parent
9d8d83d38f
commit
cc0701d408
18
xtandard.c
18
xtandard.c
@ -698,6 +698,24 @@ int string_split_space (char * string) {
|
|||||||
return (++count);
|
return (++count);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
char * string_realign (char * string, int amount, char character) {
|
||||||
|
int offset, length;
|
||||||
|
|
||||||
|
length = string_length (string);
|
||||||
|
|
||||||
|
for (offset = 0; offset != length; ++offset) {
|
||||||
|
string [amount - offset - 1] = string [length - offset - 1];
|
||||||
|
}
|
||||||
|
|
||||||
|
for (offset = 0; offset != amount - length; ++offset) {
|
||||||
|
string [offset] = character;
|
||||||
|
}
|
||||||
|
|
||||||
|
string [amount] = '\0';
|
||||||
|
|
||||||
|
return (string);
|
||||||
|
}
|
||||||
|
|
||||||
void memory_delete (void * memory, int length) {
|
void memory_delete (void * memory, int length) {
|
||||||
int i = 0;
|
int i = 0;
|
||||||
|
|
||||||
|
@ -121,6 +121,8 @@ extern char * string_concatenate_limit (char * string_0, char * string_1, int li
|
|||||||
|
|
||||||
extern int string_split_space (char * string);
|
extern int string_split_space (char * string);
|
||||||
|
|
||||||
|
extern char * string_realign (char * string, int amount, char character);
|
||||||
|
|
||||||
extern void memory_delete (void * memory, int length);
|
extern void memory_delete (void * memory, int length);
|
||||||
|
|
||||||
extern int memory_compare (void * memory, void * source, int length);
|
extern int memory_compare (void * memory, void * source, int length);
|
||||||
|
Loading…
Reference in New Issue
Block a user