From: "Damian Yerrick" Newsgroups: comp.os.msdos.djgpp Subject: Re: ASCII values in ALLEGRO Date: Tue, 31 Aug 1999 00:38:05 -0500 Organization: Rose-Hulman Institute of Technology Lines: 36 Message-ID: <7qfpq2$g84$1@solomon.cs.rose-hulman.edu> References: <37CAAFE5 DOT F6DFBD5 AT swipnet DOT se> <37CB4E6F DOT 525C AT ns DOT sympatico DOT ca> NNTP-Posting-Host: yerricde.laptop.rose-hulman.edu X-Trace: solomon.cs.rose-hulman.edu 936077954 16644 137.112.205.227 (31 Aug 1999 05:39:14 GMT) X-Complaints-To: news AT cs DOT rose-hulman DOT edu NNTP-Posting-Date: 31 Aug 1999 05:39:14 GMT X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 5.00.2314.1300 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2314.1300 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com My bum is on the swedish. Klaas wrote in message news:37CB4E6F DOT 525C AT ns DOT sympatico DOT ca... > Erik Ellingsson wrote: > > > > Hello! > > > > We are two swedish boys, we are currently working with a project using > > DJGPP and ALLEGRO. Because -we are swedish we want to use ASCII > > characters in the function textout( ); The characters are between the > > value 128-255. Is this possible using ALLEGRO? and if it is possible > > how are we going to do this? Do we have to alter the keyboard > > settings/file or something like that? > > 1. Set your font to include whatever characters you need. > 2. Use chars in the string to display those characters. > > For example: > Say I created a font with "ņ" in ANSI (not ASCII) #149. > > To display this in Allegro: > > textprintf(mybmp,myfont,myx,myy,mycolor,"oo%coo",149); /* this will > display "ooņoo" */ It's even simpler if you edit your programs in Notepad or any other Windows text editor, as opposed to RHIDE. It seems that the default font and any fonts created with TTF2PCX use the Windows (ANSI) character set rather than the DOS (OEM) character set for its ANSI characters. To say the lyrics to an annoying song, simply do this: textout(screen, font, "Dale a tu cuerpo alegrķa Macarena", 80, 100, 15); -Damian