MLV_text_va.h(3)

📦
version 3.1.0 · 2 versions
, in ubuntu jammy

okay so bestie, gather round, because this is MLV_text_va.h — page 3 of the Library Functions Manual — and it's literally the va_list era of the MLV text-and-dialogue-box saga. Same functions you know and love, except instead of a variable number of arguments you slide in a va_list like a ✨ VIP pass ✨. No cap.


🌸 NAME 🌸

MLV_text_va.h — ce fichier il définit plusieurs prototypes de fonctions qui te laissent afficher du texte et des boîtes de dialogues. It's giving "the header that makes your messages pop", fr fr. 💅


🦋 SYNOPSIS 🦋

✨ Fonctions ✨

void MLV_draw_text_va (int x, int y, const char *text, MLV_Color color, va_list pile)

Elle imprime un texte que tu lui donnes, à une position et dans une couleur que tu lui donnes aussi.

void MLV_draw_text_with_font_va (int x, int y, const char *text, const MLV_Font *font, MLV_Color color, va_list pile)

Elle écrit du texte sur l'écran en utilisant une couleur et une fonte de caractères que tu passes en paramètres.

void MLV_draw_text_with_font_on_image_va (int x, int y, const char *text, const MLV_Font *font, MLV_Color color, MLV_Image *image, va_list pile)

Elle écrit du texte sur une image, en utilisant une couleur et une fonte de caractères que tu passes en paramètres.

void MLV_get_size_of_text_va (const char *text, int *width, int *height, va_list pile)

Cette fonction elle calcule la taille du texte qui sera affiché sur l'écran à l'aide de la fonction MLV_draw_text().

void MLV_get_size_of_text_with_font_va (const char *text, int *width, int *height, const MLV_Font *font, va_list pile)

Cette fonction elle calcule la taille du texte qui sera affiché sur l'écran à l'aide de la fonction MLV_draw_text_with_font().

void MLV_draw_adapted_text_box_with_font_va (int x, int y, const char *message, const MLV_Font *font, int sizeInterligne, MLV_Color borderColor, MLV_Color textColor, MLV_Color backgroundColor, MLV_Text_justification text_justification, va_list pile)

Même chose que MLV_draw_adapted_text_box(), sauf que le texte est rendu avec une fonte de caractères donnée en paramètre.

void MLV_draw_adapted_text_box_va (int x, int y, const char *message, int sizeInterligne, MLV_Color borderColor, MLV_Color textColor, MLV_Color backgroundColor, MLV_Text_justification text_justification, va_list pile)

Elle dessine une boîte contenant du texte.

void MLV_draw_adapted_text_box_on_image_va (int x, int y, const char *message, int sizeInterligne, MLV_Color borderColor, MLV_Color textColor, MLV_Color backgroundColor, MLV_Text_justification text_justification, MLV_Image *image, va_list pile)

Même chose que MLV_draw_adapted_text_box(), sauf que le texte est rendu avec une fonte de caractères donnée en paramètre.

void MLV_draw_adapted_text_box_with_font_on_image_va (int x, int y, const char *message, const MLV_Font *font, int sizeInterligne, MLV_Color borderColor, MLV_Color textColor, MLV_Color backgroundColor, MLV_Text_justification text_justification, MLV_Image *image, va_list pile)

Même chose que MLV_draw_adapted_text_box_with_font(), sauf que le texte est rendu sur une image et pas directement à l'écran.

int MLV_get_size_of_adapted_text_box_va (const char *message, int sizeInterligne, int *result_width, int *result_height, va_list pile)

Cette fonction elle calcule la taille de la boîte de texte que tu obtiendrais si tu utilisais la fonction : MLV_draw_adapted_text_box().

int MLV_get_size_of_adapted_text_box_with_font_va (const char *message, const MLV_Font *font, int sizeInterligne, int *result_width, int *result_height, va_list pile)

