2022-12-22 11:41:31 -05:00
|
|
|
/* ************************************************************************** */
|
|
|
|
/* */
|
|
|
|
/* ::: :::::::: */
|
|
|
|
/* main.c :+: :+: :+: */
|
|
|
|
/* +:+ +:+ +:+ */
|
|
|
|
/* By: cchauvet <cchauvet@student.42angouleme.fr +#+ +:+ +#+ */
|
|
|
|
/* +#+#+#+#+#+ +#+ */
|
|
|
|
/* Created: 2022/12/12 17:20:17 by cchauvet #+# #+# */
|
2023-01-04 14:07:13 -05:00
|
|
|
/* Updated: 2023/01/04 19:47:28 by cchauvet ### ########.fr */
|
2022-12-22 11:41:31 -05:00
|
|
|
/* */
|
|
|
|
/* ************************************************************************** */
|
|
|
|
|
|
|
|
#include "solong.h"
|
|
|
|
|
|
|
|
int main(void)
|
|
|
|
{
|
|
|
|
void *window_manager;
|
|
|
|
void *window;
|
2023-01-04 14:07:13 -05:00
|
|
|
t_shape shape;
|
2022-12-22 11:41:31 -05:00
|
|
|
|
|
|
|
window_manager = mlx_init();
|
|
|
|
window = mlx_new_window(window_manager, 500, 500, "Hello world!");
|
2023-01-04 14:07:13 -05:00
|
|
|
shape.x = 10;
|
|
|
|
shape.y = 10;
|
|
|
|
shape.size = 100;
|
|
|
|
shape.color = ft_strdup("purple");
|
|
|
|
shape.bcolor = ft_strdup("black");
|
|
|
|
shape.shape = ft_strdup("square");
|
|
|
|
ft_xpm_gen_file(shape);
|
|
|
|
free(shape.color);
|
|
|
|
free(shape.bcolor);
|
|
|
|
free(shape.shape);
|
2022-12-22 11:41:31 -05:00
|
|
|
mlx_loop(window_manager);
|
2023-01-04 14:07:13 -05:00
|
|
|
mlx_destroy_window(window_manager, window);
|
|
|
|
mlx_destroy_display(window_manager);
|
|
|
|
free(window_manager);
|
2022-12-22 11:41:31 -05:00
|
|
|
}
|