-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathChangeLog
2703 lines (1831 loc) · 93.2 KB
/
ChangeLog
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
Changelog, in reverse date order. Files are named yyyymmdd.
20211116:
Implement comment-line
C-u <N> M-; will comment the next N lines if N is positive else it
will the previous N lines
You need to set local variable comment-begin and (optionally)
commend-end
Example: C code may be commented as in C++ with // or with /* */
Set the local variables when defining a mode
see bl/dot.mg3 for examples
20201128:
Implement xterm mouse mode
Scroll up and down with wheel
Click to new cursor position
Make comment-begin and comment-end *local*
Remove default comment string from Python mode
Add bl directory in autoconf
20201010:
-- Fixed string variables
** Add 'comment-begin' 'comment-end' variables
** Implement 'comment-line' and bind it to Esc-;
Comments full line. To comment from point, use Ctrl-U Esc-;
Include '# ' as comment string for Python
From 110724, Bugfixes are listed with "--", most serious bugs first.
1921205:
Moving to autoconf tools
190113:
"duplicate-line": no key assignments, customise in your .mg3 file
"line-move-up": no key assigned, cusomise in .mg3 file
"line-move-down": no key assigned, cusomise in .mg3 file
180101:
Start my development branch in github
170403:
"shell-command". And its cousin "yank-process".
-- Fixed a bug where "backward-delete-char-untabify" didn't implement
overwrite mode.
-- Fixed a bug where invoking "with-message" non-interactively would
show an extra error message if the controlled command gave an
error.
-- Fixed a bug where "scroll-up", "scroll-down", "move-to-window-
line", "move-to-window-line-top-bottom", "shrink-window-if-larger-
than-buffer" wouldn't work in a script when the window framing had
already been changed in the script.
-- Fixed bugs in macro recording:
* Forbidden "with-message" from being recorded because it won't do
anything.
* Memory running out could be interpreted as a default response on
input from the echo line.
* "blink-and-insert", "clike-blink-and-insert", "c-handle-special-
char" and "c-handle-special-brace" recorded nonsense data when
used with repeat counts.
-- Fixed a bug where "quit-window" avoided switching to an existing
"*scratch*" buffer.
- There is now a version of "shell-command" from Emacs. See
README.reference.
- Sequential interactive invocations of "backward-delete-char-
untabify" now inhibit an undo boundary.
- When USER_MACROS is defined, "describe-bindings" with an argument
now lists only the keys bound to macros.
- Clarified the text on "kill-whole-lines" in README.reference.
- Now "everything else" can be completed from an empty input on the
echo line. Everything else shares a single line of recall.
- Increased input buffer for "insert" to the max length of a filename.
170316:
No new version, because of no changes. There will probably be more
irregular versions in the future.
170216:
-- Fixed a bug where you could get stuck in the "help-help" command if
you couldn't find a defined key in the "help" keymap. Now ^G will
always get you out.
-- In Clike, made Option 1024 check that C labels are enabled as the
documentation says.
- Cleaned up a lot provisions for extensions in keymap.c. They were
never used.
- Brought back undo to the non-Emacs section in README.reference.
- Removed empty keymap.h that wasn't used.
170118:
-- Fixed a bug where "\^c" would lead to unexpected results if c >
127. Now this is an error and the command is silently ignored.
- Added info about the "install" Makefile entry to the README.
- Clike "c#" mode now supports C# literal strings delimited by @"...".
The literal strings can be multi-line.
161217:
-- Fixed a bug where empty answers to a "yes"/"no" question would be
recorded in a keyboard macro, and would be wrongly supplied to the
following commands during macro execution if you eventually
answered "yes".
- Documented in README.misc that an argument to "redraw-display" shows
the display size rather than redrawing.
- Added a command "with-key". It can be used to debug a command or
macro assigned to a key.
- The Makefile now has an "install" target for Linux/BSD/OSX. Written
by Pedro A. Aranda.
- Broken out Undo to its own section in README.reference.
- A feature of undo: a repeat count of 0 counts as infinite.
161117:
-- Fixed a bug in Clike Swift mode where a "guard" statement with the
"else" first on the next line would throw off the following
formatting by a tab.
-- Fixed a bug in "kill-paragraph" where invoking it in an empty,
newly made buffer would give an error message about a lost mark.
- "undo", "undo-only" and "redo" now accept repeat counts.
161017:
Small fixes.
-- Fixed a bug where "clike-insert" wouldn't work correctly if
recorded in a keyboard macro with a repeat count of 0.
- Filled in "(void)" for a number of function declarations.
- Internal routine "position()" now sets the window flags a bit more
efficiently.
- Cleaned up code in "ffgetline()".
- The calls to wcwidth() and wcswidth() have their parameters cast so
that it should work correctly on all platforms even without
prototypes. This was done already in the previous version.
- Functions "blink-and-insert", "call-last-kbd-macro" and "insert-
with-wrap" should now work correctly with all kinds of repeat
counts.
160917:
-- Fixed a crash bug after starting mg and "^X b RET ^X k RET". From
OpenBSD.
-- Fixed a bug in the definition of EFNOSTRICTCR that happened to
work.
- Rewritten code for "switch-to-buffer" and "switch-to-buffer-other-
window".
- The "\u" escape can now have its value within "{}", like "\u{abc}3".
- The #defines KILLQUICKLY, SHIFTREGION and JOINLINEFORWARD have been
removed from the source. They were already obligatory.
- Adjusted "clike-align-after-paren" so that it says "No '(' or '['"
if not found.
- Added a '%K' keyname output format for internal routines
"ewprintf()" and "ewprintfc()".
- The "clike-*" functions that accept a repeat count now consistently
do nothing and return FALSE with a negative repeat count and do
nothing and return TRUE with a count of zero.
- Removed the #define EFCONTINUE and the code for it because it was
never used.
- _XOPEN_SOURCE is now defined also on Cygwin so that it will compile
at highest warning level without warning that wcwidth() and
wcswidth() don't have prototypes.
160817:
-- Fixed a bug where a newly created backup or copy of a file with
restrictive permissions could become accessible to others by
getting the default permissions. Now such a file gets the same
permissions as the original minus setuid, setgid, and sticky bits.
-- Somehow the fix for showing messages from .mg-$TERM didn't get in.
But now it's there.
- Speeded up wildcard matching of "*" 2-10 times.
- Clike now recognizes "guard", "catch" and "} catch" as keywords for
Swift when "clike-lang" is 6, and "foreach" for C# when "clike-lang"
is 4.
- If USER_MACROS is defined, the named macros are kept sorted and
looked up by binary search.
160717:
-- Fixed a bug in startup where errors while executing .mg-$TERM
weren't shown on the screen.
-- Fixed a bug where if SLOW was defined, the "slow-mode" command
didn't work if the argument was parsed as a prefix argument.
- "query-replace" now implements the ',' command from Emacs, replacing
and updating the screen before moving.
- When UCSNAMES is defined, changed the display of screen width of a
codepoint from "(width)" to "[width]". The width is shown as 0 for
end-of-line and as computed width for a hard tab.
- Parsing the first argument to a function when it is numeric as a
prefix argument is a questionable practice from original Mg.
However, it's weird to have to write "with-message 1 what-cursor-
position". So now you can also write "with-message what-cursor-
position 1".
160617:
-- Fixed "kill-region" and "copy-region-as-kill" to be compatible with
GNU Emacs regarding the direction of appending/prepending to the
killbuffer. GNU Emacs considers a region to be in the forward
direction if dot is at the end of it.
-- Fixed a potential problem where an initially empty killbuffer with
a length of 0 would be referred to through a NULL.
-- Fixed a bug where "forward-paragraph", "backward-paragraph" and
"kill-paragraph" with a repeat count of 0 would move the cursor
(and kill to there).
- "yank" with a repeat count has been changed to put the region around
all inserted copies. This seems more practical.
- "query-replace" now remembers the replacement string so that it can
be filled in with TAB.
- An ambiguous completion that is in a different case will now be
refreshed.
- Completion error messages now also work when emulating a slow
terminal.
160609:
-- Fixed a bug in "kill-line" where it could add a newline at the end
of a buffer only to immediately remove it.
-- Fixed a possible overflow in the column count in internal
routine "getindent()" when the column wasn't asked for.
- If a region is too big for undo, the undo list is now cleared since
such a region is necessarily bigger than "undo-limit". There is no
longer an error.
- When the "kill-whole-lines" variable is set, made "kill-whole-line"
work the same backward as forward, with the cursor ending up
in the same column.
- Speeded up killing large regions a bit.
160511:
-- Fixed two bugs where you, in extreme circumstances, could get an
overflow in the column count from output in the echo line.
-- Fixed a bug where the screen would be repainted twice after
resuming from suspension.
- Now explicitly initializing the screen buffer pointer to 0.
160410:
-- Fixed the compile problem on FreeBSD.
- A new approach to portability: the only system-specific definition
is now _XOPEN_SOURCE on Linux.
160323:
- Changed the order of included system headers because for some reason
it didn't work on FreeBSD.
- Marks are now cleared in all windows showing a system buffer that is
emptied.
160223:
-- Fixed a bug where a newline was automatically added to the end of a
buffer by "next-line", "end-of-buffer", "mark-whole-buffer",
"forward-paragraph" or "kill-line" but not recorded by undo. It
would leave an extra newline at the end of the buffer after undo.
-- Fixed a bug in "dired-jump" when "compare-fold-file" is set where
it wouldn't find the filename of the current buffer in the Dired
listing if the filename in the listing was in a different case.
160216:
-- Fixed a bug that could happen if HOME is "/". "//" at the beginning
of a filename of a startup script could be misinterpreted.
- When UCSNAMES is defined, the change made in version 160116 is
undone.
- A change was made in undo.c to not assume MAXINT is more than 24
bits.
- "beginning-of-visual-line" and "end-of-visual-line" now accept
repeat counts.
160116:
- When UCSNAMES is defined, "list-unicode" now only matches on the
character name, by default.
- Effectivized undo slightly: only reset modified flag and update mode
lines once per 'undo' or 'redo'.
151216:
- The editor is now more robust against internal byte position error.
Only if there is a serious buffer format error will the editor quit.
- When UCSNAMES is defined, show "<block name>" if the character name
isn't defined, and "(undefined)" if the codepoint isn't defined.
151116:
-- Fixed a bug in "transpose-paragraphs" which would not update the
dot byte position in another window if the current buffer was
visible in that window and if the dot in that window was within the
second paragraph.
- Removed some obsolete tests in undo.c.
151108:
-- Fixed a bug where "revert-buffer" and "revert-buffer-forget" would
reset the position to the beginning of the buffer if the new
content was shorter than the old one, and the original position was
beyond the end of the new content.
-- Fixed a bug in Clike where a tab level increase from a label in the
previous non-blank line wasn't added to an increase from other
content in that line.
- Speeded up file I/O: reads are speeded up 20% (more for long lines)
by searching more intelligently for the LF. Writes are speeded up 2-
3 times by using the same local buffering as for reads.
- In Clike, block comment/multiline raw string recognition has been
changed to recognize strings, character constants and end-of-line
comments continued with "\" from the previous line.
- Now compatible with Emacs, "revert-buffer" doesn't refuse to revert
when the buffer is unmodified.
151008:
-- Fixed a bug with undo recording in "newline-classic".
-- Fixed a bug in "delete-horizontal-space" which would return an
error code if the current point was at a combining character at the
beginning of a line.
-- Fixed a bug in "shrink-window-if-larger-than-buffer" where the
whole text would not be shown if the current window were the bottom
one.
- There is now a constant maintainance of the byte position of dot, as
well as the byte size of a buffer.
* Performance of undo is now independent of buffer size and position
in it.
* The performance of "tab-region-left", "tab-region-right" and
"clike-indent-region" are now independent of position in the
buffer.
- Added a command "revert-buffer-forget" that is like "revert-buffer",
except it allows reverting an unmodified buffer and it clears the
undo list.
In other words, when reverting a buffer the editing session is
wholly reset.
150908:
- Performance of undo has been improved for big buffers: previously
operations could take a very long time for big regions or large
repeat counts.
- Undo now always restores the buffer-modified flag.
- "save-buffer" now always saves to the file, even when the modified-
flag isn't set.
- Added an "emacs-compat" bit to have "save-buffer" work exactly like
in Emacs.
150803:
- There is now a position-cache to speed up editing a bit when you are
more than a million lines from the beginning of the buffer and undo
is enabled.
150703:
-- Fixed bugs in "join-line", "join-line-forward", "transpose-words",
"prefix-region", "tab-region-left", "tab-region-right", where the
modified flag wasn't reset after undo.
-- Fixed a bug when running "save-buffers-kill-emacs" or "save-and-
exit" in a script, where they would exit even if there was a
problem with saving a file.
- Fixed an editing mistake in the code for "transpose-paragraphs" that
mixed declarations with statements.
- There is a new variable "bell-type" for the type of bell. 0 = off, 1
= audible bell, 2 = visible bell. Default is 1.
- Added a nicer message if mg is started and standard input is not a
tty.
- When used interactively, "save-buffers-kill-emacs" with an argument
now saves all files before exiting without questions, like GNU
Emacs.
There is a warning that you can turn off because the previous
behavior was to exit without saving.
- There is a new variable "emacs-compat" with control bits for
behaving more like GNU Emacs.
150603:
-- Fixed a bug in C-like, in modes with keywords without parentheses,
that wasn't fixed right in the previous version.
-- Fixed a bug where the undo list could come out of sync with the
buffer if you ran out of memory in "yank".
-- Fixed a bug in "transpose-paragraphs" where if the final undo entry
failed, the screen would not be updated.
-- Fixed a small bug in "revert-buffer" where a buffer bigger than
MAXINT would still give an error when undo was off.
- "list-undo" will now truncate very long undo records to 16 MB
instead of trying to list the whole thing.
150519:
An undo is implemented.
-- Fixed a bug in "delete-char", "delete-backward-char" where you
could theoretically overflow an integer.
-- Fixed a bug in C-like, where if brace matching would hit the
beginning of the buffer, the previous statement was returned,
rather than the beginning of the buffer.
-- Fixed a bug in C-like, in modes with keywords without parentheses,
where the column of a statement in column 0, or of the beginning of
the buffer, would be returned as the column of the previous
statement, rather than 0.
- Undo is implemented. It is a linear undo like in a GUI. The command
"undo" works mostly like in Emacs, and is assigned to "^X u" and
"^_". See README.undo.
- Created a command alias "sv" for "set-variable".
150427:
-- Fixed a bug when recording a keyboard macro where entering a self-
inserting character with a repeat count of 1 would record a
spurious prefix argument of 1.
-- Fixed bugs in "eval-buffer" and "set-default-mode" where the
parameter was declared too short.
-- Fixed a cosmetic bug when a buffer name got truncated in the
modeline before a double-width character.
- "insert-char" is now an alias for "ucs-insert" to be compatible with
Emacs.
- The declaration of the internal routine "emessage()" has been
changed to make it easier to use.
- Updated README.reference with the defaults on "termdoescombine",
"termdoeswide" and "termdoesonlybmp".
150328:
- C-like now handles labels. A C-style label is considered to be an
identifier at the beginning of the line followed by a ":" but not by
"::". It has its indent decreased by one tab. If the previous
statement has a label, the indent is increased with one tab.
Should a line consist of nothing but a label it is ignored when
scanning for non-blank lines.
There is no longer any reaction to a line merely ending with ':'.
There is a new "clike-options" bit for C-style labels.
Some languages (and builtin modes) have C-style labels, like C/C++,
C# and Go. Some do not, like Perl, Java, JavaScript, and Swift.
There is also a compatibility bit if you want to turn on the old
behavior.
- For command lists, error checking and message level are now
separated. User macros execute like scripts: execution is terminated
on error unless you use "ignore-errors", and messages are not shown
unless you use "with-message". This gives a cleaner execution,
especially of user macros assigned to keys.
Auto-executed statements and mode-initialization commands execute as
before and ignore errors by default.
- Like in GNU Emacs, "eval-current-buffer" is now an alias for the
command "eval-buffer", and the command takes an optional parameter
in a script, which is the name of the buffer to execute.
- "insert-buffer" now displays an error message when the buffer could
not be found.
150228:
-- Fixed a bug in GNU or Whitesmith style in C-like, where C++ access
specifiers were not withdrawn an extra tab after a block-ending
'}'. The same thing would happen to case statements if brace
matching was not turned on.
- Comment parsing in C-like should be more accurate and 2-4 times
faster.
- There is a new function "clike-indent-region" that re-indents the
lines in the region. It's bound to "ESC ^\" like "indent-region" in
Emacs.
- There is a new function "clike-indent-next" that re-indents the
current line and steps to the next line. It's not bound to a key.
- There is a new "-l loadfile" command line option. It loads a file
after program startup.
- There is a new "-e commands" command line option. It executes a list
of commands after program startup. If both "-l" and "-e" are
specified, "-e" executes last.
- There is a new "-L loadfile" option that loads a script immediately
after startup files. The execution of startup files has been
revised with a global fallback. See README.misc.
- The GOTOLINE #defines have been cleansed from the source.
- "auto-execute" patterns now support alternatives "{pat1,pat2,...}"
like for example in Bash. It is, like in Bash, a textual
replacement, and on any error the string is used directly as a
pattern.
- Cleaned up the source dealing with the SLOW option a bit.
- A lone "+" argument as "mg + file" or "mg file +" now goes to the
end of file.
- Stray "test.c" removed.
150129:
-- Fixed an undefined behavior where memcpy() was called with a NULL
pointer in display.c.
-- Fixed a problem in main.c where "thisflag" and "lastflag" weren't
explicitly set to 0 when commands were first executed.
-- Fixed a potential problem in the scripts in sys/unix where GNU grep
could interpret a file as binary if it contained characters that
were not in the locale.
- There has been a change in "auto-execute" so that only the first set
of matching patterns/tests have their commands executed.
- "clike-style" has a new bit, bit 4, indicating that multi-line "if",
"while", "for" and "switch" expressions should be indented by two
tabs.
141227:
-- Fixed a bug in "what-cursor-position" where a line-end could be
displayed as a combined character due to an uninitialized variable.
-- Fixed a bug in "what-cursor-position", "recenter" and "recenter-
top-bottom" where a numeric argument in a script was interpreted as
universal rather than numeric.
-- Fixed a wrong listing of dired mode in README.bindings.
- "what-cursor-position" now accepts a numeric argument of 1-5 as a
substitute for the same number of prefixed ^U.
- Made screen update more robust if the screen is resized while being
updated.
141130:
-- Fixed two bugs dealing with block comment parsing in Clike: end-of-
line comments could hide, through caching, what would later be
changed by a prior '`' or "/*", and the line after a continued line
should not be cached.
-- Fixed two bugs in "ucs-insert": it now interprets "#b" as binary,
and radix notation is "#xxryyyy", not "#xx#yyyy".
- Made "clike-blink-and-insert" re-indent if entered on a blank line.
Needed for the "import" statement in Go.
141031:
-- Fixed a bug when inputting filenames on Cygwin where a DOS pathname
with '\' delimiters couldn't be completed.
- Arguments for "what-cursor-position" are interpreted differently so
that a single ^U always shows the Unicode codepoint(s) for the
current character in hex.
- In Clike there is a new "go" mode for Google's Go language. It's
very similar to Swift mode.
140930:
- Changes to Clike:
* Swift mode is official. There are two new option bits in "clike-
options", for nested comments, and keywords without parentheses.
* "clike-style" is now a set of bits; bit 1 is as before for half-
size tabs, bit 2 is for indented case statements in a switch.
* "clike-lang" number 6 is now Swift.
* High bit checked of characters to not confuse the beginning of
multinational identifiers with keywords.
* Whitespace is not fully Swift, but now includes Form Feed in
addition to space and tab.
* Statements with a negative brace level will be recognized even if
the '{' is not last on the line. Necessary for trailing closures.
* "clike-align-after-paren" now aligns after both '(' and '['.
* A fix for trailing closures in Swift lets you enter things in
Horstmann or Pico style in C.
- Reinstated the "mark-paragraph" and "transpose-paragraphs" commands
because what the heck.
- You can now bind macros to keys. Unnamed macros can also be bound to
keys by "global-set-key", "local-set-key", and "define-key".
140831:
- Advanced Swift mode has been removed. It has serious problems with
some styles of Swift. By #defining LANGMODE_SWIFT you now get the
simple Swift mode.
The compile option ALL no longer sets LANGMODE_SWIFT.
140731:
-- Fixed a bug where mode initialization commands wouldn't be run
unless LANGMODE_CLIKE or USER_MODES were defined.
-- Fixed a bug in Clike introduced in the previous version where if
the tabsize was 1 and half-tab size was used you got a divide-by-
zero.
- Messages are now not hidden when executing named macros
interactively. It makes the execution similar to interactive
execution of either a keyboard macro or of "eval-current-buffer".
140726:
-- Fixed a bug in Clike where multiple half-tab levels didn't work.
-- Fixed a bug in Swift where a multiline if-expression followed by a
"{".."}" block on one line wouldn't reset the column.
-- Fixed a bug in Clike where if a line with a preprocessor command in
column 0 was inside a block comment and the line ended with ')',
the block comment wouldn't be detected after this line.
- Changes to Swift mode:
* Dropped the half-tab feature because it combines badly with "{}"
blocks within "[]" blocks which aren't that unusual in Swift.
Instead you can set "swift-style" to 2 for "case"-statements with
a tab indent (this seems to be Apple's preferred style).
* Lines starting with '#' are now ignored when scanning for non-
blank lines. They are for conditional compilation.
* The Swift definition of whitespace is used at crucial points
(Null, Tab, Line Feed, Vertical Tab, Form Feed, (lone) Carriage
Return, Space).
* Testing for keywords like "if" is now done so that they can't be
confused with the start of multilingual identifiers.
* Combinations of "case" statements and braces should now act
consistently.
* More documentation in README.swift-mode.
- In Swift and C-like, scanning for a non-blank line was stopped after
100 lines, including block comments. That was probably too little.
Changed to 10000 lines.
- Clike now contains a simple "swift" mode. If you #define
LANGMODE_SWIFT you get instead the specially-designed one.
- The "transpose-paragraphs" and "mark-paragraph" commands have been
removed since they are not essential. The definition of a paragraph
is reset as it was before.
140628:
-- Fixed a bug in "fill-paragraph" where doing a manual fill with
whitespace after the cursor could lead to access to freed memory.
-- Fixed a bug in clike where "clike-blink-and-insert" would miss the
beginning or the end of a block comment (!).
-- Fixed a bug that was introduced when trying to optimize for a
single-line screen cache. This should solve nagging problems of
updating several windows on the same buffer.
-- Fixed a bug where it wasn't checked up front in "fill-paragraph"
that the buffer was read-only. It could modify the buffer in
certain cases similar to a previous bug.
-- Fixed a bug where you would get a surprising result of "clike-
newline-and-indent" if the text after the cursor had special
behavior at the beginning of the line.
- There are two new commands for selecting a region, "mark-whole-
buffer" bound to "^X h", and "mark-paragraph", bound to "ESC h",
like in Emacs.
- A new command "transpose-paragraphs" has been added like in Emacs.
- The definition of a paragraph has been changed to be like how GNU
Emacs behaves when paragraphs are separated by empty lines.
- "backward-paragraph" now puts you on the line before the first line
of the paragraph.
- Emacs has a command "kill-this-buffer" for killing the current
buffer without asking for a name, and mg has it now. It lacks the
extra universal-argument feature of "kill-buffer-quickly".
- "move-to-window-line-top-bottom" has been bound to "ESC r" like in
Emacs ("search-backward" is available on "^R RET").
- Documented "ignore-errors" and "nil" in README.reference.
- In Clike "perl" mode "{" is no longer bound because braces are
mandatory and parentheses are not parsed, and it makes it easier to
adjust the indent manually.
- There is an optional "swift" mode for Apple's Swift language. Enable
by #defining LANGMODE_SWIFT and see README.swift-mode.
140528:
-- Fixed a bug where restoring cursor position could put you at the
internal end-of-buffer line, if you had added only one line and
were at the last line before restoring.
-- "clike-align-after" now checks for an invalid codepoint.
-- Fixed a bug in "fill-paragraph" where if the paragraph was a single
line, and if the only change was replacement of tabs with spaces,
the buffer would not be marked as modified.
- "eval-expression" now accepts a repeat count, similarly to "execute-
extended-command". It makes it easier to repeat command sequences.
- "auto-execute" and "auto-execute-list" now interpret "~" at the
start of a pattern as the name of a home directory in the usual way.
140514:
-- Fixed a bug where the undocumented "insert-unicode-hex" and
"insert-8bit-hex" no longer interpreted their argument in hex.
- Changed "query-replace" so that an uppercase single-character word
is considered uppercase and not titlecase.
- "revert-file" and "list-macro" have now been hidden from "apropos"
but other function name aliases can now be completed.
140509:
-- Fixed a bug where a local "make-backup" variable was checked for
the current buffer rather than a general buffer.
-- Fixed a possible integer overflow of parenthesis depth in "blink-
and-insert" and "clike-blink-and-insert" with extremely large
buffers.
-- Fixed a bug in clike where a block comment ending at the same line
as another began with no content ("..*/ /*..") would be
misinterpreted.
-- Fixed a theoretical overflow in block comment caching in clike
after 128 million edits.
-- Made it possible to enter abbreviated charset names like in the
modeline interactively.
- Made sure that clike can't mess with line flags in system buffers.
- Made an option in clike to recognize C++-style "public:", "private:"
and "protected:" and enabled it when "clike-lang" is 1.
- On further thought, having a local "modeline-show" variable and an
option to turn off showing "-bom" are bad ideas. They are removed.
- Two new commands from Emacs, "move-to-window-line" and "move-to-
window-line-top-bottom", are added. However "ESC r" is still
assigned to "search-backward", unlike in Emacs.
140402:
-- Fixed a bug in clike where block comments not having "*/" at end of
line would get the parser confused. Such comments should now work.
-- Fixed a bug in clike where regular expressions would mess up
parsing in "perl" and "javascript" modes. Solved for now by making
"perl" mode identical to basic "clike", and "javascript" mode
having only basic "clike" + "if" and "case" heuristics.
- Made the definition of a MODE be an INT and moved the definition to
"def.h".
- Changes to python mode:
* Removed "python-tab" and "python-delete-backward-char" commands.
* Removed the "python-indent-offset" variable. It gives no error
when set.
* Set init command of python mode to "local-set-tabs 4 1 1".
* Extra indent on the next line now triggers on the last nonblank
character being ':', not only the last character.
The behaviour is the same except that "tabs" are now only spaces.
- Added an alias "lv" meaning "local-set-variable".
- Added a bit to the variable "fill-options" to recognize numbered
itemized lists. See README.reference.
- Added a variable "clike-style" to clike, as an overall style number.
So far, 0 = default, 1 = BSD.
- Added two commands not from Emacs: "tab-region-left" and "tab-
region-right" shift the region one tab stop to the left or right.
- Added another command not from Emacs: "kill-buffer-quickly" kills a
buffer without asking for a name. With a universal argument, the
buffer is killed without question even if it's modified.
- Simplified the display of "what-cursor-position" with an argument
when UCSNAMES is defined. There is no longer a separate format for a
display wider than 80.
140304:
-- Mistakenly listed "list-macro" twice (once as an alias) when
USER_MODES was not defined.
-- Fixed a compilation problem on OS X by renaming a function.
-- Fixed bugs in clike:
* An end of a block comment in column 0 would be missed.
* If there was content on the same line before the beginning of a
block comment, the last character of it wouldn't be seen.
* Keys like "}" no longer re-indent in a block comment when entered
on a blank line. Previously only the formatting rules were turned
off, not the re-indenting.
* Corrected the help text on brace matching.
140206:
- Improved clike C parsing:
* The statement after a braceless "if", "for" etc. now has to end
with a ";" to be recognized. Otherwise too many contructs get
wrong.
* Before and after a block-ending "}" and after the end of multiline
assignments, a search for the "{" of the enclosing block is done,
or for a "case"-statement, used for setting the indent in those
cases.
* Block comments are recognized separatedly. C mode is not active
within them.
* A "//" comment in column 0 stays put and is not changed by re-
indenting.
* Modes for Java, C# and JavaScript are included.
* A new function "clike-blink-and-insert", bound to ")", does what
"blink-and-insert" does but respects comments and strings.
* Case statements line up under each other, in case you used a
custom indent.
140122:
C-like and user-defined modes.
-- It used to be possible to assign some named keymaps to keys. As far
as I know, it has never been used and it is incredibly dangerous:
it can create circular key definitions that will blow up "describe-
bindings" and the copying of a keymap. It has been disabled.
-- You couldn't enter function name aliases or obsolete function names
interactively. You can now, if you spell them out.
-- Fixed a bug where the most negative number could get garbled when
shown in the echo line.
- Documented the "list-keymaps" and "list-kbd-macro" commands.
- Stray "test.c" removed.
- (Optional) "search-all-forward" and "search-all-backward" no longer
look for the special "MGSEARCHALL" environment variable. Use the
"-p" switch.
- A (temporary) "check-for-python" command which was there in the
snapshots is no longer there. Use "shebang".
- The compilation option ALL now turns on all options except NO_TERMH.
- There is an optional set of modes for C-like languages. Enable by
#defining LANGMODE_CLIKE, and see README.clike-mode. Included are
modes for a basic C-like language, three different styles of C, and
Perl.
- There is an option for user-defined modes. Enable by #defining
USER_MODES, and see README.user_modes.
- There is an option to create named macros. Enable by #defining
USER_MACROS, and see README.user_macros.
- Regularized declarations so that predicates are "int". Status