Cette fonction elle calcule la taille de la boîte de texte que tu obtiendrais si tu utilisais la fonction : MLV_draw_adapted_text_box_with_font().

void MLV_draw_text_box_with_font_va (int x, int y, int width, int height, const char *message, const MLV_Font *font, int sizeInterligne, MLV_Color borderColor, MLV_Color textColor, MLV_Color backgroundColor, MLV_Text_justification text_justification, MLV_Horizontal_position horizontal_position, MLV_Vertical_position vertical_position, va_list pile)

Même chose que la fonction MLV_draw_text_box(), sauf que le texte est rendu avec une fonte de caractères que l'utilisateur donne en paramètre.

void MLV_draw_text_box_va (int x, int y, int width, int height, const char *message, int sizeInterligne, MLV_Color borderColor, MLV_Color textColor, MLV_Color backgroundColor, MLV_Text_justification text_justification, MLV_Horizontal_position horizontal_position, MLV_Vertical_position vertical_position, va_list pile)

Elle dessine une boîte de la taille que l'utilisateur donne, et qui contient un texte que l'utilisateur donne aussi.

void MLV_draw_text_box_with_font_on_image_va (int x, int y, int width, int height, const char *message, MLV_Font *font, int sizeInterligne, MLV_Color borderColor, MLV_Color textColor, MLV_Color backgroundColor, MLV_Text_justification text_justification, MLV_Horizontal_position horizontal_position, MLV_Vertical_position vertical_position, MLV_Image *image, va_list pile)

Même chose que la fonction MLV_draw_text_box_with_font(), sauf que le texte n'est pas dessiné directement sur l'écran, mais sur une image.

void MLV_draw_text_box_on_image_va (int x, int y, int width, int height, const char *message, int sizeInterligne, MLV_Color borderColor, MLV_Color textColor, MLV_Color backgroundColor, MLV_Text_justification text_justification, MLV_Horizontal_position horizontal_position, MLV_Vertical_position vertical_position, MLV_Image *image, va_list pile)

Même chose que MLV_draw_text_box(), sauf que le texte n'est pas écrit directement sur l'écran, mais sur une image à la place.


🎀 Description détaillée 🎀

Ce fichier il définit plusieurs prototypes de fonctions qui te permettent d'afficher du texte et des boîtes de dialogues. That's the whole vibe. Un fichier, des prototypes, du texte qui s'affiche. Iconic. 👑

🫶 Auteur 🫶

  • Adrien Boussicault
  • Marc Zipstein

💖 Documentation des fonctions 💖

🌟 MLV_draw_adapted_text_box_on_image_va 🌟

void MLV_draw_adapted_text_box_on_image_va (int x, int y, const char *message, int sizeInterligne, MLV_Color borderColor, MLV_Color textColor, MLV_Color backgroundColor, MLV_Text_justification text_justification, MLV_Image * image, va_list pile)

Même chose que MLV_draw_adapted_text_box(), sauf que le texte est rendu avec une fonte de caractères donnée en paramètre. Cette fonction est équivalente à la fonction MLV_draw_adapted_text_box_on_image(), à l'exception qu'elle est appelée avec un paramètre de type va_list à la place d'un nombre variable d'arguments.

Tu veux plus de détails sur la fonction ? Va voir la documentation de MLV_draw_adapted_text_box_on_image(). 🦋

🌸 Paramètres 🌸

  • x — la coordonnée en X de la position du coin Nord-Ouest de la boîte.
  • y — la coordonnée en Y de la position du coin Nord-Ouest de la boîte.
  • message — le texte à afficher.
  • borderColor — la couleur des bordures.
  • sizeInterligne — la taille de l'interligne.
  • textColor — la couleur du texte.
  • backgroundColor — la couleur du fond de la boîte.
  • text_justification — la justification du texte.
  • image — l'image sur laquelle le texte doit être écrit.
  • pile — une liste d'arguments supplémentaires.

