I'm using Allegro 5.0.8 al_draw_text to draw text on a bitmap (backbuffer). However, I've noticed that the first character of the string is always skipped. Moreover, whenever the same character appears in the string, it is skipped again.
For example:
font = al_load_font(path.c_str(), 100, 0);
std::string str = "01230450678";
al_draw_text(font, color, 100, 100, 0, str.c_str());
Will print "12345678", skipping all occurrences of '0'
I've tried several TTF fonts, which work with other graphic software. I've noticed that this sometimes may or may not happen with the same font, depending only on the text size on screen (font size)
Edit: I've formatted the code and added the arguments I've used to load the font.
Edit2: Here is a complete code to replicate this using Allegro 5.0.8.
This code should print "0123045670890", but, instead, it renders the following image:
(Note: I didn't cleared the memory because the error appears before program finishes)

//---------------------------------------------------------------------------
#include <string>
#include <allegro5/allegro.h>
#include <allegro5/allegro_image.h>
#include <allegro5/allegro_opengl.h>
#include <allegro5/allegro_font.h>
#include <allegro5/allegro_ttf.h>
#include <allegro5/allegro_primitives.h>
//---------------------------------------------------------------------------
using namespace std;
//---------------------------------------------------------------------------
int main(int argc, char * argv[])
{
al_init();
al_install_keyboard();
al_init_image_addon();
al_init_primitives_addon();
al_init_font_addon();
al_init_ttf_addon();
al_set_new_display_flags(ALLEGRO_OPENGL);
ALLEGRO_DISPLAY * mainWindow= al_create_display(1200, 1000);
ALLEGRO_PATH *path = al_get_standard_path(ALLEGRO_RESOURCES_PATH);
string file = al_path_cstr(path, '/');
file = file + "arial.ttf";
ALLEGRO_FONT * font = al_load_font(file.c_str(), 50, 0);
al_set_target_bitmap(al_get_backbuffer(mainWindow));
al_draw_filled_rectangle(0, 0, 1200, 1000, al_map_rgb(0,0,0));
al_draw_text(font, al_map_rgb(255,0,0), 50, 50, 0, "0123045670890");
al_save_bitmap("d:\\teste.bmp", al_get_backbuffer(mainWindow));
al_flip_display();
al_rest(5.0);
return 0;
}

al_set_new_bitmap_flags(ALLEGRO_MEMORY_BITMAP)before loading the font. – Matthew Jan 8 at 18:01