ChangeLog 48 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509
  1. 2005-02-07 Roland Illig <roland.illig@gmx.de>
  2. * *.c: Removed trailing whitespace.
  3. 2005-02-07 Roland Illig <roland.illig@gmx.de>
  4. * edit.h: Removed catstrs, as it is only used in editcmd.c.
  5. * editcmd.c (catstrs): Changed declaration to be static.
  6. * editcmd.c: Added const qualifiers.
  7. * syntax.c: Don't use catstrs anymore.
  8. * edit.c (user_menu): Likewise.
  9. * editwidget.c: Likewise.
  10. 2005-02-07 Roland Illig <roland.illig@gmx.de>
  11. * edit.c: Improved message formatting.
  12. 2005-01-30 Roland Illig <roland.illig@gmx.de>
  13. * edit.h: Removed NO_INLINE_GETBYTE conditional. The name was
  14. misleading, as it really meant INLINE_GETBYTE. Furthermore,
  15. it has not been working since the split of edit.h into edit-widget.h.
  16. * edit.c: Likewise.
  17. 2005-01-26 Roland Illig <roland.illig@gmx.de>
  18. * editdraw.c (edit_status): Fixed drawing bug with ncurses.
  19. 2004-12-03 Roland Illig <roland.illig@gmx.de>
  20. * edit.h: Renamed multiple inclusion guards that started with a
  21. double underscore. Added #includes for dependent files.
  22. * editcmddef.h: Likewise.
  23. * editlock.h: Likewise.
  24. * edit-widget.h: Likewise.
  25. 2004-12-02 Roland Illig <roland.illig@gmx.de>
  26. * editcmd.c (edit_replace_cmd): Separated input and output arguments.
  27. * editcmd.c (edit_replace_dialog): Code cleanup.
  28. 2004-12-02 Pavel S. Shirshov <me@pavelsh.pp.ru>
  29. * editcmd.c (edit_replace_prompt): Fix warning with 'unused' label_len.
  30. 2004-12-01 Roland Illig <roland.illig@gmx.de>
  31. * editcmd.c: Introduced a type edit_getbyte_fn to get rid of
  32. the many function type casts.
  33. 2004-11-18 Andrew V. Samoilov <andrew@email.zp.ua>
  34. * syntax.c (get_args): Use in "args_size" argument instead of
  35. in out "argc". Return number of found entries.
  36. Adjust all callers.
  37. 2004-11-16 Andrew V. Samoilov <andrew@email.zp.ua>
  38. * syntax.c (get_args): Use "argc" to check "args" size.
  39. (edit_read_syntax_rules): Add new parameter "argc" (size of the
  40. "args" buffer) to prevent buffer overflow.
  41. 2004-11-10 Pavel Tsekov <ptsekov@gmx.net>
  42. * editdraw.c (edit_status): Don't output extra characters on the
  43. status line.
  44. (print_to_widget): Don't use addch() with negative offset to skip
  45. over excessive columns. Output only those columns that should be
  46. displayed on the screen.
  47. 2004-11-10 Roland Illig <roland.illig@gmx.de>
  48. * editcmd.c (edit_replace_prompt): Fixed codepage conversion bug
  49. introduced in on 2004-09-25 by me.
  50. 2004-10-23 Roland Illig <roland.illig@gmx.de>
  51. * editdraw.c (edit_status): Expand the filename field in the status
  52. line to 16 characters even if the actual filename is shorter.
  53. 2004-10-16 Roland Illig <roland.illig@gmx.de>
  54. * syntax.c (read_one_line): Fixed SEGV when reading syntax file
  55. with "\r\n" line endings on Unix.
  56. 2004-10-11 Leonard den Ottolander <leonard * den ottolander nl>
  57. * editcmd.c (regexp_error): Small text fix.
  58. (edit_search_cmd): Likewise.
  59. 2004-09-26 Roland Illig <roland.illig@gmx.de>
  60. * editcmd.c (edit_ext_cmd): Revoked my last change.
  61. 2004-09-25 Roland Illig <roland.illig@gmx.de>
  62. * editcmd.c (edit_ext_cmd): Replaced the old version with a new
  63. one that uses ../src/pipethrough. The new version feeds the
  64. currently selected block (or an empty input) into the command
  65. which reduces the chance of a deadlock when the command tried
  66. to read from stdin. It also allows the user to insert the output
  67. of a command that has exited with a nonzero result. Another
  68. feature is that it does not use temporary files.
  69. 2004-09-25 Roland Illig <roland.illig@gmx.de>
  70. * syntax.c (this_try_alloc_color_pair): Added const qualifiers.
  71. * editcmd.c (snprintf_p): Likewise. (edit_replace_prompt):
  72. Simplified the code.
  73. 2004-09-25 Pavel S. Shirshov <me@pavelsh.pp.ru>
  74. * edit.c (edit_clean): g_free handles NULL argument too,
  75. no need for the comparison.
  76. (edit_move_backward_lots): Likewise.
  77. * editcmd.c (edit_set_filename): Likewise.
  78. (edit_replace_cmd): Likewise.
  79. (edit_search_cmd): Likewise.
  80. (edit_sort_cmd): Likewise.
  81. (edit_mail_dialog): Likewise.
  82. * syntax.c (syntax_g_free): Likewise.
  83. (edit_read_syntax_rules): Likewise.
  84. 2004-09-24 Roland Illig <roland.illig@gmx.de>
  85. * editdraw.c (status_string): Removed unused parameter.
  86. (edit_status): Rewrote to allow longer filenames to be displayed
  87. completely whenever possible.
  88. * edit.c: Replaced NULL with (char *) NULL. Likewise for 0, where
  89. NULL was meant.
  90. * editcmd.c: Likewise.
  91. * editlock.c: Likewise.
  92. * editwidget.c: Likewise.
  93. * syntax.c: Likewise.
  94. 2004-09-19 Roland Illig <roland.illig@gmx.de>
  95. * editcmd.c (edit_replace_cmd): Added const qualifier.
  96. * editwidget.c (edit_my_define): likewise.
  97. * editcmd.c (edit_replace_prompt): Allocate the label text
  98. dynamically instead of using catstrs. Don't handle
  99. ENABLE_CHARSET specially.
  100. * edit.h: renamed edit() to edit_file() to avoid GCC shadow
  101. warnings (many variables are also called edit).
  102. * editwidget.c: likewise.
  103. 2004-09-17 Andrew V. Samoilov <andrew@email.zp.ua>
  104. * editcmd.c (edit_replace_prompt) [HAVE_CHARSET]: Warning hack.
  105. 2004-09-03 Pavel S. Shirshov <me@pavelsh.pp.ru>
  106. * editwidget.c (edit_adjust_size): Fix warnings.
  107. (edit_dialog_callback): Likewise.
  108. * edit.c (menu_save_mode_cmd): Likewise.
  109. Based on patch from Jakub Jelinek <jakub@redhat.com>
  110. 2004-09-02 Pavel S. Shirshov <me@pavelsh.pp.ru>
  111. * editcmd.c (edit_save_as_cmd): Add hotkey to dialog.
  112. (edit_save_confirm_cmd): Likewise. (edit_new_cmd): Likewise.
  113. (edit_load_cmd): Likewise. (edit_block_move_cmd): Likewise.
  114. (edit_block_delete): Likewise. (edit_ok_to_exit): Likewise.
  115. 2004-09-01 Pavel S. Shirshov <me@pavelsh.pp.ru>
  116. * syntax.c (this_try_alloc_color_pair): Use g_strlcpy instead
  117. sequence strncpy(), name[len] = '\0'
  118. (edit_read_syntax_rules): Likewise.
  119. 2004-08-29 Roland Illig <roland.illig@gmx.de>
  120. * Code cleanup: Added const qualifier for variables and
  121. function declarations where possible. No functional changes.
  122. 2004-08-26 Leonard den Ottolander <leonard * den ottolander nl>
  123. * edit/editcmd.c: Fix buffer overflows in edit replace code.
  124. Based on patch from Jakub Jelinek <jakub@redhat.com>
  125. 2004-08-23 Jakub Jelinek <jakub@redhat.com>
  126. * syntax.c: (edit_read_syntax_rules): Fix boundary conditions.
  127. 2004-08-23 David Sterba <dave@jikos.cz>
  128. * syntax.c: (edit_read_syntax_rules): Dynamically allocate
  129. more space for contexts and for words in context.
  130. 2004-08-16 Roland Illig <roland.illig@gmx.de>
  131. * edit.c (several functions): Changed the data type of some
  132. variables from int to size_t (for string lengths) or unsigned
  133. long (for editor offsets) to avoid implicit sign conversions.
  134. No functional changes.
  135. * edit.c, editcmds.h: Moved the semicolon out of the macro
  136. definition SHELL_COMMANDS_i, so that the declaration in edit.c
  137. looks more natural. No functional changes.
  138. * editcmd.c: Added missing initializers for QuickDialogs.i18n.
  139. Replaced the last item in QuickWidgets from {0} to
  140. NULL_QuickWidget (that is, added missing initializers).
  141. (edit_completion_dialog): Made dlg_h and dlg_w unsigned to
  142. avoid implicit sign conversion. No functional changes.
  143. * editlock.c (lock_build_name, edit_lock_file): Casted pid to
  144. int to avoid wrong type argument for printf. No other functional
  145. changes.
  146. * editoptions.c: Added missing initializers for QuickDialogs
  147. and QuickWidgets. No functional changes.
  148. * syntax.c (xx_strchr): Removed explicit loop unrolling. It's
  149. the job of the compiler.
  150. 2004-02-04 Pavel Roskin <proski@gnu.org>
  151. * editcmddef.h: Split CK_No_Command into CK_Insert_Char and
  152. CK_Ignore_Key.
  153. * editkeys.c (emacs_key_map): Ignore Ctrl-g. Requested by
  154. Paul Seelig <pseelig@uni-mainz.de>
  155. (edit_translate_key): Implement CK_Ignore_Key.
  156. * edit.c (edit_execute_key_command): Return void, the result is
  157. never used.
  158. (edit_execute_cmd): Likewise.
  159. 2003-12-24 Dmitry Alexeyev <dmi_a@qnx.org.ru>
  160. * syntax.c (edit_read_syntax_rules): Fix crash if syntax file
  161. has more than 1024 keywords.
  162. 2003-11-27 Pavel Roskin <proski@gnu.org>
  163. * editcmd.c: Use input_expand_dialog() instead of input_dialog()
  164. for loading and saving files.
  165. 2003-11-24 Andrew V. Samoilov <sav@bcs.zp.ua>
  166. * editcmd.c (pipe_mail): Eliminate g_strdup_printf().
  167. (edit_complete_word_cmd): Fix possible buffer overflow.
  168. 2003-11-03 Andrew V. Samoilov <sav@bcs.zp.ua>
  169. * editcmd.c (edit_mail_dialog): Trivial clean-up.
  170. 2003-10-23 Andrew V. Samoilov <sav@bcs.zp.ua>
  171. * edit-widget.h (struct WEdit): Add GTree *defines field.
  172. * syntax.c: Use edit->defines instead of static defines.
  173. 2003-10-16 Andrew V. Samoilov <sav@bcs.zp.ua>
  174. * syntax.c (compare_word_to_right): More checks for braces and
  175. brackets.
  176. 2003-10-16 Pavel Roskin <proski@gnu.org>
  177. * syntax.c (compare_word_to_right): Fix recent breakage - rules
  178. ending with wildcard (e.g. "$+") won't match.
  179. 2003-10-14 Pavel Roskin <proski@gnu.org>
  180. * edit.h: Make static all functions and variables that don't
  181. need to be global. Remove unused functions. Adjust all
  182. dependencies.
  183. 2003-09-22 Pavel Roskin <proski@gnu.org>
  184. * syntax.c: Give names to numeric tokens.
  185. * syntax.c (compare_word_to_right): Add checks that we don't go
  186. beyond text length for certain invalid rules.
  187. Reported by Juan C. Olivares <juancri@TAGnet.org>
  188. 2003-09-12 Pavel Roskin <proski@gnu.org>
  189. * editcmd.c (edit_raw_key_query): Use straight widget order.
  190. (edit_completion_dialog): Likewise.
  191. * editwidget.c (edit): Likewise.
  192. 2003-09-07 Pavel Roskin <proski@gnu.org>
  193. * edit.h: Get rid of WIDGET_COMMAND, update all dependencies.
  194. 2003-07-31 Andrew V. Samoilov <sav@bcs.zp.ua>
  195. * edit-widget.h: Resurrect "dir" field in WEdit to store
  196. directory for relative filenames.
  197. * edit.c (edit_clean): Release edit->dir.
  198. * editcmd.c (edit_save_file): Use absolute filename.
  199. Temporarily disable safe save and backups on remote VFS because
  200. it doesn't work - again.
  201. 2003-07-25 Pavel Roskin <proski@gnu.org>
  202. * edit.c (edit_execute_cmd): Enable user menu in mcedit.
  203. 2003-07-20 Pavel Roskin <proski@gnu.org>
  204. * editcmd.c (edit_quit_cmd): Rename to ...
  205. (edit_ok_to_exit): ... this. Don't stop dialog - this function
  206. is called by the dialog code.
  207. * editwidget.c (edit_dialog_callback): Process DLG_VALIDATE
  208. event. Don't exit it the user wants to continue editing.
  209. * edit.c (edit_execute_cmd): Close the dialog - it will ask user
  210. if necessary.
  211. * editcmd.c (edit_quit_cmd): Don't save this command in the undo
  212. stack. Don't force any refresh. Don't delete unsaved files, do
  213. it ...
  214. * edit.c (edit_clean): ... here. This ensures that unsaved
  215. files from the mcedit command line are erased on Ctrl-n.
  216. * editwidget.c (edit): Remove unused variable "framed".
  217. 2003-07-08 Adam Byrtek <alpha@debian.org>
  218. * edit.c (edit_clean): Remove stale lock if any.
  219. 2003-07-08 Pavel Roskin <proski@gnu.org>
  220. * edit-widget.h: Add new field loading_done.
  221. * edit.c (edit_init): Set loading_done.
  222. (edit_insert): Don't call edit_modification() before the file is
  223. completely loaded.
  224. * edit-widget.h: Eliminate unused explicit_syntax field.
  225. * edit-widget.h: Stop misusing "unsigned char" for boolean.
  226. Eliminate have_frame - it's unused. Adjust all dependencies.
  227. 2003-06-14 Pavel Roskin <proski@gnu.org>
  228. * editkeys.c: Leave only distinct entries in cooledit_key_map
  229. and emacs_key_map. Move the rest to common_key_map.
  230. 2003-06-09 Pavel Roskin <proski@gnu.org>
  231. * editkeys.c (emacs_key_map): Move Atl-'>' and Alt-'<' ...
  232. (common_key_map): ... here.
  233. 2003-06-05 Andrew V. Samoilov <sav@bcs.zp.ua>
  234. * editcmd.c (edit_ext_cmd): Fix memory leak.
  235. 2003-05-30 Michal Szwaczko <mikey@scene.pl>
  236. * editcmd.c: Implement pasting the output of any external
  237. command.
  238. * editmenu.c: Add menu entries for that.
  239. * editcmddef.h: Add new command CK_ExtCmd.
  240. 2003-04-04 Adam Byrtek <alpha@debian.org>
  241. * edit.c: Move edit_modification() before actions to provide
  242. proper repainting if there are dialogs invoked by actions.
  243. * editlock.c: Split lock into user@host and pid and report them
  244. separately.
  245. 2003-04-02 Pavel Roskin <proski@gnu.org>
  246. * edit.c (edit_load_file): Use vfs_file_is_local(), not
  247. vfs_current_is_local().
  248. * editlock.c (edit_lock_file): Disable locking on VFS.
  249. 2003-04-01 Adam Byrtek <alpha@debian.org>
  250. * editlock.c, editlock.h: New files. Implement file locking in
  251. Emacs style, as documented in JED editor sources.
  252. * Makefile.am: Add those files to build tree.
  253. * edit-widget.c (WEdit): New property 'locked', 0 on edit_init.
  254. * edit.c (edit_modification): Lock buffer on modification.
  255. * editcmd.c (edit_save_cmd, edit_save_as_cmd): Handle locking
  256. during file save.
  257. (edit_load_file_from_filename): Unlock. Remove 2 duplicate
  258. lines (handled by edit_init).
  259. (edit_quit_cmd): Unlock.
  260. 2003-03-12 Pavel Roskin <proski@gnu.org>
  261. * edit.h: Make it easier to tweak buffer size and maximal number
  262. of buffers.
  263. 2003-03-07 Pavel Roskin <proski@gnu.org>
  264. * editkeys.c (common_key_map): Delete previous word by
  265. Alt-Backspace. Fix Ctrl-Backspace on some terminals.
  266. Reported by Andrew V. Samoilov <sav@bcs.zp.ua>
  267. 2003-03-06 Andrew V. Samoilov <sav@bcs.zp.ua>
  268. * syntax.c (edit_read_syntax_file): Fix segmentation violation.
  269. 2003-03-03 Andrew V. Samoilov <sav@bcs.zp.ua>
  270. * syntax.c (edit_read_syntax_rules): Check for list of defines
  271. is already initialized.
  272. (edit_read_syntax_file): Process `include ...` before first
  273. `file ...`, so color definitions can be stored separately.
  274. * syntax.c (subst_defines): New function to substitute defines.
  275. (this_try_alloc_color_pair): Move color substitution ...
  276. (edit_read_syntax_rules): ... here. Use subst_defines() to
  277. substitute colors for contexts and keywords. Allow multiword
  278. defines.
  279. 2003-02-26 Andrew V. Samoilov <sav@bcs.zp.ua>
  280. * syntax.c (edit_read_syntax_rules): Add args argument and use
  281. it instead of own auto args array to share this area with ...
  282. (edit_read_syntax_file): ... this. Adjust for the above.
  283. Use strncpy() instead of unsafe strcpy().
  284. 2003-02-25 Andrew V. Samoilov <sav@bcs.zp.ua>
  285. * syntax.c (defines): New static variable for list of defines.
  286. (mc_defines_destroy): New function to release memory of key
  287. pair.
  288. (destroy_defines): New function to destroy list of defines
  289. completely.
  290. (this_try_alloc_color_pair): Use strncpy() instead of unsafe
  291. strcpy(). Use values from list of defines to substitute given
  292. parameters.
  293. (edit_read_syntax_rules): Initialize list of defines and process
  294. new "define" keyword. Use strncpy() instead of unsafe strcpy().
  295. (edit_free_syntax_rules): Destroy list of defines.
  296. 2003-02-21 Andrew V. Samoilov <sav@bcs.zp.ua>
  297. * editmenu.c (OptMenuEmacs): Define as OptMenu.
  298. (SearReplMenuEmacs): Define as SearReplMenu.
  299. (EditMenuEmacs): Define as EditMenu.
  300. 2002-12-28 Pavel Roskin <proski@gnu.org>
  301. * editmenu.c (OptMenu): Add "Learn Keys".
  302. (OptMenuEmacs): Likewise.
  303. 2003-01-27 Andrew V. Samoilov <sav@bcs.zp.ua>
  304. * edit-widget.h (struct macro): Move definition ...
  305. * edit.h: ... here to fix compilation on HP-UX.
  306. 2002-12-25 Pavel Roskin <proski@gnu.org>
  307. * editkeys.c: Move key maps to the file scope. Put common keys
  308. to a separate table common_key_map.
  309. (edit_translate_key): Remove unused argument x_keycode.
  310. * editkeys.c (edit_translate_key): Treat Shift-Enter as return
  311. without indent. Useful when pasting multiline text with
  312. Shift-button3 or Shift-Insert with autoindent enabled.
  313. 2002-12-23 Pavel Roskin <proski@gnu.org>
  314. * editkeys.c (edit_translate_key): Treat Ctrl-Home and Ctrl-End
  315. like Ctrl-PgUp and Ctrl-PgDown respectively.
  316. * edit_key_translator.c: Rename to ...
  317. * editkeys.c: ... this.
  318. * edit.c (edit_translate_key): Move to editkeys.c.
  319. * Makefile.am: Adjust for the above.
  320. 2002-12-21 Pavel Roskin <proski@gnu.org>
  321. * edit.c (edit_translate_key): Remove x_state argument, it's now
  322. a part of x_keycode.
  323. * editwidget.c (get_key_state): Remove.
  324. 2002-12-18 Andrew V. Samoilov <sav@bcs.zp.ua>
  325. * editcmd.c (edit_block_process_cmd): Quote filename.
  326. * edit.h (edit_save_mode_t): New enum for file saving mode.
  327. * editcmd.c (): Use edit_save_mode_t.
  328. (pipe_mail): Quote to, subject and cc with name_quote().
  329. * edit.c (edit_get_filter): Use quoted filename.
  330. (edit_get_write_filter): Use quoted writename.
  331. (edit_push_action): Use g_realloc().
  332. 2002-12-16 Pavel Roskin <proski@gnu.org>
  333. * editcmd.c (edit_goto_cmd): Add support for negative line
  334. numbers, which are counted from the last line. Use strtol(), so
  335. hex numbers are supported as well.
  336. * edit.c: Use edit->stack_disable instead of static variable.
  337. 2002-12-15 Pavel Roskin <proski@gnu.org>
  338. * edit.c (check_file_access): Use non-blocking open() followed
  339. by fstat() to avoid race conditions. Don't ask users to
  340. recompile the editor.
  341. * edit.c (edit_reload): Don't initialize edit->macro_i, because
  342. edit_init() takes care of it.
  343. * editwidget.c (edit): Likewise.
  344. * edit.h: Don't inclide malloc.h. Use g_malloc() and g_free()
  345. instead. Adjust all dependencies.
  346. * edit.c (edit_load_file): Merge edit_open_file(). Disable fast
  347. loading on non-local VFS because the file size can be wrong.
  348. (init_dynamic_edit_buffers): Split into edit_init_buffers() and
  349. edit_load_file_fast().
  350. * edit.c (edit_init): Move file loading to ...
  351. (edit_load_file): ... a separate function.
  352. * edit.c (init_dynamic_edit_buffers): Remove unused code to
  353. support loading text from buffer.
  354. 2002-12-14 Pavel Roskin <proski@gnu.org>
  355. * editcmd.c (edit_split_filename): Rename to edit_set_filename,
  356. use g_malloc() and g_free() on edit->filename.
  357. 2002-12-08 Pavel Roskin <proski@gnu.org>
  358. * edit.c (edit_open_file): Remove "text" and "text_size"
  359. arguments. Adjust all callers.
  360. * edit.c (edit_move_to_column): Remove, use
  361. edit_move_to_prev_col() instead.
  362. * edit.c: Commit the rest of the position saving code.
  363. (edit_load_position): New function, load position.
  364. (edit_save_position): New function, save position.
  365. (edit_init): Take new argument "line". If it's 0, load position
  366. from .mc/filepos.
  367. (edit_clean): Save file position to .mc/filepos even if the file
  368. is not being saved.
  369. * editwidget.c (edit): Don't set the initial line, pass it to
  370. edit_init().
  371. 2002-12-07 Pavel Roskin <proski@gnu.org>
  372. * syntax.c (edit_load_syntax): Reuse more informative error
  373. message.
  374. * edit.c (check_file_access): Use O_EXCL when opening new files.
  375. Don't allow editing stale symlinks.
  376. Reported by Max Derzhak <max@linux.zp.ua>
  377. 2002-12-05 Pavel Roskin <proski@gnu.org>
  378. * edit-widget.h: Remove "from_here" and "to_here".
  379. * edit.c (edit_purge_widget): New function - clean struct WEdit
  380. except the Widget part.
  381. 2002-12-04 Pavel Roskin <proski@gnu.org>
  382. * editcmd.c: Include dialog.h.
  383. Reported by Frédéric L. W. Meunier <lists@pervalidus.net>
  384. 2002-11-30 Pavel Roskin <proski@gnu.org>
  385. * edit.h: Remove "dir" field in WEdit - it's always an empty
  386. string. Adjust all dependencies.
  387. * editcmd.c (edit_get_load_file): Remove first argument, it's
  388. unused.
  389. (edit_get_save_file): Likewise.
  390. * syntax.c: Make structures key_word, context_rule and
  391. _syntax_marker opaque.
  392. * edit.c: Use g_malloc() and g_free() on buffers1 and buffers2.
  393. Eliminate CMalloc.
  394. (edit_get_buffer_as_text): Remove, it's unused.
  395. * editcmd.c (edit_set_search_parameters): Use g_malloc().
  396. (edit_complete_word_cmd): Use g_free().
  397. 2002-11-29 Pavel Roskin <proski@gnu.org>
  398. * edit.h: Don't define HAVE_SYNTAXH.
  399. * syntax.c: Syntax highlighting is no more optional.
  400. (edit_check_spelling): Remove.
  401. * editoptions.c (edit_options_dialog): Add "Save file position"
  402. option, make "Syntax highlighting" unconditional.
  403. * edit.c: First part of the position saving code.
  404. (edit_move_to_column): New function.
  405. 2002-11-29 Andrew V. Samoilov <sav@bcs.zp.ua>
  406. * editoptions.c (edit_options_dialog): Use g_free() to release
  407. variables allocated in quick_dialog().
  408. 2002-11-28 Pavel Roskin <proski@gnu.org>
  409. * edit-widget.h: Move typedef WEdit and file names ...
  410. * edit.h: ... here. Don't include edit-widget.h. Adjust all
  411. dependencies.
  412. 2002-11-23 Andrew V. Samoilov <sav@bcs.zp.ua>
  413. * editoptions.c (edit_options_dialog): Clean up and use g_snprintf()
  414. instead of sprintf().
  415. 2002-11-14 Pavel Roskin <proski@gnu.org>
  416. * edit.h: Decentralize includes.
  417. * editmenu.c (edit_user_menu_cmd): Move to ../src/cmd.c.
  418. * edit.c (edit_delete_line): Don't remove and restore the
  419. preceding newline. Don't treat binary zero as newline.
  420. From Dmitry Semyonov <Dmitry.Semyonov@oktet.ru>
  421. 2002-11-12 Pavel Roskin <proski@gnu.org>
  422. * *.c: Fix all global functions without declarations - declare,
  423. make static or remove.
  424. * syntax.c (syntax_change_callback): Remove, it's unused.
  425. (edit_set_syntax_change_callback): Likewise.
  426. * edit.c (edit_execute_cmd): Fool gcc to prevent Y2K warning.
  427. * editwidget.c (edit_adjust_size): Use find_buttonbar().
  428. 2002-11-11 Pavel Roskin <proski@gnu.org>
  429. * editcmd.c: Warning fix for compilers that don't understand the
  430. "const" keyword and variable size arrays.
  431. 2002-11-06 Pavel Roskin <proski@gnu.org>
  432. * editcmd.c (edit_save_file): Restore ownership before access
  433. mode, not after. Otherwise suid bit is lost.
  434. Reported by Nerijus Baliunas <nerijus@users.sourceforge.net>
  435. 2002-10-30 Pavel Roskin <proski@gnu.org>
  436. * edit.c: Include charset.h unconditionally, use new conversion
  437. functions that don't require ifdefs.
  438. * edit_key_translator.c: Likewise.
  439. * editcmd.c: Likewise.
  440. * editdraw.c: Likewise.
  441. 2002-10-20 Pavel Roskin <proski@gnu.org>
  442. * edit-widget.h: Add new field macro_depth to control depth of
  443. macro recursion.
  444. * edit.c (edit_execute_macro): Make static. Increment
  445. macro_depth on entry, decrement on exit, don't allow it to be
  446. too large.
  447. * wordproc.c (line_start): Remove incorrect optimization abusing
  448. static variables. Internal formatting should be usable now.
  449. 2002-10-18 Pavel Roskin <proski@gnu.org>
  450. * wordproc.c (begin_paragraph): Fix the same off-by-one error as
  451. in end_paragraph() - it affects formatting of the paragraph
  452. after the first line in the file it that line starts with a dot.
  453. Remove unused argument.
  454. * wordproc.c (end_paragraph): The last line of the file wasn't
  455. tested for being blank, which resulted in the last newline
  456. becoming a space after formatting.
  457. 2002-10-17 Pavel Roskin <proski@gnu.org>
  458. * editoptions.c (edit_options_dialog): Don't allow
  459. option_tab_spacing to be 0. Reset invalid values to 8.
  460. Reported by Ury N. Stankevich <ury@bofh.homeunix.org>
  461. 2002-10-08 Pavel Roskin <proski@gnu.org>
  462. * wordproc.c (format_paragraph): If formatting was successful,
  463. scroll to the left to show the formatted paragraph.
  464. 2002-10-06 Pavel Roskin <proski@gnu.org>
  465. * editdraw.c (print_to_widget): Eliminate use of floating point.
  466. Change all callers.
  467. 2002-10-02 Andrew V. Samoilov <sav@bcs.zp.ua>
  468. * editcmd.c (edit_insert_column_of_text): Fix infinite loop if
  469. block of text is copied past the end of the buffer.
  470. By Paul Sheer <psheer@icon.co.za>.
  471. (stacked): Don't initialize static arrays by zeros.
  472. 2002-09-26 Andrew V. Samoilov <sav@bcs.zp.ua>
  473. * edit.h (struct key_word): Remove time field.
  474. * syntax.c: Remove MAD support.
  475. 2002-09-24 Pavel Roskin <proski@gnu.org>
  476. * editwidget.c (edit): Make edit_dlg local variable.
  477. * editmenu.c (edit_drop_menu_cmd): Don't use edit_dlg variable.
  478. * edit.c: Remove all references to CR_LF_TRANSLATION.
  479. * editcmd.c: Likewise.
  480. 2002-09-23 Pavel Roskin <proski@gnu.org>
  481. * editwidget.c (edit): Install handler for DLG_RESIZE.
  482. * editwidget.c (edit): Set edit_dlg to NULL after it's
  483. destroyed.
  484. * edit.h: Move style definitions ...
  485. * editdraw.c: ... here. Multiply them by 256. Remove unused
  486. styles.
  487. (print_to_widget): Don't divide style by 256. Simplify logic
  488. since we only have 4 styles now.
  489. * edit.c (edit_move_forward3): Use caret notation for code 127
  490. and below code 32.
  491. * editdraw.c (edit_draw_this_line): Likewise. Print '.' for
  492. other non-printable characters and remove this code from ...
  493. (print_to_widget): ... here.
  494. * edit.c (edit_move_forward3): Show '\r' as ^M.
  495. * editdraw.c (edit_draw_this_line): Likewise. Use MOD_ABNORMAL
  496. attribute.
  497. From Alexander Varakin <avarakin00@hotmail.com>
  498. * edit.h: Remove all references to O_TEXT, USE_O_TEXT and
  499. MY_O_TEXT.
  500. * edit.c: Use O_BINARY when opening files.
  501. * editcmd.c: Likewise.
  502. From Alexander Varakin <avarakin00@hotmail.com>
  503. 2002-09-20 Pavel Roskin <proski@gnu.org>
  504. * editwidget.c (edit_event): Add support for mouse wheel events.
  505. * edit.h: Add missing declarations for edit_move_up() and
  506. edit_move_down().
  507. 2002-09-20 Andrew V. Samoilov <sav@bcs.zp.ua>
  508. * edit.c: Don't initialize static selection and selection_history.
  509. * editdraw.c (status_string): Remove font_width argument.
  510. (edit_status): Fix calculation to use last column in the
  511. status string.
  512. 2002-09-04 Pavel Roskin <proski@gnu.org>
  513. * edit.c (edit_filters): Use gzip, not compress for *.Z files
  514. for consistency with other parts of the code (viewer, mc.ext).
  515. 2002-09-03 Pavel Roskin <proski@gnu.org>
  516. * editcmd.c: Recheck and fix all calls to create_dlg().
  517. * editwidget.c: Likewise.
  518. 2002-09-02 Pavel Roskin <proski@gnu.org>
  519. * editcmd.c (edit_raw_key_query): Eliminate
  520. x_set_dialog_title().
  521. 2002-09-01 Pavel Roskin <proski@gnu.org>
  522. * editcmd.c (edit_block_process_cmd): Restore third argument
  523. (but make it /dev/null) for compatibility with old scripts.
  524. Reported by Andrew V. Samoilov <sav@bcs.zp.ua>
  525. 2002-08-31 Pavel Roskin <proski@gnu.org>
  526. * editwidget.c (edit): Avoid passing an uninitialized color
  527. array to create_dlg() - pass NULL instead.
  528. 2002-08-27 Andrew V. Samoilov <sav@bcs.zp.ua>
  529. * editcmd.c (edit_printf): Use g_vsnprintf() instead of sprintf().
  530. 2002-08-24 Pavel Roskin <proski@gnu.org>
  531. * edit-widget.h: Eliminate ERROR_FILE.
  532. * edit.c: Remove all references to ERROR_FILE.
  533. * editcmd.c (edit_block_process_cmd): Revert to using catstrs(),
  534. those strings are freed now. Use system(), not execute() to
  535. execute commands. Use open_error_pipe() and close_error_pipe()
  536. to keep track of errors.
  537. 2002-08-22 Pavel Roskin <proski@gnu.org>
  538. * editcmd.c: Clean up global variables in the completion code.
  539. * editwidget.c: Use new dialog flags.
  540. * editcmd.c: Likewise.
  541. (edit_completion_dialog): Set DLG_COMPACT for the dialog.
  542. * editcmd.c (compl_callback): Use common_dialog_repaint().
  543. * editcmd.c (raw_callback): Use standard common_dialog_repaint()
  544. to handle DLG_DRAW.
  545. 2002-08-21 Pavel Roskin <proski@gnu.org>
  546. * editwidget.c (edit): Make edit_bar a local variable.
  547. 2002-08-20 Pavel Roskin <proski@gnu.org>
  548. * editcmd.c (freestrs): Set freed strings to NULL.
  549. (catstrs): Use g_malloc() and g_free().
  550. * editcmd.c (freestrs): New function to clean temporary strings.
  551. * edit.c (edit_clean): Call freestrs().
  552. 2002-08-20 David Martin <dmartina@excite.com>
  553. * editmenu.c: Use new create_menu() interface.
  554. 2002-08-18 Pavel Roskin <proski@gnu.org>
  555. * editoptions.c: Make some variables static.
  556. * edit.h: Take extern declarations from all C files.
  557. * editcmd.c (edit_block_process_cmd): Plug memory leak.
  558. Simplify logic, reformat.
  559. 2002-08-02 Paul Sheer <psheer@icon.co.za>
  560. * edit.c (edit_push_action): Fix access to uninitialized memory.
  561. Found by Valgrind.
  562. 2002-08-01 Pavel Roskin <proski@gnu.org>
  563. * syntax.c: Remove all references to MAD.
  564. * edit.h: Don't include mad.h.
  565. 2002-07-29 Andrew V. Samoilov <kai@cmail.ru>
  566. * edit.h (edit_get_load_file): Mark message for translation.
  567. (edit_get_save_file): Ditto.
  568. 2002-07-20 Pavel Roskin <proski@gnu.org>
  569. * syntax.c (apply_rules_going_right): Recheck keyword rules when
  570. a keyword is found on the left border of a context.
  571. 2002-07-14 Pavel Roskin <proski@gnu.org>
  572. * syntax.c (edit_get_syntax_color): Return colorpair index, not
  573. attribute, when syntax highlighting is disabled. Handle black
  574. and white mode separately.
  575. * syntax.c (edit_load_syntax): Do nothing in black and white
  576. mode.
  577. * edit.h [!HAVE_SLANG]: Enable syntax highlighting.
  578. * editdraw.c [!HAVE_SLANG]: Respect attributes for color pairs
  579. by using MY_COLOR_PAIR macro.
  580. * edit.h (struct key_word): Remove unused "bg" field, rename
  581. "fg" to "color", since it keeps all color information.
  582. * syntax.c (edit_get_syntax_color): Replace "fg" and "bg"
  583. arguments with a single argument "color".
  584. Adjust all dependencies.
  585. * editdraw.c (edit_draw_this_line): Fix setting MOD_ABNORMAL
  586. attribute.
  587. (print_to_widget): Fix displaying non-printable characters with
  588. ncurses. Set color for every character even if syntax
  589. highlighting is not compiled - it's needed to reset color after
  590. non-printable characters.
  591. * editdraw.c (edit_status): Use EDITOR_NORMAL_COLOR instead of
  592. NORMAL_COLOR.
  593. * syntax.c (edit_get_syntax_color) [!HAVE_SYNTAXH]: Likewise.
  594. 2002-06-24 Pavel Roskin <proski@gnu.org>
  595. * edit.c (check_file_access): Return 1 on all errors, document
  596. this behavior. Set edit->delete_file to 1 for newly created
  597. files.
  598. (edit_open_file): Don't set edit->delete_file, it's now done in
  599. check_file_access().
  600. Reported by Saso <saso@bojler.dhs.org>
  601. 2002-05-13 Andrew V. Samoilov <kai@cmail.ru>
  602. * editcmd.c (edit_save_file): Call mc_chown() and mc_chmod()
  603. before mc_open() to prevent hangs over ftpfs.
  604. * edit.h: Remove open, close, write, read and mkdir definitions.
  605. * edit.c: Use mc_open, mc_close, mc_write, mc_read, mc_rename,
  606. mc_chmod and mc_chown. Don't cast (char *) to (unsigned long)
  607. in pointer arithmetics.
  608. * editcmd.c: Likewise.
  609. 2002-03-25 Andrew V. Samoilov <kai@cmail.ru>
  610. * syntax.c (edit_read_syntax_file): Use system wide Syntax
  611. Highlighting definitions' file if there is no users one.
  612. 2002-03-18 Pavel Roskin <proski@gnu.org>
  613. * edit.h: Use eregex.h, not regex.h.
  614. From Alexander Varakin <avarakin00@hotmail.com>
  615. 2002-02-27 Andrew V. Samoilov <kai@cmail.ru>
  616. * editcmd.c (edit_replace_cmd): Eliminate fin_string
  617. and use message() to fix possible buffer overflow.
  618. (edit_search_cmd): Likewise.
  619. 2002-02-18 Andrew V. Samoilov <kai@cmail.ru>
  620. * syntax.c (convert): Fix buffer overflow for ".*\" cases.
  621. 2002-01-22 Pavel Roskin <proski@gnu.org>
  622. * editdraw.c (edit_scroll_screen_over_cursor): Do nothing if the
  623. edit widget has zero width or height.
  624. 2002-01-21 Pavel Roskin <proski@gnu.org>
  625. * edit.c: Rename DELETE to DELCHAR to avoid macro redefinition
  626. on Win32.
  627. * edit.h: Likewise.
  628. 2002-01-21 Matthias Urban <murban@cs.uni-magdeburg.de>
  629. * edit.c: Add support for CK_Complete_Word event.
  630. * editcmddef.h: Likewise.
  631. * edit_key_translator.c (cooledit_key_map): Bind Alt-Tab to
  632. CK_Complete_Word.
  633. (emacs_key_map): Likewise.
  634. * editcmd.c: Implement word completion.
  635. 2002-01-21 Pavel Roskin <proski@gnu.org>
  636. * editmenu.c (CmdMenuEmacs): Add mail command without shortcut.
  637. Users of emacs keys should be able to send mail too.
  638. 2002-01-15 Andrew V. Samoilov <kai@cmail.ru>
  639. * syntax.c (syntax_g_free): New macro to release and NULLify
  640. glib allocated memory area(s).
  641. (strdup_convert): Rename to ...
  642. (convert): ... this. Don't strdup() passed string.
  643. (get_args): Use convert() instead of strdup_convert().
  644. (free_args): Make it do nothing macro.
  645. (open_include_file): Eliminate p array. Use glib function to
  646. construct error_file_name. Use PATH_SEP instead of '/';
  647. (edit_read_syntax_file): Use PATH_SEP_STR.
  648. (edit_load_syntax): Use syntax_g_free to release error_file_name.
  649. (edit_read_syntax_rules): Likewise.
  650. Eliminate c->single_char. It's only written but never read.
  651. * edit.h (struct context_rule): Comment out single_char field.
  652. It is written once but never read.
  653. * edit-widget.h: Use PATH_SEP_STR.
  654. 2001-12-22 Andrew V. Samoilov <kai@cmail.ru>
  655. * editcmd.c (edit_goto_cmd): Use g_free() to release f.
  656. (edit_save_file): Use PATH_SEP instead of '/'.
  657. Undefine "close" before closing file created by mc_mkstemps.
  658. Define close to mc_close() after it - temporary fix.
  659. (sprintf_p): Don't cast (char *) to (unsigned long).
  660. * syntax.c (read_one_line): Undo last patch - errno is a
  661. function on some systems. Check ferror() status before
  662. everything else if fgetc() returns EOF.
  663. Accept last line without trailing newline.
  664. (compare_word_to_right): Don't cast p and q to unsigned long.
  665. (apply_rules_going_right): Likewise.
  666. 2001-12-21 Pavel Roskin <proski@gnu.org>
  667. * edit.c (user_menu): Don't move the cursor before and after
  668. inserting the block.
  669. Reported by Matthias Urban <murban@cs.uni-magdeburg.de>
  670. * syntax.c (read_one_line): Clear errno before using it. Don't
  671. use the result of fgetc() if errno is EINTR.
  672. 2001-11-28 Andrew V. Samoilov <kai@cmail.ru>
  673. * syntax.c (apply_rules_going_right): Fix crash for lines like
  674. \s+ \n lightgray/13 red
  675. in Syntax file.
  676. (read_one_line): Use EOF instead of -1.
  677. (get_args): Fix buffer overflow for l without trailing
  678. whitespace(s).
  679. (break_a): New macro.
  680. (edit_read_syntax_rules): Use break_a to fix memory leaks.
  681. (edit_load_syntax): Eliminate s and use message to prevent
  682. buffer overflow.
  683. * editdraw.c (edit_render): Eliminate f. It's only written
  684. but never read.
  685. 2001-11-27 Andrew V. Samoilov <kai@cmail.ru>
  686. * editmenu.c (edit_wrap_cmd): Use g_free() on the result
  687. of input_dialog().
  688. 2001-11-22 Andrew V. Samoilov <kai@cmail.ru>
  689. * editcmd.c (edit_save_file): Use g_free() on the result of
  690. mc_mkstemps().
  691. (edit_replace_cmd): Fix rare memory leaks.
  692. 2001-11-19 Andrew V. Samoilov <kai@cmail.ru>
  693. * edit.c (edit_renew): Release dir after use.
  694. * editcmd.c (edit_replace_dialog): Eliminate tsearch_text,
  695. treplace_text and targ_order.
  696. (edit_replace_cmd): edit_replace_dialog gives g_malloced
  697. strings, so g_strdup/g_free have to be used. Accept only
  698. positive pattern number in Scanf search and replace.
  699. (edit_save_file): Enable safe save and backups on remote VFS.
  700. 2001-11-16 Andrew V. Samoilov <kai@cmail.ru>
  701. * edit_key_translator.c (cooledit_key_map):
  702. Add C-k, CK_Delete_To_Line_End.
  703. * edit.c (user_menu): Don't assign block_file twice.
  704. 2001-11-07 Andrew V. Samoilov <kai@cmail.ru>
  705. * edit.c (edit_reload): destroy_dlg g_free()s widget(s), so
  706. g_malloc/g_free have to be used.
  707. (edit_init): Ditto. Eliminate st.
  708. 2001-11-05 Andrew V. Samoilov <kai@cmail.ru>
  709. * edit.h (edit_execute_cmd): Declare it here.
  710. * edit.c: Remove edit_execute_cmd declaration.
  711. (edit_execute_cmd): Use edit_print_string instead of edit_printf.
  712. * editcmd.c: Remove edit_execute_cmd declaration.
  713. (edit_search_dialog): Eliminate tsearch_text.
  714. (edit_search_cmd): edit_search_dialog gives g_malloc()ed exp.
  715. Use g_strdup/g_free instead of strdup/free.
  716. (edit_mail_dialog): quick_dialog use g_strdup, so g_free
  717. must be used.
  718. (edit_load_cmd): input_dialog returns g_malloc(ed) string,
  719. so g_free has to be used.
  720. (edit_save_block_cmd): Likewise.
  721. (edit_insert_file_cmd): Likewise.
  722. (edit_sort_cmd): Likewise.
  723. (edit_save_as_cmd): Likewise. Memory leak fixed.
  724. * bookmark.c (book_mark_clear): Eliminate rend.
  725. It's only written but never read.
  726. (book_mark_flush): Likewise.
  727. (book_mark_inc): Likewise.
  728. (book_mark_dec): Likewise.
  729. 2001-10-23 Pavel Roskin <proski@gnu.org>
  730. * edit.c (user_menu): If the error file is missing, treat it as
  731. success. Truncate block file unconditionally.
  732. 2001-10-22 Pavel Roskin <proski@gnu.org>
  733. * edit.c: Stop using _EDIT_C definition. Move variable
  734. declarations from edit.h, make static or eliminate if possible.
  735. Report errors immediately.
  736. * edit.h: Likewise.
  737. * editwidget.c (edit): Don't report errors from edit_init(),
  738. they are reported in place.
  739. 2001-10-20 Pavel Roskin <proski@gnu.org>
  740. * editcmd.c (sprintf_p): Declare with the printf attribute.
  741. Make static.
  742. * edit.h: Declare edit_printf() with the printf attribute.
  743. 2001-10-18 Pavel Roskin <proski@gnu.org>
  744. * edit.c (check_file_access): Only allow to edit regular files.
  745. Use stat() before open() to prevent hangs on pipes, use fstat()
  746. afterwards if stat() was unsuccessful.
  747. 2001-09-17 Pavel Roskin <proski@gnu.org>
  748. * edit.h: Don't use macro `stat' - it's already a macro on
  749. Solaris 8 with large file support.
  750. * editcmd.c: Replace stat() with mc_stat().
  751. * edit.c: Likewise.
  752. 2001-09-11 Pavel Roskin <proski@gnu.org>
  753. * syntax.c (syntax_text): Remove, it's a separate file now.
  754. (upgrade_syntax_file): Remove.
  755. (edit_read_syntax_file): Use check_for_default().
  756. 2001-09-08 Pavel Roskin <proski@gnu.org>
  757. * edit.h: Remove some useless definitions.
  758. 2001-09-07 Pavel Roskin <proski@gnu.org>
  759. * Makefile.am: Don't define "MIDNIGHT" - it's unused now.
  760. * edit.c: Eliminate all code disabled for the text edition.
  761. * editcmddef.h: Likewise.
  762. * editmenu.c: Likewise.
  763. * editwidget.c: Likewise.
  764. * syntax.c: Likewise.
  765. * wordproc.c: Likewise.
  766. * edit-widget.h: Change ~/.cedit to ~/.mc/cedit to keep mcedit
  767. files separate from cooledit.
  768. * bookmark.c: Eliminate all code disabled for the text edition.
  769. * edit-widget.h: Likewise.
  770. * editcmd.c: Likewise.
  771. * editdraw.c: Likewise.
  772. * editoptions.c: Likewise.
  773. * edit.h: Eliminate all code disabled for the text edition.
  774. Reorder and simplify includes.
  775. * edit.c: Likewise.
  776. 2001-09-06 Pavel Roskin <proski@gnu.org>
  777. * syntax.c (syntax_text): Add PHP support from Cooledit.
  778. 2001-09-04 Pavel Roskin <proski@gnu.org>
  779. * Makefile.am (AM_CFLAGS): Remove CFLAGS, don't use substituted
  780. values directly.
  781. * syntax.c (syntax_text): Remove useless ']' in the Perl and
  782. Python rules. Change shell script rule to use more portable
  783. regular expression.
  784. * editcmd.c (edit_block_process_cmd): Prepend space to the
  785. command to avoid polluting bash history. Document arguments.
  786. Fix crash if block is 0 - not used currently.
  787. 2001-08-26 Pavel Roskin <proski@gnu.org>
  788. * Makefile.am: Don't install libedit.a.
  789. * Makefile.in: Converted to ...
  790. * Makefile.am: ... this.
  791. 2001-08-24 Pavel Roskin <proski@gnu.org>
  792. * Makefile.in (EDITSRC): Add headers.
  793. (CPPFLAGS): Remove reference to gtkedit.
  794. Copy all necessary files from gtkedit.
  795. * Makefile.in (EDITLINKS): Merge with EDITSRC, remove all
  796. references.
  797. 2001-08-24 Pavel Roskin <proski@gnu.org>
  798. * syntax.c (syntax_text): Fix recognizing pdksh and zsh scripts.
  799. 2001-08-23 Pavel Roskin <proski@gnu.org>
  800. * editcmd.c (edit_block_process_cmd): Use execute(), not
  801. my_system() to relieve interactive scripts, such as spell
  802. checker, from saving and restoring the terminal.
  803. 2001-08-19 Pavel Roskin <proski@gnu.org>
  804. * gtkedit.c: Include <sys/param.h> if present - it should always
  805. be included before <glib.h> to avoid redefining MIN and MAX.
  806. * editcmd.c [!MIDNIGHT]: Undefine B_ENTER and B_CANCEL before
  807. redefining them.
  808. * edit.h: Include <sys/param.h> if present. Include Gtk+
  809. headers as system headers.
  810. * gtkedit.c: Include Gtk+ headers as system headers.
  811. 2001-08-18 Pavel Roskin <proski@gnu.org>
  812. * syntax.c (syntax_text): Highlight *.pot as PO files.
  813. * edit.h [GTK]: Fix definition of edit_message_dialog().
  814. * gtkedit.c (gtk_edit_dialog_message): Use "OK" button, not
  815. "Cancel", for consistency with the text edition.
  816. 2001-08-17 Pavel Roskin <proski@gnu.org>
  817. * syntax.c (syntax_text): Add support for PO files.
  818. 2001-08-12 Pavel Roskin <proski@gnu.org>
  819. * edit.c: Handle CK_Shell.
  820. * editcmddef.h: Define CK_Shell.
  821. * editmenu.c (FileMenu): Remove C-o from the "Open file..."
  822. item.
  823. (FileMenuEmacs): Likewise.
  824. 2001-08-06 Andrew V. Samoilov <kai@cmail.ru>
  825. * editcmd.c (edit_replace_prompt): Fix menu location calculation.
  826. 2001-08-01 Pavel Roskin <proski@gnu.org>
  827. * editcmd.c (edit_save_file): Temporarily disable safe save
  828. and backups on remote VFS because it doesn't work. Use
  829. mc_mkstemps() instead of tempnam().
  830. 2001-07-29 Pavel Roskin <proski@gnu.org>
  831. * syntax.c (syntax_text): Add support for S-Lang.
  832. 2001-07-28 Pavel Roskin <proski@gnu.org>
  833. * editcmd.c (menu_save_mode_cmd): Resurrect i18n code lost in
  834. the last resync with Cooledit.
  835. Reported by David Martin <dmartina@excite.es>
  836. * gtkedit.c (gtk_edit_delete_cb): Handler for "delete_event".
  837. (edit): Connect it.
  838. 2001-07-27 Pavel Roskin <proski@gnu.org>
  839. * edit.c: Fix include.
  840. 2001-07-20 Pavel Roskin <proski@gnu.org>
  841. * syntax.c (open_include_file) [GTK]: Use mc_home instead of
  842. LIBDIR.
  843. 2001-07-19 Pavel Roskin <proski@gnu.org>
  844. * editcmd.c (edit_canonicalize_pathname): Don't ever use
  845. getwd(), use g_get_current_dir() instead.
  846. * editoptions.c (edit_options_dialog): Call edit_load_syntax()
  847. if user turned syntax highlighting off to unload the rules.
  848. 2001-07-17 Pavel Roskin <proski@gnu.org>
  849. * edit.h [MIDNIGHT]: Declare wedit.
  850. * editmenu.c: Remove wedit declaration.
  851. * editoptions.c (edit_options_dialog): Load syntax rules if user
  852. turned syntax highlighting on.
  853. * syntax.c (edit_load_syntax): Don't load rules if syntax
  854. highlighting is disabled.
  855. 2001-07-13 Pavel Roskin <proski@gnu.org>
  856. * editoptions.c (edit_options_dialog): Allow numbers for tab
  857. spacing. Reported by mharris@redhat.com.
  858. http://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=34852
  859. * editcmd.c (menu_save_mode_cmd): Give meaningful names to the
  860. input fields instead of "i" so that they have separate history.
  861. * editoptions.c (edit_options_dialog): Likewise.
  862. 2001-07-11 Pavel Roskin <proski@gnu.org>
  863. * editdraw.c (status_string): Use g_snprintf() instead of
  864. snprintf().
  865. From Libor Motyèka <l_motycka@ortex.cz>
  866. 2001-07-10 Pavel Roskin <proski@gnu.org>
  867. * gtkeditkey.c (edit_translate_key): When processing bindings
  868. with Alt check that Shift is not pressed - it's handled later.
  869. 2001-07-05 Pavel Roskin <proski@gnu.org>
  870. * editdraw.c: Comment fixes.
  871. 2001-06-26 Pavel Roskin <proski@gnu.org>
  872. * edit-widget.h (editor_widget): Rename `stat' to `stat1' to
  873. avoid problems on Solaris with 64-bit file access, when `stat'
  874. is a macro. All users adjusted.
  875. Reported by Maksym Polyakov <polyama@yahoo.com>.
  876. 2001-06-25 Pavel Roskin <proski@gnu.org>
  877. * gtkedit.c: Remove home_dir - it's declared in main.c.
  878. 2001-06-15 Pavel Roskin <proski@gnu.org>
  879. * editcmd.c (canonicalize_pathname) [GTK]: Rename to ...
  880. (edit_canonicalize_pathname): ... this to avoid namespace clash.
  881. * edit.h [MIDNIGHT]: Include "src/cmd.h" and "src/user.h".
  882. Remove declarations duplicating "src/user.h".
  883. [GTK]: Include "src/dialog.h" and "src/util.h".
  884. * editmenu.c (edit_wrap_cmd): Fix declaration.
  885. (edit_about_cmd): Likewise.
  886. * editwidget.c (get_key_state): Likewise.
  887. * editcmd.c (edit_quit_cmd): Don't use strcmp on the result of
  888. gtk_dialog_cauldron() since it's NULL if the dialog has been
  889. closed without using buttons.
  890. * edit.c (edit_execute_cmd): Put time format to a variable to
  891. avoid gcc warning about Y2K issues with %c in strftime().
  892. 2001-06-14 Pavel Roskin <proski@gnu.org>
  893. * edit.c: Declare cmd_F* static. Comment out cmd_F9.
  894. * edit.c: Use indented #error for compatibility with old C
  895. compilers.
  896. 2001-06-13 Pavel Roskin <proski@gnu.org>
  897. * edit.c (edit_execute_cmd) [GTK]: Disable user menu - it
  898. doesn't work.
  899. (user_menu) [GTK]: Disable.
  900. * gtkedit.c (tb_items): Use complete words. Disable pull-down
  901. menu.
  902. 2001-06-09 Pavel Roskin <proski@gnu.org>
  903. * editcmd.c (catstrs): Use interactive_display() without
  904. specifying the help file.
  905. From Andrew V. Samoilov.
  906. 2001-06-08 Andrew V. Samoilov <sav@bcs.zp.ua>
  907. * editcmd.c [HAVE_CHARSET]: Really include charset.h.
  908. * editmenu.c (edit_wrap_cmd): Memory leaking fixed.
  909. 2001-06-05 Pavel Roskin <proski@gnu.org>
  910. * edit.c [HAVE_CHARSET]: Include charsets.h and selcodepage.h.
  911. * editcmd.c [HAVE_CHARSET]: Add charset conversion support.
  912. * editdraw.c [HAVE_CHARSET]: Likewise.
  913. From Andrew V. Samoilov <sav@bcs.zp.ua>
  914. and Walery Studennikov <hqsoftware@mail.ru>.
  915. 2001-06-01 Pavel Roskin <proski@gnu.org>
  916. * gtkedit.h: Warning fix - use stricter declarations for
  917. destroy_me and destroy_me_user_data.
  918. 2001-05-31 Pavel Roskin <proski@gnu.org>
  919. * Makefile.in: Define HAVE_X and HAVE_GNOME, not just GTK -
  920. header files are using them.
  921. * editdraw.c (edit_render) [GTK]: Revert previous patch, it
  922. broke compilation.
  923. 2001-05-31 Andrew V. Samoilov <sav@bcs.zp.ua>
  924. * editdraw.c (edit_status): Use strcpy (s, ) instead of
  925. sprintf (s, "%s", ).
  926. (set_color) [MIDNIGHT]: Became a macro.
  927. (render_edit_text) [defined(MIDNIGHT) || defined(GTK)]: Warning fix.
  928. (edit_render) [GTK]: Eliminate win variable.
  929. (key_pending) [!GTK]: Warning fix.
  930. 2001-05-30 Pavel Roskin <proski@gnu.org>
  931. * editdraw.c (status_string): Use is_printable(). Declare
  932. static. Eliminate intermediate buffer. Use memset() for filling.
  933. Print byte as unsigned. Use C notation for hex numbers.
  934. * editdraw.c (status_string): Don't print non-printable chars.
  935. Better formatting. Print "<EOF>" at the end of file instead of
  936. -1. Use snprintf instead of sprintf.
  937. 2001-05-30 Andrew V. Samoilov <sav@bcs.zp.ua>
  938. * syntax.c (open_include_file) [MIDNIGHT]: Don't hardcode location
  939. of syntax file(s) with LIBDIR, use mc_home instead.
  940. From Ludovic Drolez <ludovic.drolez@freealter.com>.
  941. (syntax_text): Use perl.syntax to highlight perl modules (.pm).
  942. 2001-05-18 Pavel Roskin <proski@gnu.org>
  943. * editcmd.c (edit_replace_prompt): Warning fix.
  944. 2001-02-26 Pavel Roskin <proski@gnu.org>
  945. * editcmd.c (edit_delete_macro_cmd) [MIDNIGHT]: Don't use
  946. CK_Macro on the argument to edit_delete_macro().
  947. * edit.c (edit_init_file): Remove, it's useless. All the
  948. necessary files should be created when needed.
  949. * edit.h: Remove declaration of edit_init_file().
  950. 2000-11-01 Andrew V. Samoilov <sav@bcs.zp.ua>
  951. * editcmd.c (canonicalize_pathname) [GTK]: memory leaking fixed
  952. 2000-10-30 Pavel Roskin <proski@gnu.org>
  953. * editcmd.c (canonicalize_pathname) [GTK]: Make the argument
  954. constant.
  955. (edit_split_filename) [GTK]: Make the second argument constant
  956. to match the declaration.
  957. 2000-10-30 Andrew V. Samoilov <sav@bcs.zp.ua>
  958. * editcmd.c (edit_save_file): better error handling on writing
  959. (edit_sort_cmd): saved sort options proposed in dialog
  960. edit.h, editcmd.c: declaration for edit_save_block () added
  961. (edit_split_filename): f constified
  962. * edit.c (edit_init) [ENABLE_NLS]: option_whole_chars_search
  963. expanded by national letters using current locale on first call
  964. (edit_file_is_open) [MIDNIGHT]: all occurrences and related code
  965. are commented
  966. (edit_execute_cmd): typo in error message fixed
  967. 2000-09-30 Pavel Roskin <proski@gnu.org>
  968. * libgettext.h: Removed, shouldn't be here.
  969. * Makefile.in: Adjusted to remove libgettext.h
  970. 2000-09-15 Andrew V. Samoilov <sav@bcs.zp.ua>
  971. * editcmd.c (edit_delete_macro, edit_(load|save)_macro_cmd): don't
  972. translate keywords written to macro file or macro don't work, at least
  973. for Cyrillic. Made this as separate commit, so, if it seriously breaks
  974. compatibility it's easy to revert it.
  975. 2000-09-15 Andrew V. Samoilov <sav@bcs.zp.ua>
  976. * editcmd.c (edit_save_file): fopen()+fwrite()+fclose() replaced
  977. by open()+write()+close() to restore possibility to edit files
  978. over Midnight Commander's VFSes
  979. (edit_replace_cmd) [MIDNIGHT]: some more right algorithm to calculate
  980. menu coordinates used. I don't like if menu hides replaced text.
  981. (edit_goto_cmd): Memory leaking fixed when f is empty string
  982. 2000-09-07 Andrew V. Samoilov <sav@bcs.zp.ua>
  983. * edit.c (check_file_access) [MIDNIGHT,GTK]: error message localized;
  984. some cosmetics changes to avoid annoying warnings
  985. * editcmd.c (edit_save_file): pclose returns 0 on success,
  986. file fclose()d when fwrite fails
  987. (pipe_mail): malloc () + sprintf () replaced by g_strdup_printf ()
  988. * syntax.c (syntax_text): Makefile replaced by [Mm]akefile to cover
  989. makefile and GNUmakefile
  990. (upgrade_syntax_file): infinitive loop fixed when rule file
  991. is outdated but it cannot be unlinked/overwritten
  992. 2000-08-30 Pavel Roskin <proski@gnu.org>
  993. * editwidget.c [!MIDNIGHT]: include xdnd.h
  994. * Makefile.in: distribute xdnd.h
  995. 2000-08-18 Pavel Roskin <proski@gnu.org>
  996. * Makefile.in: adjusted list of distributed files.
  997. Added rule for rebuilding Makefile
  998. 2000-08-08 Pavel Roskin <proski@gnu.org>
  999. * gtkedit.c [GTK]: don't include mousemark.h
  1000. * gtkedit.h [GTK]: likewise
  1001. 2000-08-03 Pavel Roskin <proski@gnu.org>
  1002. * mousemark.c, mousemark.h: removed
  1003. * Makefile.in: don't distribute mousemark.h
  1004. * gtkedit.c [MIDNIGHT]: don't include mousemark.h
  1005. * gtkedit.h [MIDNIGHT]: likewise
  1006. 2000-07-20 Andrew V. Samoilov <sav@bcs.zp.ua>
  1007. * gtkedit/editcmd.c (edit_save_file): check fclose()s return value
  1008. to prevent loss of data
  1009. (edit_block_process_cmd): don't translate empty string
  1010. * gtkedit/edit.h (edit_get_write_filter, edit_write_stream,
  1011. edit_init_file): added declarations
  1012. * edit.c (edit_filters): constified
  1013. (edit_get_write_filter): filename constified
  1014. (user_menu): don't translate empty string
  1015. * syntax.c (syntax_text): constified
  1016. (upgrade_syntax_file): syntax_line constified, f closed after use