🌟 MLV_draw_adapted_text_box_va 🌟

void MLV_draw_adapted_text_box_va (int x, int y, const char * message, int sizeInterligne, MLV_Color borderColor, MLV_Color textColor, MLV_Color backgroundColor, MLV_Text_justification text_justification, va_list pile)

Elle dessine une boîte contenant du texte. Cette fonction est équivalente à la fonction MLV_draw_adapted_text_box(), à l'exception qu'elle est appelée avec un paramètre de type va_list à la place d'un nombre variable d'arguments.

Pour plus de détails sur la fonction, va voir la documentation de MLV_draw_adapted_text_box(). 🦋

🌸 Paramètres 🌸

  • x — la coordonnée en X de la position du coin Nord-Ouest de la boîte.
  • y — la coordonnée en Y de la position du coin Nord-Ouest de la boîte.
  • message — le texte à afficher.
  • borderColor — la couleur des bordures.
  • sizeInterligne — la taille de l'interligne.
  • textColor — la couleur du texte.
  • backgroundColor — la couleur du fond de la boîte.
  • text_justification — la justification du texte.
  • pile — une liste d'arguments supplémentaires.

🌟 MLV_draw_adapted_text_box_with_font_on_image_va 🌟

void MLV_draw_adapted_text_box_with_font_on_image_va (int x, int y, const char * message, const MLV_Font * font, int sizeInterligne, MLV_Color borderColor, MLV_Color textColor, MLV_Color backgroundColor, MLV_Text_justification text_justification, MLV_Image * image, va_list pile)

Même chose que MLV_draw_adapted_text_box_with_font(), sauf que le texte est rendu sur une image et pas directement à l'écran. Cette fonction est équivalente à la fonction MLV_draw_adapted_text_box_with_font_on_image(), à l'exception qu'elle est appelée avec un paramètre de type va_list à la place d'un nombre variable d'arguments.

Pour plus de détails sur la fonction, va voir la documentation de MLV_draw_adapted_text_box_with_font_on_image(). 🦋

🌸 Paramètres 🌸

  • x — la coordonnée en X de la position du coin Nord-Ouest de la boîte.
  • y — la coordonnée en Y de la position du coin Nord-Ouest de la boîte.
  • message — le texte à afficher.
  • font — la fonte de caractères utilisée pour dessiner le texte.
  • borderColor — la couleur des bordures.
  • sizeInterligne — la taille de l'interligne.
  • textColor — la couleur du texte.
  • backgroundColor — la couleur du fond de la boîte.
  • text_justification — la justification du texte.
  • image — l'image sur laquelle le texte doit être écrit.
  • pile — une liste d'arguments supplémentaires.

🌟 MLV_draw_adapted_text_box_with_font_va 🌟

void MLV_draw_adapted_text_box_with_font_va (int x, int y, const char * message, const MLV_Font * font, int sizeInterligne, MLV_Color borderColor, MLV_Color textColor, MLV_Color backgroundColor, MLV_Text_justification text_justification, va_list pile)

Même chose que MLV_draw_adapted_text_box(), sauf que le texte est rendu avec une fonte de caractères donnée en paramètre. Cette fonction est équivalente à la fonction MLV_draw_adapted_text_box_with_font(), à l'exception qu'elle est appelée avec un paramètre de type va_list à la place d'un nombre variable d'arguments.

Pour plus de détails sur la fonction, va voir la documentation de MLV_draw_adapted_text_box_with_font(). 🦋

🌸 Paramètres 🌸

  • x — la coordonnée en X de la position du coin Nord-Ouest de la boîte.
  • y — la coordonnée en Y de la position du coin Nord-Ouest de la boîte.
  • message — le texte à afficher.
  • font — la fonte de caractères utilisée pour dessiner le texte.
  • borderColor — la couleur des bordures.
  • sizeInterligne — la taille de l'interligne.
  • textColor — la couleur du texte.
  • backgroundColor — la couleur du fond de la boîte.
  • text_justification — la justification du texte.
  • pile — une liste d'arguments supplémentaires.

