fhackenberger / ktikz

KtikZ provides a nice user interface for making pictures using TikZ.
Other
350 stars 34 forks source link

Support UTF-8 (or non-local) encoding for PGF-files. #6

Closed gprud closed 7 years ago

gprud commented 7 years ago

Hey,

I use (a lot) TikZ and ktikz. However, I cannot use (French) accents inside my draws because documents are exported with a different encoding than the one defined in the root TeX file (through inputenc package).

So, I have made some additions inside the load/save procedures. The standard behavior is to use the local decoder, or UTF-8 if the BOM is detected. Then, the same coder is used to write the file (adding a BOM if Unicode). This should be OK for most of the users.

For specific uses, the decoder or/and encoder can be overridden. So, options have been added inside “editor” tabs.

fhackenberger commented 7 years ago

Hi! Thanks for the patch! I've looked through it briefly. I'd like to merge it. There's only one minor thing that I'd like to ask you to fix, before I merge: Could you please fix your indentation to match the rest of the existing source code? Thanks, Florian

gprud commented 7 years ago

Hi Florian, Thank you for your answer. I have not noticed that my IDE uses spaces as default. This should be ok now.

fhackenberger commented 7 years ago

Thanks for the changes! I'll merge this now!

gprud commented 7 years ago

Great :)