On Mon, June 21, 2010 10:19, Noel and Marie wrote:
Hello, > Recently SP3 for XP was installed on my PC. > > An fpc 2.2.0 program that previously displayed a square root symbol when > instructed to write chr(251) now displays a superscript 1. In other words, > the character set displayed in the IDE through Tools ->ascii table is > different from the one previously displayed. > > Can you give instructions on how to have the program use the former > character set please? There are several options for you: 1) Change the console code page to the preferred character set before starting the program (e.g. by calling 'cp 437' on the command line or from a batch file before invoking your program). Advantage: No change to the program is required. Disadvantage: Change necessary on each and every machine where the program runs. 2) Change the console code page to the preferred character set using the Win32 API from within the program. Advantage: No user changes necessary. Disadvantage: Platform dependent change (if you aim to support multiple platforms), no chance for the user to use a different character set (i.e. no possibility of displaying characters used in other languages any longer). 3) Start using widestrings / Unicode characters. Advantage: Your programs becomes completely independent from the used character set and allows reliable displaying of whichever characters you may need (as long as they are supported by the installed fonts, of course). Disadvantage: Depending on the way your program is currently written / output to console is performed, major changes to your program may be necessary. Hope this helps Tomas _______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal