On Wed, Jun 02, 2004 at 10:30:37PM -0400, Brad Sawatzky wrote: > Hello all, > > A patch implementing a Rot13 decoder off the Export form is attached. I > find this very useful for decoding the 'hints' from a plucked geocache page > off www.geocaching.com. I think it a fairly unobtrusive addition, but If > it is too special-purpose I could wrap some ifdefs around it and implement > a configure option upon request. > > The patch is against the recent plucker_src-1.8.tar.bz2 source. > > Potential caveat: > I am not clear on how this will interact with unicode text (see the inline > comment for my musings). AFAICT, the Char type looked like it was at least > guaranteed to be 8 bit/character, but I don't know how to tell if it is > ascii, UTF-8, or some other 8-bit map for with Rot13 doesn't apply. > > Can someone who understands this better summarize how this might be handled > in a unicode friendly manner?
export does not handle unicode characters well (they are mojibaked anyway). I plan to look at this some time. Except of this little detail :-), your patch is ok since it skips 8-bit characters, UTF-8 is guaranteed to be ascii-safe. Where it might cause problems are various multibyte encodings that are not ASCII-safe. I am not quite sure what are the Japanese devices using, but I thinks Shift-JIS, and this encoding is not ASCII safe and the text will be messed up with your patch. But Japanese text cannot be ROT-13ed anyway, therefore I do not think it matters much. -- ----------------------------------------------------------- | Radovan Garab�k http://melkor.dnp.fmph.uniba.sk/~garabik/ | | __..--^^^--..__ garabik @ melkor.dnp.fmph.uniba.sk | ----------------------------------------------------------- Antivirus alert: file .signature infected by signature virus. Hi! I'm a signature virus! Copy me into your signature file to help me spread! _______________________________________________ plucker-dev mailing list [EMAIL PROTECTED] http://lists.rubberchicken.org/mailman/listinfo/plucker-dev
