static void Draw_Line(TTF_Font *font, const SDL_Surface *textbuf, int row, int line_width, int line_thickness, Uint32 color, const render_mode_t render_mode)
{
    int tmp    = row + line_thickness - textbuf->h;
    Uint8 *dst = (Uint8 *)textbuf->pixels + row * textbuf->pitch;

#if TTF_USE_HARFBUZZ
    /* No Underline/Strikethrough style if direction is vertical */
    if (font->hb_direction == HB_DIRECTION_TTB || font->hb_direction == HB_DIRECTION_BTT) {
        return;
    }
#endif

    /* Not needed because of "font->height = SDL_max(font->height, bottom_row);".
     * But if you patch to render textshaping and break line in middle of a cluster,
     * (which is a bad usage and a corner case), you need this to prevent out of bounds.
     * You can get an "ystart" for the "whole line", which is different (and smaller)
     * than the ones of the "splitted lines". */
    if (tmp > 0) {
        line_thickness -= tmp;
    }

    /* Wrapped mode with an unbroken line: 'line_width' is greater that 'textbuf->w' */
    line_width = SDL_min(line_width, textbuf->w);

    if (render_mode == RENDER_BLENDED) {
        while (line_thickness--) {
            SDL_memset4(dst, color, line_width);
            dst += textbuf->pitch;
        }
    } else {
        while (line_thickness--) {
            SDL_memset(dst, color, line_width);
            dst += textbuf->pitch;
        }
    }
}
static void Draw_Line(TTF_Font *font, const SDL_Surface *textbuf, int row, int line_width, int line_thickness, Uint32 color, const render_mode_t render_mode)
{
    int tmp    = row + line_thickness - textbuf->h;
    Uint8 *dst = (Uint8 *)textbuf->pixels + row * textbuf->pitch;

#if TTF_USE_HARFBUZZ
     
    if (font->hb_direction == HB_DIRECTION_TTB || font->hb_direction == HB_DIRECTION_BTT) {
        return;
    }
#endif

     
    if (tmp > 0) {
        line_thickness -= tmp;
    }

     
    line_width = SDL_min(line_width, textbuf->w);

    if (render_mode == RENDER_BLENDED) {
        while (line_thickness--) {
            SDL_memset4(dst, color, line_width);
            dst += textbuf->pitch;
        }
    } else {
        while (line_thickness--) {
            SDL_memset(dst, color, line_width);
            dst += textbuf->pitch;
        }
    }
}