[cairo] please help

Eric Feillant eric.feillant at live-media.fr
Wed Jan 5 11:48:25 UTC 2022


hi,

I'm sorry to ask you that directly by email but i did not find any 
solution elsewhere ...
I'm a poor programmer and try to display one text in a PNG image using 
CAIRO.

My problem here is that in the "for" loop, cairo display only one colum 
and not the entire string, ex: 3 2 1
my small code:
                 char  sets2 [100] ;
                 for (size_t i=0; i < match->nb_set; i++)
                 {
                 char  chaine  = joueur->sets[i] ;
                 sprintf(sets2 , "%d", chaine);
                 printf("%s ", sets2);  // This print 3 2 1
                 cairo_move_to(cr, 250, 120);
                 cairo_show_text(cr, sets2); // this display in the 
image one colum the overlayed number
                 }

Is this my for loop or cairo displaying like this ?
Really thank you in advance if you can help,
Eric
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.cairographics.org/archives/cairo/attachments/20220105/f5615e6e/attachment.htm>


More information about the cairo mailing list