ChangeLog 30 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983
  1. 2002-12-08 Pavel Roskin <proski@gnu.org>
  2. * edit.c (edit_open_file): Remove "text" and "text_size"
  3. arguments. Adjust all callers.
  4. * edit.c (edit_move_to_column): Remove, use
  5. edit_move_to_prev_col() instead.
  6. * edit.c: Commit the rest of the position saving code.
  7. (edit_load_position): New function, load position.
  8. (edit_save_position): New function, save position.
  9. (edit_init): Take new argument "line". If it's 0, load position
  10. from .mc/filepos.
  11. (edit_clean): Save file position to .mc/filepos even if the file
  12. is not being saved.
  13. * editwidget.c (edit): Don't set the initial line, pass it to
  14. edit_init().
  15. 2002-12-07 Pavel Roskin <proski@gnu.org>
  16. * syntax.c (edit_load_syntax): Reuse more informative error
  17. message.
  18. * edit.c (check_file_access): Use O_EXCL when opening new files.
  19. Don't allow editing stale symlinks.
  20. Reported by Max Derzhak <max@linux.zp.ua>
  21. 2002-12-05 Pavel Roskin <proski@gnu.org>
  22. * edit-widget.h: Remove "from_here" and "to_here".
  23. * edit.c (edit_purge_widget): New function - clean struct WEdit
  24. except the Widget part.
  25. 2002-12-04 Pavel Roskin <proski@gnu.org>
  26. * editcmd.c: Include dialog.h.
  27. Reported by Frédéric L. W. Meunier <lists@pervalidus.net>
  28. 2002-11-30 Pavel Roskin <proski@gnu.org>
  29. * edit.h: Remove "dir" field in WEdit - it's always an empty
  30. string. Adjust all dependencies.
  31. * editcmd.c (edit_get_save_file): Remove first argument, it's
  32. unused.
  33. (edit_get_save_file): Likewise.
  34. * syntax.c: Make structures key_word, context_rule and
  35. _syntax_marker opaque.
  36. * edit.c: Use g_malloc() and g_free() on buffers1 and buffers2.
  37. Eliminate CMalloc.
  38. (edit_get_buffer_as_text): Remove, it's unused.
  39. * editcmd.c (edit_set_search_parameters): Use g_malloc().
  40. (edit_complete_word_cmd): Use g_free().
  41. 2002-11-29 Pavel Roskin <proski@gnu.org>
  42. * edit.h: Don't define HAVE_SYNTAXH.
  43. * syntax.c: Syntax highlighting is no more optional.
  44. (edit_check_spelling): Remove.
  45. * editoptions.c (edit_options_dialog): Add "Save file position"
  46. option, make "Syntax highlighting" unconditional.
  47. * edit.c: First part of the position saving code.
  48. (edit_move_to_column): New function.
  49. 2002-11-29 Andrew V. Samoilov <sav@bcs.zp.ua>
  50. * editoptions.c (edit_options_dialog): Use g_free() to release
  51. variables allocated in quick_dialog().
  52. 2002-11-28 Pavel Roskin <proski@gnu.org>
  53. * edit-widget.h: Move typedef WEdit and file names ...
  54. * edit.h: ... here. Don't include edit-widget.h. Adjust all
  55. dependencies.
  56. 2002-11-23 Andrew V. Samoilov <sav@bcs.zp.ua>
  57. * editoptions.c (edit_options_dialog): Clean up and use g_snprintf()
  58. instead of sprintf().
  59. 2002-11-14 Pavel Roskin <proski@gnu.org>
  60. * edit.h: Decentralize includes.
  61. * editmenu.c (edit_user_menu_cmd): Move to ../src/cmd.c.
  62. * edit.c (edit_delete_line): Don't remove and restore the
  63. preceding newline. Don't treat binary zero as newline.
  64. From Dmitry Semyonov <Dmitry.Semyonov@oktet.ru>
  65. 2002-11-12 Pavel Roskin <proski@gnu.org>
  66. * *.c: Fix all global functions without declarations - declare,
  67. make static or remove.
  68. * syntax.c (syntax_change_callback): Remove, it's unused.
  69. (edit_set_syntax_change_callback): Likewise.
  70. * edit.c (edit_execute_cmd): Fool gcc to prevent Y2K warning.
  71. * editwidget.c (edit_adjust_size): Use find_buttonbar().
  72. 2002-11-11 Pavel Roskin <proski@gnu.org>
  73. * editcmd.c: Warning fix for compilers that don't understand the
  74. "const" keyword and variable size arrays.
  75. 2002-11-06 Pavel Roskin <proski@gnu.org>
  76. * editcmd.c (edit_save_file): Restore ownership before access
  77. mode, not after. Otherwise suid bit is lost.
  78. Reported by Nerijus Baliunas <nerijus@users.sourceforge.net>
  79. 2002-10-30 Pavel Roskin <proski@gnu.org>
  80. * edit.c: Include charset.h unconditionally, use new conversion
  81. functions that don't require ifdefs.
  82. * edit_key_translator.c: Likewise.
  83. * editcmd.c: Likewise.
  84. * editdraw.c: Likewise.
  85. 2002-10-20 Pavel Roskin <proski@gnu.org>
  86. * edit-widget.h: Add new field macro_depth to control depth of
  87. macro recursion.
  88. * edit.c (edit_execute_macro): Make static. Increment
  89. macro_depth on entry, decrement on exit, don't allow it to be
  90. too large.
  91. * wordproc.c (line_start): Remove incorrect optimization abusing
  92. static variables. Internal formatting should be usable now.
  93. 2002-10-18 Pavel Roskin <proski@gnu.org>
  94. * wordproc.c (begin_paragraph): Fix the same off-by-one error as
  95. in end_paragraph() - it affects formatting of the paragraph
  96. after the first line in the file it that line starts with a dot.
  97. Remove unused argument.
  98. * wordproc.c (end_paragraph): The last line of the file wasn't
  99. tested for being blank, which resulted in the last newline
  100. becoming a space after formatting.
  101. 2002-10-17 Pavel Roskin <proski@gnu.org>
  102. * editoptions.c (edit_options_dialog): Don't allow
  103. option_tab_spacing to be 0. Reset invalid values to 8.
  104. Reported by Ury N. Stankevich <ury@bofh.homeunix.org>
  105. 2002-10-08 Pavel Roskin <proski@gnu.org>
  106. * wordproc.c (format_paragraph): If formatting was successful,
  107. scroll to the left to show the formatted paragraph.
  108. 2002-10-06 Pavel Roskin <proski@gnu.org>
  109. * editdraw.c (print_to_widget): Eliminate use of floating point.
  110. Change all callers.
  111. 2002-10-02 Andrew V. Samoilov <sav@bcs.zp.ua>
  112. * editcmd.c (edit_insert_column_of_text): Fix infinite loop if
  113. block of text is copied past the end of the buffer.
  114. By Paul Sheer <psheer@icon.co.za>.
  115. (stacked): Don't initialize static arrays by zeros.
  116. 2002-09-26 Andrew V. Samoilov <sav@bcs.zp.ua>
  117. * edit.h (struct key_word): Remove time field.
  118. * syntax.c: Remove MAD support.
  119. 2002-09-24 Pavel Roskin <proski@gnu.org>
  120. * editwidget.c (edit): Make edit_dlg local variable.
  121. * editmenu.c (edit_drop_menu_cmd): Don't use edit_dlg variable.
  122. * edit.c: Remove all references to CR_LF_TRANSLATION.
  123. * editcmd.c: Likewise.
  124. 2002-09-23 Pavel Roskin <proski@gnu.org>
  125. * editwidget.c (edit): Install handler for DLG_RESIZE.
  126. * editwidget.c (edit): Set edit_dlg to NULL after it's
  127. destroyed.
  128. * edit.h: Move style definitions ...
  129. * editdraw.c: ... here. Multiply them by 256. Remove unused
  130. styles.
  131. (print_to_widget): Don't divide style by 256. Simplify logic
  132. since we only have 4 styles now.
  133. * edit.c (edit_move_forward3): Use caret notation for code 127
  134. and below code 32.
  135. * editdraw.c (edit_draw_this_line): Likewise. Print '.' for
  136. other non-printable characters and remove this code from ...
  137. (print_to_widget): ... here.
  138. * edit.c (edit_move_forward3): Show '\r' as ^M.
  139. * editdraw.c (edit_draw_this_line): Likewise. Use MOD_ABNORMAL
  140. attribute.
  141. From Alexander Varakin <avarakin00@hotmail.com>
  142. * edit.h: Remove all references to O_TEXT, USE_O_TEXT and
  143. MY_O_TEXT.
  144. * edit.c: Use O_BINARY when opening files.
  145. * editcmd.c: Likewise.
  146. From Alexander Varakin <avarakin00@hotmail.com>
  147. 2002-09-20 Pavel Roskin <proski@gnu.org>
  148. * editwidget.c (edit_event): Add support for mouse wheel events.
  149. * edit.h: Add missing declarations for edit_move_up() and
  150. edit_move_down().
  151. 2002-09-20 Andrew V. Samoilov <sav@bcs.zp.ua>
  152. * edit.c: Don't initialize static selection and selection_history.
  153. * editdraw.c (status_string): Remove font_width argument.
  154. (edit_status): Fix calculation to use last column in the
  155. status string.
  156. 2002-09-04 Pavel Roskin <proski@gnu.org>
  157. * edit.c (edit_filters): Use gzip, not compress for *.Z files
  158. for consistency with other parts of the code (viewer, mc.ext).
  159. 2002-09-03 Pavel Roskin <proski@gnu.org>
  160. * editcmd.c: Recheck and fix all calls to create_dlg().
  161. * editwidget.c: Likewise.
  162. 2002-09-02 Pavel Roskin <proski@gnu.org>
  163. * editcmd.c (edit_raw_key_query): Eliminate
  164. x_set_dialog_title().
  165. 2002-09-01 Pavel Roskin <proski@gnu.org>
  166. * editcmd.c (edit_block_process_cmd): Restore third argument
  167. (but make it /dev/null) for compatibility with old scripts.
  168. Reported by Andrew V. Samoilov <sav@bcs.zp.ua>
  169. 2002-08-31 Pavel Roskin <proski@gnu.org>
  170. * editwidget.c (edit): Avoid passing an uninitialized color
  171. array to create_dlg() - pass NULL instead.
  172. 2002-08-27 Andrew V. Samoilov <sav@bcs.zp.ua>
  173. * editcmd.c (edit_printf): Use g_vsnprintf() instead of sprintf().
  174. 2002-08-24 Pavel Roskin <proski@gnu.org>
  175. * edit-widget.h: Eliminate ERROR_FILE.
  176. * edit.c: Remove all references to ERROR_FILE.
  177. * editcmd.c (edit_block_process_cmd): Revert to using catstrs(),
  178. those strings are freed now. Use system(), not execute() to
  179. execute commands. Use open_error_pipe() and close_error_pipe()
  180. to keep track of errors.
  181. 2002-08-22 Pavel Roskin <proski@gnu.org>
  182. * editcmd.c: Clean up global variables in the completion code.
  183. * editwidget.c: Use new dialog flags.
  184. * editcmd.c: Likewise.
  185. (edit_completion_dialog): Set DLG_COMPACT for the dialog.
  186. * editcmd.c (compl_callback): Use common_dialog_repaint().
  187. * editcmd.c (raw_callback): Use standard common_dialog_repaint()
  188. to handle DLG_DRAW.
  189. 2002-08-21 Pavel Roskin <proski@gnu.org>
  190. * editwidget.c (edit): Make edit_bar a local variable.
  191. 2002-08-20 Pavel Roskin <proski@gnu.org>
  192. * editcmd.c (freestrs): Set freed strings to NULL.
  193. (catstrs): Use g_malloc() and g_free().
  194. * editcmd.c (freestrs): New function to clean temporary strings.
  195. * edit.c (edit_clean): Call freestrs().
  196. 2002-08-20 David Martin <dmartina@excite.com>
  197. * editmenu.c: Use new create_menu() interface.
  198. 2002-08-18 Pavel Roskin <proski@gnu.org>
  199. * editoptions.c: Make some variables static.
  200. * edit.h: Take extern declarations from all C files.
  201. * editcmd.c (edit_block_process_cmd): Plug memory leak.
  202. Simplify logic, reformat.
  203. 2002-08-02 Paul Sheer <psheer@icon.co.za>
  204. * edit.c (edit_push_action): Fix access to uninitialized memory.
  205. Found by Valgrind.
  206. 2002-08-01 Pavel Roskin <proski@gnu.org>
  207. * syntax.c: Remove all references to MAD.
  208. * edit.h: Don't include mad.h.
  209. 2002-07-29 Andrew V. Samoilov <kai@cmail.ru>
  210. * edit.h (edit_get_load_file): Mark message for translation.
  211. (edit_get_save_file): Ditto.
  212. 2002-07-20 Pavel Roskin <proski@gnu.org>
  213. * syntax.c (apply_rules_going_right): Recheck keyword rules when
  214. a keyword is found on the left border of a context.
  215. 2002-07-14 Pavel Roskin <proski@gnu.org>
  216. * syntax.c (edit_get_syntax_color): Return colorpair index, not
  217. attribute, when syntax highlighting is disabled. Handle black
  218. and white mode separately.
  219. * syntax.c (edit_load_syntax): Do nothing in black and white
  220. mode.
  221. * edit.h [!HAVE_SLANG]: Enable syntax highlighting.
  222. * editdraw.c [!HAVE_SLANG]: Respect attributes for color pairs
  223. by using MY_COLOR_PAIR macro.
  224. * edit.h (struct key_word): Remove unused "bg" field, rename
  225. "fg" to "color", since it keeps all color information.
  226. * syntax.c (edit_get_syntax_color): Replace "fg" and "bg"
  227. arguments with a single argument "color".
  228. Adjust all dependencies.
  229. * editdraw.c (edit_draw_this_line): Fix setting MOD_ABNORMAL
  230. attribute.
  231. (print_to_widget): Fix displaying non-printable characters with
  232. ncurses. Set color for every character even if syntax
  233. highlighting is not compiled - it's needed to reset color after
  234. non-printable characters.
  235. * editdraw.c (edit_status): Use EDITOR_NORMAL_COLOR instead of
  236. NORMAL_COLOR.
  237. * syntax.c (edit_get_syntax_color) [!HAVE_SYNTAXH]: Likewise.
  238. 2002-06-24 Pavel Roskin <proski@gnu.org>
  239. * edit.c (check_file_access): Return 1 on all errors, document
  240. this behavior. Set edit->delete_file to 1 for newly created
  241. files.
  242. (edit_open_file): Don't set edit->delete_file, it's now done in
  243. check_file_access().
  244. Reported by Saso <saso@bojler.dhs.org>
  245. 2002-05-13 Andrew V. Samoilov <kai@cmail.ru>
  246. * editcmd.c (edit_save_file): Call mc_chown() and mc_chmod()
  247. before mc_open() to prevent hangs over ftpfs.
  248. * edit.h: Remove open, close, write, read and mkdir definitions.
  249. * edit.c: Use mc_open, mc_close, mc_write, mc_read, mc_rename,
  250. mc_chmod and mc_chown. Don't cast (char *) to (unsigned long)
  251. in pointer arithmetics.
  252. * editcmd.c: Likewise.
  253. 2002-03-25 Andrew V. Samoilov <kai@cmail.ru>
  254. * syntax.c (edit_read_syntax_file): Use system wide Syntax
  255. Highlighting definitions' file if there is no users one.
  256. 2002-03-18 Pavel Roskin <proski@gnu.org>
  257. * edit.h: Use eregex.h, not regex.h.
  258. From Alexander Varakin <avarakin00@hotmail.com>
  259. 2002-02-27 Andrew V. Samoilov <kai@cmail.ru>
  260. * editcmd.c (edit_replace_cmd): Eliminate fin_string
  261. and use message() to fix possible buffer overflow.
  262. (edit_search_cmd): Likewise.
  263. 2002-02-18 Andrew V. Samoilov <kai@cmail.ru>
  264. * syntax.c (convert): Fix buffer overflow for ".*\" cases.
  265. 2002-01-22 Pavel Roskin <proski@gnu.org>
  266. * editdraw.c (edit_scroll_screen_over_cursor): Do nothing if the
  267. edit widget has zero width or height.
  268. 2002-01-21 Pavel Roskin <proski@gnu.org>
  269. * edit.c: Rename DELETE to DELCHAR to avoid macro redefinition
  270. on Win32.
  271. * edit.h: Likewise.
  272. 2002-01-21 Matthias Urban <murban@cs.uni-magdeburg.de>
  273. * edit.c: Add support for CK_Complete_Word event.
  274. * editcmddef.h: Likewise.
  275. * edit_key_translator.c (cooledit_key_map): Bind Alt-Tab to
  276. CK_Complete_Word.
  277. (emacs_key_map): Likewise.
  278. * editcmd.c: Implement word completion.
  279. 2002-01-21 Pavel Roskin <proski@gnu.org>
  280. * editmenu.c (CmdMenuEmacs): Add mail command without shortcut.
  281. Users of emacs keys should be able to send mail too.
  282. 2002-01-15 Andrew V. Samoilov <kai@cmail.ru>
  283. * syntax.c (syntax_g_free): New macro to release and NULLify
  284. glib allocated memory area(s).
  285. (strdup_convert): Rename to ...
  286. (convert): ... this. Don't strdup() passed string.
  287. (get_args): Use convert() instead of strdup_convert().
  288. (free_args): Make it do nothing macro.
  289. (open_include_file): Eliminate p array. Use glib function to
  290. construct error_file_name. Use PATH_SEP instead of '/';
  291. (edit_read_syntax_file): Use PATH_SEP_STR.
  292. (edit_load_syntax): Use syntax_g_free to release error_file_name.
  293. (edit_read_syntax_rules): Likewise.
  294. Eliminate c->single_char. It's only written but never read.
  295. * edit.h (struct context_rule): Comment out single_char field.
  296. It is written once but never read.
  297. * edit-widget.h: Use PATH_SEP_STR.
  298. 2001-12-22 Andrew V. Samoilov <kai@cmail.ru>
  299. * editcmd.c (edit_goto_cmd): Use g_free() to release f.
  300. (edit_save_file): Use PATH_SEP instead of '/'.
  301. Undefine "close" before closing file created by mc_mkstemps.
  302. Define close to mc_close() after it - temporary fix.
  303. (sprintf_p): Don't cast (char *) to (unsigned long).
  304. * syntax.c (read_one_line): Undo last patch - errno is a
  305. function on some systems. Check ferror() status before
  306. everything else if fgetc() returns EOF.
  307. Accept last line without trailing newline.
  308. (compare_word_to_right): Don't cast p and q to unsigned long.
  309. (apply_rules_going_right): Likewise.
  310. 2001-12-21 Pavel Roskin <proski@gnu.org>
  311. * edit.c (user_menu): Don't move the cursor before and after
  312. inserting the block.
  313. Reported by Matthias Urban <murban@cs.uni-magdeburg.de>
  314. * syntax.c (read_one_line): Clear errno before using it. Don't
  315. use the result of fgetc() if errno is EINTR.
  316. 2001-11-28 Andrew V. Samoilov <kai@cmail.ru>
  317. * syntax.c (apply_rules_going_right): Fix crash for lines like
  318. \s+ \n lightgray/13 red
  319. in Syntax file.
  320. (read_one_line): Use EOF instead of -1.
  321. (get_args): Fix buffer overflow for l without trailing
  322. whitespace(s).
  323. (break_a): New macro.
  324. (edit_read_syntax_rules): Use break_a to fix memory leaks.
  325. (edit_load_syntax): Eliminate s and use message to prevent
  326. buffer overflow.
  327. * editdraw.c (edit_render): Eliminate f. It's only written
  328. but never read.
  329. 2001-11-27 Andrew V. Samoilov <kai@cmail.ru>
  330. * editmenu.c (edit_wrap_cmd): Use g_free() on the result
  331. of input_dialog().
  332. 2001-11-22 Andrew V. Samoilov <kai@cmail.ru>
  333. * editcmd.c (edit_save_file): Use g_free() on the result of
  334. mc_mkstemps().
  335. (edit_replace_cmd): Fix rare memory leaks.
  336. 2001-11-19 Andrew V. Samoilov <kai@cmail.ru>
  337. * edit.c (edit_renew): Release dir after use.
  338. * editcmd.c (edit_replace_dialog): Eliminate tsearch_text,
  339. treplace_text and targ_order.
  340. (edit_replace_cmd): edit_replace_dialog gives g_malloced
  341. strings, so g_strdup/g_free have to be used. Accept only
  342. positive pattern number in Scanf search and replace.
  343. (edit_save_file): Enable safe save and backups on remote VFS.
  344. 2001-11-16 Andrew V. Samoilov <kai@cmail.ru>
  345. * edit_key_translator.c (cooledit_key_map):
  346. Add C-k, CK_Delete_To_Line_End.
  347. * edit.c (user_menu): Don't assign block_file twice.
  348. 2001-11-07 Andrew V. Samoilov <kai@cmail.ru>
  349. * edit.c (edit_reload): destroy_dlg g_free()s widget(s), so
  350. g_malloc/g_free have to be used.
  351. (edit_init): Ditto. Eliminate st.
  352. 2001-11-05 Andrew V. Samoilov <kai@cmail.ru>
  353. * edit.h (edit_execute_cmd): Declare it here.
  354. * edit.c: Remove edit_execute_cmd declaration.
  355. (edit_execute_cmd): Use edit_print_string instead of edit_printf.
  356. * editcmd.c: Remove edit_execute_cmd declaration.
  357. (edit_search_dialog): Eliminate tsearch_text.
  358. (edit_search_cmd): edit_search_dialog gives g_malloc()ed exp.
  359. Use g_strdup/g_free instead of strdup/free.
  360. (edit_mail_dialog): quick_dialog use g_strdup, so g_free
  361. must be used.
  362. (edit_load_cmd): input_dialog returns g_malloc(ed) string,
  363. so g_free has to be used.
  364. (edit_save_block_cmd): Likewise.
  365. (edit_insert_file_cmd): Likewise.
  366. (edit_sort_cmd): Likewise.
  367. (edit_save_as_cmd): Likewise. Memory leak fixed.
  368. * bookmark.c (book_mark_clear): Eliminate rend.
  369. It's only written but never read.
  370. (book_mark_flush): Likewise.
  371. (book_mark_inc): Likewise.
  372. (book_mark_dec): Likewise.
  373. 2001-10-23 Pavel Roskin <proski@gnu.org>
  374. * edit.c (user_menu): If the error file is missing, treat it as
  375. success. Truncate block file unconditionally.
  376. 2001-10-22 Pavel Roskin <proski@gnu.org>
  377. * edit.c: Stop using _EDIT_C definition. Move variable
  378. declarations from edit.h, make static or eliminate if possible.
  379. Report errors immediately.
  380. * edit.h: Likewise.
  381. * editwidget.c (edit): Don't report errors from edit_init(),
  382. they are reported in place.
  383. 2001-10-20 Pavel Roskin <proski@gnu.org>
  384. * editcmd.c (sprintf_p): Declare with the printf attribute.
  385. Make static.
  386. * edit.h: Declare edit_printf() with the printf attribute.
  387. 2001-10-18 Pavel Roskin <proski@gnu.org>
  388. * edit.c (check_file_access): Only allow to edit regular files.
  389. Use stat() before open() to prevent hangs on pipes, use fstat()
  390. afterwards if stat() was unsuccessful.
  391. 2001-09-17 Pavel Roskin <proski@gnu.org>
  392. * edit.h: Don't use macro `stat' - it's already a macro on
  393. Solaris 8 with large file support.
  394. * editcmd.c: Replace stat() with mc_stat().
  395. * edit.c: Likewise.
  396. 2001-09-11 Pavel Roskin <proski@gnu.org>
  397. * syntax.c (syntax_text): Remove, it's a separate file now.
  398. (upgrade_syntax_file): Remove.
  399. (edit_read_syntax_file): Use check_for_default().
  400. 2001-09-08 Pavel Roskin <proski@gnu.org>
  401. * edit.h: Remove some useless definitions.
  402. 2001-09-07 Pavel Roskin <proski@gnu.org>
  403. * Makefile.am: Don't define "MIDNIGHT" - it's unused now.
  404. * edit.c: Eliminate all code disabled for the text edition.
  405. * editcmddef.h: Likewise.
  406. * editmenu.c: Likewise.
  407. * editwidget.c: Likewise.
  408. * syntax.c: Likewise.
  409. * wordproc.c: Likewise.
  410. * edit-widget.h: Change ~/.cedit to ~/.mc/cedit to keep mcedit
  411. files separate from cooledit.
  412. * bookmark.c: Eliminate all code disabled for the text edition.
  413. * edit-widget.h: Likewise.
  414. * editcmd.c: Likewise.
  415. * editdraw.c: Likewise.
  416. * editoptions.c: Likewise.
  417. * edit.h: Eliminate all code disabled for the text edition.
  418. Reorder and simplify includes.
  419. * edit.c: Likewise.
  420. 2001-09-06 Pavel Roskin <proski@gnu.org>
  421. * syntax.c (syntax_text): Add PHP support from Cooledit.
  422. 2001-09-04 Pavel Roskin <proski@gnu.org>
  423. * Makefile.am (AM_CFLAGS): Remove CFLAGS, don't use substituted
  424. values directly.
  425. * syntax.c (syntax_text): Remove useless ']' in the Perl and
  426. Python rules. Change shell script rule to use more portable
  427. regular expression.
  428. * editcmd.c (edit_block_process_cmd): Prepend space to the
  429. command to avoid polluting bash history. Document arguments.
  430. Fix crash if block is 0 - not used currently.
  431. 2001-08-26 Pavel Roskin <proski@gnu.org>
  432. * Makefile.am: Don't install libedit.a.
  433. * Makefile.in: Converted to ...
  434. * Makefile.am: ... this.
  435. 2001-08-24 Pavel Roskin <proski@gnu.org>
  436. * Makefile.in (EDITSRC): Add headers.
  437. (CPPFLAGS): Remove reference to gtkedit.
  438. Copy all necessary files from gtkedit.
  439. * Makefile.in (EDITLINKS): Merge with EDITSRC, remove all
  440. references.
  441. 2001-08-24 Pavel Roskin <proski@gnu.org>
  442. * syntax.c (syntax_text): Fix recognizing pdksh and zsh scripts.
  443. 2001-08-23 Pavel Roskin <proski@gnu.org>
  444. * editcmd.c (edit_block_process_cmd): Use execute(), not
  445. my_system() to relieve interactive scripts, such as spell
  446. checker, from saving and restoring the terminal.
  447. 2001-08-19 Pavel Roskin <proski@gnu.org>
  448. * gtkedit.c: Include <sys/param.h> if present - it should always
  449. be included before <glib.h> to avoid redefining MIN and MAX.
  450. * editcmd.c [!MIDNIGHT]: Undefine B_ENTER and B_CANCEL before
  451. redefining them.
  452. * edit.h: Include <sys/param.h> if present. Include Gtk+
  453. headers as system headers.
  454. * gtkedit.c: Include Gtk+ headers as system headers.
  455. 2001-08-18 Pavel Roskin <proski@gnu.org>
  456. * syntax.c (syntax_text): Highlight *.pot as PO files.
  457. * edit.h [GTK]: Fix definition of edit_message_dialog().
  458. * gtkedit.c (gtk_edit_dialog_message): Use "OK" button, not
  459. "Cancel", for consistency with the text edition.
  460. 2001-08-17 Pavel Roskin <proski@gnu.org>
  461. * syntax.c (syntax_text): Add support for PO files.
  462. 2001-08-12 Pavel Roskin <proski@gnu.org>
  463. * edit.c: Handle CK_Shell.
  464. * editcmddef.h: Define CK_Shell.
  465. * editmenu.c (FileMenu): Remove C-o from the "Open file..."
  466. item.
  467. (FileMenuEmacs): Likewise.
  468. 2001-08-06 Andrew V. Samoilov <kai@cmail.ru>
  469. * editcmd.c (edit_replace_prompt): Fix menu location calculation.
  470. 2001-08-01 Pavel Roskin <proski@gnu.org>
  471. * editcmd.c (edit_save_file): Temporarily disable safe save
  472. and backups on remote VFS because it doesn't work. Use
  473. mc_mkstemps() instead of tempnam().
  474. 2001-07-29 Pavel Roskin <proski@gnu.org>
  475. * syntax.c (syntax_text): Add support for S-Lang.
  476. 2001-07-28 Pavel Roskin <proski@gnu.org>
  477. * editcmd.c (menu_save_mode_cmd): Resurrect i18n code lost in
  478. the last resync with Cooledit.
  479. Reported by David Martin <dmartina@excite.es>
  480. * gtkedit.c (gtk_edit_delete_cb): Handler for "delete_event".
  481. (edit): Connect it.
  482. 2001-07-27 Pavel Roskin <proski@gnu.org>
  483. * edit.c: Fix include.
  484. 2001-07-20 Pavel Roskin <proski@gnu.org>
  485. * syntax.c (open_include_file) [GTK]: Use mc_home instead of
  486. LIBDIR.
  487. 2001-07-19 Pavel Roskin <proski@gnu.org>
  488. * editcmd.c (edit_canonicalize_pathname): Don't ever use
  489. getwd(), use g_get_current_dir() instead.
  490. * editoptions.c (edit_options_dialog): Call edit_load_syntax()
  491. if user turned syntax highlighting off to unload the rules.
  492. 2001-07-17 Pavel Roskin <proski@gnu.org>
  493. * edit.h [MIDNIGHT]: Declare wedit.
  494. * editmenu.c: Remove wedit declaration.
  495. * editoptions.c (edit_options_dialog): Load syntax rules if user
  496. turned syntax highlighting on.
  497. * syntax.c (edit_load_syntax): Don't load rules if syntax
  498. highlighting is disabled.
  499. 2001-07-13 Pavel Roskin <proski@gnu.org>
  500. * editoptions.c (edit_options_dialog): Allow numbers for tab
  501. spacing. Reported by mharris@redhat.com.
  502. http://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=34852
  503. * editcmd.c (menu_save_mode_cmd): Give meaningful names to the
  504. input fields instead of "i" so that they have separate history.
  505. * editoptions.c (edit_options_dialog): Likewise.
  506. 2001-07-11 Pavel Roskin <proski@gnu.org>
  507. * editdraw.c (status_string): Use g_snprintf() instead of
  508. snprintf().
  509. From Libor Motyèka <l_motycka@ortex.cz>
  510. 2001-07-10 Pavel Roskin <proski@gnu.org>
  511. * gtkeditkey.c (edit_translate_key): When processing bindings
  512. with Alt check that Shift is not pressed - it's handled later.
  513. 2001-07-05 Pavel Roskin <proski@gnu.org>
  514. * editdraw.c: Comment fixes.
  515. 2001-06-26 Pavel Roskin <proski@gnu.org>
  516. * edit-widget.h (editor_widget): Rename `stat' to `stat1' to
  517. avoid problems on Solaris with 64-bit file access, when `stat'
  518. is a macro. All users adjusted.
  519. Reported by Maksym Polyakov <polyama@yahoo.com>.
  520. 2001-06-25 Pavel Roskin <proski@gnu.org>
  521. * gtkedit.c: Remove home_dir - it's declared in main.c.
  522. 2001-06-15 Pavel Roskin <proski@gnu.org>
  523. * editcmd.c (canonicalize_pathname) [GTK]: Rename to ...
  524. (edit_canonicalize_pathname): ... this to avoid namespace clash.
  525. * edit.h [MIDNIGHT]: Include "src/cmd.h" and "src/user.h".
  526. Remove declarations duplicating "src/user.h".
  527. [GTK]: Include "src/dialog.h" and "src/util.h".
  528. * editmenu.c (edit_wrap_cmd): Fix declaration.
  529. (edit_about_cmd): Likewise.
  530. * editwidget.c (get_key_state): Likewise.
  531. * editcmd.c (edit_quit_cmd): Don't use strcmp on the result of
  532. gtk_dialog_cauldron() since it's NULL if the dialog has been
  533. closed without using buttons.
  534. * edit.c (edit_execute_cmd): Put time format to a variable to
  535. avoid gcc warning about Y2K issues with %c in strftime().
  536. 2001-06-14 Pavel Roskin <proski@gnu.org>
  537. * edit.c: Declare cmd_F* static. Comment out cmd_F9.
  538. * edit.c: Use indented #error for compatibility with old C
  539. compilers.
  540. 2001-06-13 Pavel Roskin <proski@gnu.org>
  541. * edit.c (edit_execute_cmd) [GTK]: Disable user menu - it
  542. doesn't work.
  543. (user_menu) [GTK]: Disable.
  544. * gtkedit.c (tb_items): Use complete words. Disable pull-down
  545. menu.
  546. 2001-06-09 Pavel Roskin <proski@gnu.org>
  547. * editcmd.c (catstrs): Use interactive_display() without
  548. specifying the help file.
  549. From Andrew V. Samoilov.
  550. 2001-06-08 Andrew V. Samoilov <sav@bcs.zp.ua>
  551. * editcmd.c [HAVE_CHARSET]: Really include charset.h.
  552. * editmenu.c (edit_wrap_cmd): Memory leaking fixed.
  553. 2001-06-05 Pavel Roskin <proski@gnu.org>
  554. * edit.c [HAVE_CHARSET]: Include charsets.h and selcodepage.h.
  555. * editcmd.c [HAVE_CHARSET]: Add charset conversion support.
  556. * editdraw.c [HAVE_CHARSET]: Likewise.
  557. From Andrew V. Samoilov <sav@bcs.zp.ua>
  558. and Walery Studennikov <hqsoftware@mail.ru>.
  559. 2001-06-01 Pavel Roskin <proski@gnu.org>
  560. * gtkedit.h: Warning fix - use stricter declarations for
  561. destroy_me and destroy_me_user_data.
  562. 2001-05-31 Pavel Roskin <proski@gnu.org>
  563. * Makefile.in: Define HAVE_X and HAVE_GNOME, not just GTK -
  564. header files are using them.
  565. * editdraw.c (edit_render) [GTK]: Revert previous patch, it
  566. broke compilation.
  567. 2001-05-31 Andrew V. Samoilov <sav@bcs.zp.ua>
  568. * editdraw.c (edit_status): Use strcpy (s, ) instead of
  569. sprintf (s, "%s", ).
  570. (set_color) [MIDNIGHT]: Became a macro.
  571. (render_edit_text) [defined(MIDNIGHT) || defined(GTK)]: Warning fix.
  572. (edit_render) [GTK]: Eliminate win variable.
  573. (key_pending) [!GTK]: Warning fix.
  574. 2001-05-30 Pavel Roskin <proski@gnu.org>
  575. * editdraw.c (status_string): Use is_printable(). Declare
  576. static. Eliminate intermediate buffer. Use memset() for filling.
  577. Print byte as unsigned. Use C notation for hex numbers.
  578. * editdraw.c (status_string): Don't print non-printable chars.
  579. Better formatting. Print "<EOF>" at the end of file instead of
  580. -1. Use snprintf instead of sprintf.
  581. 2001-05-30 Andrew V. Samoilov <sav@bcs.zp.ua>
  582. * syntax.c (open_include_file) [MIDNIGHT]: Don't hardcode location
  583. of syntax file(s) with LIBDIR, use mc_home instead.
  584. From Ludovic Drolez <ludovic.drolez@freealter.com>.
  585. (syntax_text): Use perl.syntax to highlight perl modules (.pm).
  586. 2001-05-18 Pavel Roskin <proski@gnu.org>
  587. * editcmd.c (edit_replace_prompt): Warning fix.
  588. 2001-02-26 Pavel Roskin <proski@gnu.org>
  589. * editcmd.c (edit_delete_macro_cmd) [MIDNIGHT]: Don't use
  590. CK_Macro on the argument to edit_delete_macro().
  591. * edit.c (edit_init_file): Remove, it's useless. All the
  592. necessary files should be created when needed.
  593. * edit.h: Remove declaration of edit_init_file().
  594. 2000-11-01 Andrew V. Samoilov <sav@bcs.zp.ua>
  595. * editcmd.c (canonicalize_pathname) [GTK]: memory leaking fixed
  596. 2000-10-30 Pavel Roskin <proski@gnu.org>
  597. * editcmd.c (canonicalize_pathname) [GTK]: Make the argument
  598. constant.
  599. (edit_split_filename) [GTK]: Make the second argument constant
  600. to match the declaration.
  601. 2000-10-30 Andrew V. Samoilov <sav@bcs.zp.ua>
  602. * editcmd.c (edit_save_file): better error handling on writing
  603. (edit_sort_cmd): saved sort options proposed in dialog
  604. edit.h, editcmd.c: declaration for edit_save_block () added
  605. (edit_split_filename): f constified
  606. * edit.c (edit_init) [ENABLE_NLS]: option_whole_chars_search
  607. expanded by national letters using current locale on first call
  608. (edit_file_is_open) [MIDNIGHT]: all occurrences and related code
  609. are commented
  610. (edit_execute_cmd): typo in error message fixed
  611. 2000-09-30 Pavel Roskin <proski@gnu.org>
  612. * libgettext.h: Removed, shouldn't be here.
  613. * Makefile.in: Adjusted to remove libgettext.h
  614. 2000-09-15 Andrew V. Samoilov <sav@bcs.zp.ua>
  615. * editcmd.c (edit_delete_macro, edit_(load|save)_macro_cmd): don't
  616. translate keywords written to macro file or macro don't work, at least
  617. for Cyrillic. Made this as separate commit, so, if it seriously breaks
  618. compatibility it's easy to revert it.
  619. 2000-09-15 Andrew V. Samoilov <sav@bcs.zp.ua>
  620. * editcmd.c (edit_save_file): fopen()+fwrite()+fclose() replaced
  621. by open()+write()+close() to restore possibility to edit files
  622. over Midnight Commander's VFSes
  623. (edit_replace_cmd) [MIDNIGHT]: some more right algorithm to calculate
  624. menu coordinates used. I don't like if menu hides replaced text.
  625. (edit_goto_cmd): Memory leaking fixed when f is empty string
  626. 2000-09-07 Andrew V. Samoilov <sav@bcs.zp.ua>
  627. * edit.c (check_file_access) [MIDNIGHT,GTK]: error message localized;
  628. some cosmetics changes to avoid annoying warnings
  629. * editcmd.c (edit_save_file): pclose returns 0 on success,
  630. file fclose()d when fwrite fails
  631. (pipe_mail): malloc () + sprintf () replaced by g_strdup_printf ()
  632. * syntax.c (syntax_text): Makefile replaced by [Mm]akefile to cover
  633. makefile and GNUmakefile
  634. (upgrade_syntax_file): infinitive loop fixed when rule file
  635. is outdated but it cannot be unlinked/overwritten
  636. 2000-08-30 Pavel Roskin <proski@gnu.org>
  637. * editwidget.c [!MIDNIGHT]: include xdnd.h
  638. * Makefile.in: distribute xdnd.h
  639. 2000-08-18 Pavel Roskin <proski@gnu.org>
  640. * Makefile.in: adjusted list of distributed files.
  641. Added rule for rebuilding Makefile
  642. 2000-08-08 Pavel Roskin <proski@gnu.org>
  643. * gtkedit.c [GTK]: don't include mousemark.h
  644. * gtkedit.h [GTK]: likewise
  645. 2000-08-03 Pavel Roskin <proski@gnu.org>
  646. * mousemark.c, mousemark.h: removed
  647. * Makefile.in: don't distribute mousemark.h
  648. * gtkedit.c [MIDNIGHT]: don't include mousemark.h
  649. * gtkedit.h [MIDNIGHT]: likewise
  650. 2000-07-20 Andrew V. Samoilov <sav@bcs.zp.ua>
  651. * gtkedit/editcmd.c (edit_save_file): check fclose()s return value
  652. to prevent loss of data
  653. (edit_block_process_cmd): don't translate empty string
  654. * gtkedit/edit.h (edit_get_write_filter, edit_write_stream,
  655. edit_init_file): added declarations
  656. * edit.c (edit_filters): constified
  657. (edit_get_write_filter): filename constified
  658. (user_menu): don't translate empty string
  659. * syntax.c (syntax_text): constified
  660. (upgrade_syntax_file): syntax_line constified, f closed after use