logo separator

[mkgmap-dev] More Dog patches

From Marko Mäkelä marko.makela at iki.fi on Tue Nov 17 12:16:36 GMT 2009

Hi Bennie,

On Tue, Nov 17, 2009 at 12:15:55PM +0200, Du Plessis, Bennie wrote:
> Hi Marko,
> 
> >I had a look at your patch.  
> 
> Thanks for taking the time
> 
> >I think that the character encoding should
> >be ASCII or UTF-8.  The apparent encoding of your patch is Microsoft
> >Code Page 1252.>
> 
> Ahh, that won't do- I want to help improve mkgmap, not hamper it!
> I'll try to find out what that means and will refrain from patching till
> then.

The text you added contains some characters that are not in ASCII (7-bit).
They were not encoded in UTF-8, even though UTF-8 is the standard encoding
of OpenStreetMap.  (OSM is based on XML, whose default encoding is UTF-8,
as far as I understand.)

In this case, the fix is simple: use ASCII apostrophes (') instead of
curly quotes and spell Windows correctly.  I think that it is better to
have the English plain text documentation in ASCII, because ASCII is a
proper subset of most character encodings, and some people could still
be using system configurations that do not display UTF-8.

> How can you tell which character encoding is used?

Educated guess verified with GNU Recode.  I viewed the patch in a program
that is configured to expect UTF-8.  It displayed the non-ASCII characters
in hexadecimal notation, because they were not valid UTF-8.

> Hang on - I've tried to get a diff from comparing two paths on svn, but
> it didn't work: all I get is a diff like output on screen (which is fine
> to read, but does not save / download as a diff file with the + - @ etc
> - how do you get a diff file from it? I've tried to copy & paste but all
> the diff symbols has to be added manualy then - I'm guaranteed to make a
> typo.

How about redirecting the output of the command to a file:

svn diff > some_descriptive_name.patch

With best regards,

	Marko



More information about the mkgmap-dev mailing list