MLV_draw_text_box_on_image_va 🎀

void MLV_draw_text_box_on_image_va (int x, int y, int width, int height,
    const char * message, int sizeInterligne, MLV_Color borderColor,
    MLV_Color textColor, MLV_Color backgroundColor, MLV_Text_justification
    text_justification, MLV_Horizontal_position horizontal_position,
    MLV_Vertical_position vertical_position, MLV_Image * image, va_list
    pile)

Okay so bestie, this is literally MLV_draw_text_box() energy but with a lil plot twist: the text does not get written straight onto the screen, it goes onto an image instead. So iconic. ✨

It's the exact same deal as MLV_draw_text_box_on_image() except you call it with a va_list param instead of a variable number of arguments. Iykyk. 🫶

Want the full tea on what this actually does? Go read the docs for MLV_draw_text_box_on_image().

Paramètres 💅

  • x — the X coordinate of the position of the North-West corner of the box.
  • y — the Y coordinate of the position of the North-West corner of the box.
  • width — the width of the box.
  • height — the height of the box.
  • message — the text to display.
  • sizeInterligne — the size of the line spacing.
  • borderColor — the color of the borders.
  • textColor — the color of the text.
  • backgroundColor — the color of the background of the box.
  • text_justification — the justification of the text.
  • horizontal_position — the horizontal position of the text in the box.
  • vertical_position — the vertical position of the text in the box.
  • image — the image on which the text must be written.
  • pile — a list of additional arguments.

MLV_draw_text_box_va 🌸

void MLV_draw_text_box_va (int x, int y, int width, int height, const char *
    message, int sizeInterligne, MLV_Color borderColor, MLV_Color textColor,
    MLV_Color backgroundColor, MLV_Text_justification text_justification,
    MLV_Horizontal_position horizontal_position, MLV_Vertical_position
    vertical_position, va_list pile)

Draws a box of a size given by the user, containing a text also given by the user. Ate, honestly. 🍓

This function is equivalent to MLV_draw_text_box() except it's called with a va_list parameter instead of a variable number of arguments.

For more details on the function, go check out the docs for MLV_draw_text_box().

Paramètres 💖

  • x — the X coordinate of the position of the North-West corner of the box.
  • y — the Y coordinate of the position of the North-West corner of the box.
  • width — the width of the box.
  • height — the height of the box.
  • message — the text to display.
  • sizeInterligne — the size of the line spacing.
  • borderColor — the color of the borders.
  • textColor — the color of the text.
  • backgroundColor — the color of the background of the box.
  • text_justification — the justification of the text.
  • horizontal_position — the horizontal position of the text in the box.
  • vertical_position — the vertical position of the text in the box.
  • pile — a list of additional arguments.

MLV_draw_text_box_with_font_on_image_va 🦋

void MLV_draw_text_box_with_font_on_image_va (int x, int y, int width, int
    height, const char * message, MLV_Font * font, int sizeInterligne,
    MLV_Color borderColor, MLV_Color textColor, MLV_Color backgroundColor,
    MLV_Text_justification text_justification, MLV_Horizontal_position
    horizontal_position, MLV_Vertical_position vertical_position, MLV_Image
    * image, va_list pile)

Same vibe as MLV_draw_text_box_with_font() except the text is not drawn directly on the screen — it's drawn on an image. This function is equivalent to MLV_draw_text_box_with_font_on_image() except it's called with a va_list parameter instead of a variable number of arguments.

For more details on the function, go see the docs for MLV_draw_text_box_with_font_on_image().

