> I think your attitude is not very constructive. We have to keep this > idea as simple as possible or nobody implements it.
I think some of that is important, even if you only want to implement a simple translation. Besides, of course it isn't very constructive to *discuss* an idea. Go use DOSLFN's source (free/PD) and implement an interface if you want to be constructive, should be enough pointers here by now. > I think it is not needed to make tables UNICODE to ASCII. > It is sufficient to make ASCII to UNICODE. Please be specific, I think what you are saying is not what you mean. I assume that when you say "ASCII" you mean "current code page" because ASCII to Unicode (and the reverse) translation doesn't require any table at all. Strictly, the ASCII contains a set of 128 codes - these all have the same numeric value as the associated Unicode code-points. You might be proposing that the implementation should be, as Bret put it, "accurate" - ie it should only map exact matches, ignoring "pairs of characters that look similar enough" (Bret's "useful"). The literal sense of your words is that the implementation should be unable (!) to look up what a particular Unicode code-point should be mapped to in the current code page (only accurate matches). This is undesirable as it would unnecessarily hinder many applications. > Simple table - on one side 256 bytes - on second side 256 words. > That is all. You actually need only 128 words for what you have in mind - the lower 128 word table entries can be dropped, because the ASCII characters/bytes always map directly to Unicode code-points. The byte table (containing the associated byte in the current code page) can be dropped entirely, because its contents will just count upward. (That table format matches what DOSLFN uses for simple (256-character) code pages. DBCS mapping needs to be a lot more complicated. Though you might not care, I suggest one consult DOSLFN's source if one is interested in DBCS mapping.) As I mentioned, with a table consisting of (16-bit) words for the Unicode side you cannot map all Unicode code-points. Granted, this is not very important in practice. Regards, Christian ------------------------------------------------------------------------------ Increase Visibility of Your 3D Game App & Earn a Chance To Win $500! Tap into the largest installed PC base & get more eyes on your game by optimizing for Intel(R) Graphics Technology. Get started today with the Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs. http://p.sf.net/sfu/intelisp-dev2dev _______________________________________________ Freedos-devel mailing list Freedos-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/freedos-devel