]>
Commit | Line | Data |
---|---|---|
eb0ac1ae AG |
1 | To: vim-dev@vim.org |
2 | Subject: Patch 6.2.136 | |
3 | Fcc: outbox | |
4 | From: Bram Moolenaar <Bram@moolenaar.net> | |
5 | Mime-Version: 1.0 | |
6 | Content-Type: text/plain; charset=ISO-8859-1 | |
7 | Content-Transfer-Encoding: 8bit | |
8 | ------------ | |
9 | ||
10 | Patch 6.2.136 | |
11 | Problem: ":e ++enc=latin1 newfile" doesn't set 'fenc' when the file doesn't | |
12 | exist. (Miroslaw Dobrzanski-Neumann) | |
13 | Solution: Set 'fileencoding' to the specified encoding when editing a file | |
14 | that does not exist. | |
15 | Files: src/fileio.c | |
16 | ||
17 | ||
18 | *** ../vim-6.2.135/src/fileio.c Sun Oct 12 17:25:14 2003 | |
19 | --- src/fileio.c Tue Oct 28 20:52:40 2003 | |
20 | *************** | |
21 | *** 543,548 **** | |
22 | --- 543,559 ---- | |
23 | * edited before and deleted. Get the old marks. */ | |
24 | check_marks_read(); | |
25 | #endif | |
26 | + #ifdef FEAT_MBYTE | |
27 | + if (eap != NULL && eap->force_enc != 0) | |
28 | + { | |
29 | + /* set forced 'fileencoding' */ | |
30 | + fenc = enc_canonize(eap->cmd + eap->force_enc); | |
31 | + if (fenc != NULL) | |
32 | + set_string_option_direct((char_u *)"fenc", -1, | |
33 | + fenc, OPT_FREE|OPT_LOCAL); | |
34 | + vim_free(fenc); | |
35 | + } | |
36 | + #endif | |
37 | #ifdef FEAT_AUTOCMD | |
38 | apply_autocmds_exarg(EVENT_BUFNEWFILE, sfname, sfname, | |
39 | FALSE, curbuf, eap); | |
40 | *** ../vim-6.2.135/src/version.c Sun Oct 26 20:12:53 2003 | |
41 | --- src/version.c Wed Oct 29 14:27:36 2003 | |
42 | *************** | |
43 | *** 639,640 **** | |
44 | --- 639,642 ---- | |
45 | { /* Add new patch number below this line */ | |
46 | + /**/ | |
47 | + 136, | |
48 | /**/ | |
49 | ||
50 | -- | |
51 | Vi beats Emacs to death, and then again! | |
52 | http://linuxtoday.com/stories/5764.html | |
53 | ||
54 | /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ | |
55 | /// Creator of Vim - Vi IMproved -- http://www.Vim.org \\\ | |
56 | \\\ Project leader for A-A-P -- http://www.A-A-P.org /// | |
57 | \\\ Help AIDS victims, buy here: http://ICCF-Holland.org/click1.html /// |