Re: Suggest ':TOhtml' to use 'fileencoding' rather than 'encoding' as default html charset

2010-09-11 Fir de Conversatie Ben Fritz
On Sep 10, 10:22 pm, Benjamin Fritz fritzophre...@gmail.com wrote: Unfortunately, I could not find a list of widely supported charsets, so I just used all the ones in Vim and the IANA registry, as mentioned previously. If there is such a list, would it be a good idea to limit the

Re: Suggest ':TOhtml' to use 'fileencoding' rather than 'encoding' as default html charset

2010-09-10 Fir de Conversatie Benjamin Fritz
The attached patch against the latest 7.3.3 changeset in Mercurial adds the requested use of 'fencoding' instead of 'encoding' when it is set to determine the HTML charset. Additionally, it will now support a lot more encodings, and automatically set the file encoding of the new file to match the

Re: Suggest ':TOhtml' to use 'fileencoding' rather than 'encoding' as default html charset

2010-08-29 Fir de Conversatie Benjamin Fritz
On Sat, Aug 28, 2010 at 10:00 PM, Tony Mechelynck antoine.mechely...@gmail.com wrote: I don't know what is being done ATM, but I'd always include the line meta http-equiv=Content-Type content=text/html; charset=whatever / (replacing whatever by the charset name) somewhere near the start of

Re: Suggest ':TOhtml' to use 'fileencoding' rather than 'encoding' as default html charset

2010-08-29 Fir de Conversatie JiaYanwei
Sorry, it's my omission, I had set 'fileencoding' in '.vimrc'... ps: Excuse me to get this message so late. I cannot visit google group last few days. On 2010-8-28, 03:37 Ben Fritz fritzophre...@gmail.com wrote: On Aug 25, 11:11 pm, JiaYanwei jia...@126.com wrote: e.g. If the system/vim

Re: Suggest ':TOhtml' to use 'fileencoding' rather than 'encoding' as default html charset

2010-08-28 Fir de Conversatie Tony Mechelynck
On 26/08/10 16:40, Ben Fritz wrote: On Aug 25, 11:11 pm, JiaYanweijia...@126.com wrote: I think this will be more reasonable than before. If the encoding of edited text file differ form the system/vim encoding, it's inconvenient to set default HTML charset to be 'encoding'. Thus, after

Re: Suggest ':TOhtml' to use 'fileencoding' rather than 'encoding' as default html charset

2010-08-28 Fir de Conversatie Benjamin Fritz
On Sat, Aug 28, 2010 at 4:16 PM, Tony Mechelynck antoine.mechely...@gmail.com wrote: From my understanding, 'fileencoding' is the encoding Vim is supposed to use to read/write the file. So, it does make sense that we should use this instead of just 'encoding' for the charset of the generated

Re: Suggest ':TOhtml' to use 'fileencoding' rather than 'encoding' as default html charset

2010-08-28 Fir de Conversatie Tony Mechelynck
On 29/08/10 04:29, Benjamin Fritz wrote: On Sat, Aug 28, 2010 at 4:16 PM, Tony Mechelynck antoine.mechely...@gmail.com wrote: From my understanding, 'fileencoding' is the encoding Vim is supposed to use to read/write the file. So, it does make sense that we should use this instead of just

Re: Suggest ':TOhtml' to use 'fileencoding' rather than 'encoding' as default html charset

2010-08-27 Fir de Conversatie Ben Fritz
On Aug 25, 11:11 pm, JiaYanwei jia...@126.com wrote: e.g. If the system/vim encoding is 'UTF-8', but a text file encoding is 'latin-1'. If the default HTML charset is 'encoding', after ':TOhtml', we should change the HTML charset to 'iso-8859-1', or save the generated HTML file by ':w

Re: Suggest ':TOhtml' to use 'fileencoding' rather than 'encoding' as default html charset

2010-08-26 Fir de Conversatie Ben Fritz
On Aug 25, 11:11 pm, JiaYanwei jia...@126.com wrote: I think this will be more reasonable than before. If the encoding of edited text file differ form the system/vim encoding, it's inconvenient to set default HTML charset to be 'encoding'. Thus, after ':TOhtml', we should modify the

Re: Suggest ':TOhtml' to use 'fileencoding' rather than 'encoding' as default html charset

2010-08-26 Fir de Conversatie Ben Fritz
On Aug 26, 9:40 am, Ben Fritz fritzophre...@gmail.com wrote: From my understanding, 'fileencoding' is the encoding Vim is supposed to use to read/write the file. So, it does make sense that we should use this instead of just 'encoding' for the charset of the generated html. Does anyone know

Re: Suggest ':TOhtml' to use 'fileencoding' rather than 'encoding' as default html charset

2010-08-26 Fir de Conversatie JiaYanwei
Oh, sorry, I forgeted that 'fileencoding' may be empty. This should be handled. I encountered the opposite that 'fileencoding' is often different from 'encoding' while editing existing files. Ben Fritz wrote: On Aug 26, 9:40 am, Ben Fritz fritzophre...@gmail.com wrote: From my

Suggest ':TOhtml' to use 'fileencoding' rather than 'encoding' as default html charset

2010-08-25 Fir de Conversatie JiaYanwei
I think this will be more reasonable than before. If the encoding of edited text file differ form the system/vim encoding, it's inconvenient to set default HTML charset to be 'encoding'. Thus, after ':TOhtml', we should modify the generated HTML file to make the file encoding the same as HTML