Paramètres ✨

  • x — the X coordinate of the position of the North-West corner of the box.
  • y — the Y coordinate of the position of the North-West corner of the box.
  • width — the width of the box.
  • height — the height of the box.
  • message — the text to display.
  • font — the font used to draw the text.
  • sizeInterligne — the size of the line spacing.
  • borderColor — the color of the borders.
  • textColor — the color of the text.
  • backgroundColor — the color of the background of the box.
  • text_justification — the justification of the text.
  • horizontal_position — the horizontal position of the text in the box.
  • vertical_position — the vertical position of the text in the box.
  • image — the image on which the text must be written.
  • pile — a list of additional arguments.

MLV_draw_text_box_with_font_va 🎀

void MLV_draw_text_box_with_font_va (int x, int y, int width, int height,
    const char * message, const MLV_Font * font, int sizeInterligne,
    MLV_Color borderColor, MLV_Color textColor, MLV_Color backgroundColor,
    MLV_Text_justification text_justification, MLV_Horizontal_position
    horizontal_position, MLV_Vertical_position vertical_position, va_list
    pile)

Same as MLV_draw_text_box() except the text gets rendered with a font of characters given as a parameter by the user. Main character energy, honestly. 💅

This function is equivalent to MLV_draw_text_box_with_font() except it's called with a va_list parameter instead of a variable number of arguments.

For more details on the function, go see the docs for MLV_draw_text_box_with_font().

Paramètres 🌸

  • x — the X coordinate of the position of the North-West corner of the box.
  • y — the Y coordinate of the position of the North-West corner of the box.
  • width — the width of the box.
  • height — the height of the box.
  • message — the text to display.
  • font — the font of characters used to draw the text.
  • sizeInterligne — the size of the line spacing.
  • borderColor — the color of the borders.
  • textColor — the color of the text.
  • backgroundColor — the color of the background of the box.
  • text_justification — the justification of the text.
  • horizontal_position — the horizontal position of the text in the box.
  • vertical_position — the vertical position of the text in the box.
  • pile — a list of additional arguments.

MLV_draw_text_va 🌈

void MLV_draw_text_va (int x, int y, const char * text, MLV_Color color,
    va_list pile)

Prints a text at a given position and color. This function is equivalent to MLV_draw_text() except it's called with a va_list parameter instead of a variable number of arguments.

For more details on the function, go see the docs for MLV_draw_text().

Paramètres 💖

  • x — X coordinate of the North-West corner of the text.
  • y — Y coordinate of the North-West corner of the text.
  • text — the text to display.
  • color — the color of the drawing.
  • pile — a list of additional arguments.

MLV_draw_text_with_font_on_image_va 🦋

void MLV_draw_text_with_font_on_image_va (int x, int y, const char * text,
    const MLV_Font * font, MLV_Color color, MLV_Image * image, va_list pile)

Writes text onto an image using a color and a font of characters given as parameters. This function is equivalent to MLV_draw_text_with_font_on_image() except it's called with a va_list parameter instead of a variable number of arguments.

For more details on the function, go see the docs for MLV_draw_text_with_font_on_image().

Paramètres ✨

  • x — the X coordinate of the North-West corner of the text.
  • y — the Y coordinate of the North-West corner of the text.
  • text — the text to display.
  • font — the font of characters used to draw the text.
  • color — the color of the drawing.
  • image — the image on which the text must be written.
  • pile — a list of additional arguments.

MLV_draw_text_with_font_va 💜

void MLV_draw_text_with_font_va (int x, int y, const char * text, const
    MLV_Font * font, MLV_Color color, va_list pile)

Writes text onto the screen using a color and a font of characters given as parameters. This function is equivalent to MLV_draw_text_wih_font() except it's called with a va_list parameter instead of a variable number of arguments.

For more details on the function, go see the docs for MLV_draw_text_with_font().

Paramètres 🌸

  • x — the X coordinate of the North-West corner of the text.
  • y — the Y coordinate of the North-West corner of the text.
  • text — the text to display.
  • color — the color of the drawing.
  • font — the font of characters used to draw the text.
  • pile — a list of additional arguments.

