-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathft_printf.h
More file actions
52 lines (46 loc) · 1.91 KB
/
ft_printf.h
File metadata and controls
52 lines (46 loc) · 1.91 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_printf.h :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: jzubizar <jzubizar@student.42urduliz.co +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2023/04/27 18:34:23 by jzubizar #+# #+# */
/* Updated: 2023/07/10 13:05:19 by jzubizar ### ########.fr */
/* */
/* ************************************************************************** */
#ifndef FT_PRINTF_H
# define FT_PRINTF_H
# include <stdlib.h>
# include <unistd.h>
# include <stdarg.h>
# include <stdint.h>
# include "./libft/libft.h"
typedef struct s_flag
{
int zeros;
int justify;
int precision;
int precwidth;
int width;
int hash;
int space;
int plus;
} t_flag;
int ft_putunbr_fd(unsigned int n, int fd, t_flag flags);
int ft_putxnbr_fd(unsigned int n, t_flag flags);
int ft_putxmnbr_fd(unsigned int n, t_flag flags);
int ft_putxptr_fd(void *n, int fd, t_flag flags);
size_t ft_pfstrlen(const char *s);
int ft_pfputstr_fd(const char *s, int fd);
char ft_is_type(char c);
int ft_printf(const char *str, ...);
int ft_pfputnbr_fd(int n, int fd, t_flag flags);
int ft_pfputargstr_fd(const char *s, int fd, t_flag flags);
int ft_print_nbr(char *nbr, t_flag flags, int n);
int ft_precision_nul(t_flag *flags);
int ft_print_char_fd(char c, t_flag flags, int fd);
t_flag ft_flags_zeros(void);
int ft_process_flags(int i, t_flag *flags, const char *str);
int ft_print_width(int tot_width, int filled, int zeros);
#endif