logo separator

[mkgmap-dev] how to use utf-8 in stderr output

From GerdP gpetermann_muenchen at hotmail.com on Wed Jan 14 19:55:06 GMT 2015

Hi Walter,

reg. logging.properties:
This feature allows to enable detailed logging to a separate file.
A sample is contained in the source:
mkgmap\resources\logging.properties 

Another sample see http://wiki.openstreetmap.org/wiki/Mkgmap/dev

I am not sure if stderr/stdout can be configured.

Gerd


Walter Schlögl wrote
> Hi Steve and Gerd,
> 
> yes, you got me right. I was talking about stderr output where echo
> messages are printed.
> 
> I have tried the following (under Windows):
> 
> %JavaPath% -Xmx6144m -ea -jar
> -Dlog.config=%OptionsPath%\logging_properties.txt  
> %ToolPath%\mkgmap\mkgmap.jar  -c %OptionsPath%\%mkgmap_options%  
> --mapname=%mapid%  --overview-mapname=%overview_mapname%  
> --family-id=%family_id%  --product-id=%product_id%  
> --gmapsupp %mkgmap_filename%  
> %StylesPath%\%StylesFile%  2>>%LogfileName%
> 
> content of logging_properties.txt is:
> 
> java.util.logging.FileHandler.encoding=UTF-8
> java.util.logging.ConsoleHandler.encoding=UTF-8
> 
> I am still getting outputs of echo "name='${name}'” as: ‘??????? ??????’
> if the char set is not part of 1252 (e.g. for greek letters)
> 
> I think I did not fully understand your hint with the logging properties.
> 
> Walter
> 
> 
> From: Gerd Petermann 
> Sent: Wednesday, January 14, 2015 11:03 AM
> To: 

> mkgmap-dev at .org

>  
> Subject: Re: [mkgmap-dev] Solution to show transliterated name if no other
> ascii name exists
> 
> Hi Walter,
> 
> reg. UTF8 in logs:
> When I read your post my first question was: Is he talking about the log
> that is written to stderr/stdout or the one that is enabled with
> java -Dlog.config ... -jar mkgmap.jar ...
> 
> I think the latter works fine, the first two look ugly when they write to
> a 
> windows console. They also look fine when you pipe them to files
> like this
> java -Dlog.config ... -jar mkgmap.jar ...  > mkgmap.stdout 2>mkgmap.stderr
> 
> Gerd
> 
> 
>> Date: Wed, 14 Jan 2015 09:15:50 +0000
>> From: 

> steve at .me

>> To: 

> mkgmap-dev at .org

>> Subject: Re: [mkgmap-dev] Solution to show transliterated name if no
>> other ascii name exists
>> 
>> Hi Walter,
>> 
>> It's great to hear that it is working well for you. It was just a few
>> lines of code, perhaps no one asked before because they imagined it
>> would be more difficult.
>> 
>> 
>> > Do you know, if the logfile can only be written in ANSI coding,
>> > or if there is a way to use unicode for logfiles?
>> 
>> I don't know for sure, but make sure you have this included in
>> your log.config file.
>> java.util.logging.FileHandler.encoding=UTF-8
>> 
>> and try adding this too:
>> java.util.logging.ConsoleHandler.encoding=UTF-8
>> 
>> ..Steve
>> _______________________________________________
>> mkgmap-dev mailing list
>> 

> mkgmap-dev at .org

>> http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
> 
> 
> 
> --------------------------------------------------------------------------------
> _______________________________________________
> mkgmap-dev mailing list

> mkgmap-dev at .org

> http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
> _______________________________________________
> mkgmap-dev mailing list

> mkgmap-dev at .org

> http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev





--
View this message in context: http://gis.19327.n5.nabble.com/elevation-data-tp5828381p5830037.html
Sent from the Mkgmap Development mailing list archive at Nabble.com.


More information about the mkgmap-dev mailing list