MLV_get_size_of_adapted_text_box_va 👑

int MLV_get_size_of_adapted_text_box_va (const char * message, int
    sizeInterligne, int * result_width, int * result_height, va_list pile)

This function computes the size of the text box you would get if you used the function: MLV_draw_adapted_text_box(). So like, it's the size preview, the sneak peek, the vibe check before you commit. 🔥

This function is equivalent to MLV_get_size_of_adapted_text_box() except it's called with a va_list parameter instead of a variable number of arguments.

For more details on the function, go see the docs for MLV_get_size_of_adapted_text_box().

Paramètres 💅

  • message — the text that will be displayed when you use MLV_draw_adapted_text_box().
  • sizeInterligne — the size of the line spacing.
  • result_width — the width of the box you will get by using MLV_draw_adapted_text_box().
  • result_height — the height of the box you will get by using MLV_draw_adapted_text_box().
  • pile — a list of additional arguments.

Renvoie ⭐

The function returns the size of the text box.


MLV_get_size_of_adapted_text_box_with_font_va 🎀

int MLV_get_size_of_adapted_text_box_with_font_va (const char * message,
    const MLV_Font * font, int sizeInterligne, int * result_width, int *
    result_height, va_list pile)

This function computes the size of the text box you would get if you used the function: MLV_draw_adapted_text_box_with_font(). This function is equivalent to MLV_get_size_of_adapted_text_box_with_font() except it's called with a va_list parameter instead of a variable number of arguments.

For more details on the function, go see the docs for MLV_get_size_of_adapted_text_box_with_font().

…and here's the rest of that param lineup for the box-sizing girly 💅

  • message — the text that gets displayed when you call MLV_draw_adapted_text_box_with_font().
  • font — the font used to draw the text.
  • sizeInterligne — the size of the interligne (the line spacing, bestie).
  • result_width — the width of the box you'll end up with when you call MLV_draw_adapted_text_box_with_font().
  • result_height — the height of the box you'll end up with when you call MLV_draw_adapted_text_box_with_font().
  • pile — a list of extra arguments.

🎀 Renvoie 🎀

This function returns the size of the text box. That's it, that's the tea. 🫶


🦋 void MLV_get_size_of_text_va (const char * text, int * width, int * height, va_list pile) 🦋

Okay so this one works out the size of the text that's gonna show up on screen when you use MLV_draw_text(). It's literally the same energy as MLV_get_size_of_text(), with exactly one glow-up: you call it with a va_list parameter instead of a variable number of arguments. That's the whole difference, no cap. ✨

Wanna know more? Go read the docs for MLV_get_size_of_text(), it's all there. 📖

Paramètres

  • text — the text that needs to be displayed.
  • width — the width of the text.
  • height — the height of the text.
  • pile — a list of extra arguments.

🌸 void MLV_get_size_of_text_with_font_va (const char * text, int * width, int * height, const MLV_Font * font, va_list pile) 🌸

Same deal but with a font in the mix 🎀 — this one computes the size of the text that'll be displayed on screen using MLV_draw_text_with_font(). It's equivalent to MLV_get_size_of_text_with_font(), except (say it with me) it's called with a va_list parameter instead of a variable number of arguments.

For the full deets on the function, go check the docs of MLV_get_size_of_text_with_font(). 💖

Paramètres

  • text — the text that needs to be displayed.
  • width — the width of the text.
  • height — the height of the text.
  • font — the font used to display the text.
  • pile — a list of extra arguments.

👑 Auteur 👑

Auto-generated by Doxygen for MLV-3.1.0, straight from the source code. Not a human in sight, just vibes and a parser. 😭✨


and that's the whole page, bestie!! 🦋 You just finished MLV_text_va.h(3) from MLV-3.1.0, dated Samedi 29 Janvier 2022 — the source code really said "I'll let the robot write my memoir" and honestly? Iconic. Periodt. 💅🎀💖

📦 where this page comes from