transpose_font(3alleg4)

transpose_font3alleg4

Transposes all characters in a font. allegro game programming library.

Usage

#include <allegro.h>

int transpose_font(FONT *f, int drange)

Overview

This function transposes all characters in a font, effectively remapping the font. Example:

   FONT *myfont;
   FONT *capitals;
   ...
   /* Create a font of only capital letters */
   capitals = extract_font_range(myfont, 'A', 'Z');
   /* Now transpose the characters in the font so that they will be used */
   /*  for the lower case letters a-z */
   transpose_font(capitals, 'a'-'A');
   textout_ex(screen, capitals, "allcaps",
              100, 100, makecol(255,255,255), 0);

Return value

Returns 0 on success, -1 on failure.

Releases

7 releases since Debian 7 (Wheezy); the text changed 1 time.

  1. 7–10
  2. 11–13

From allegro4-doc 2:4.4.3.1-5 in Debian 13 (Trixie). Parsed by carta from the page's man source.