63 Commits

Author SHA1 Message Date
Leo Gaskin
c9ea562bd5 Fix regression with determining the current sgml context
This problem seems to have been introduced in commit aae47ae by adding
"100" as an argument to "looking-back" instead of the correct "1".
2022-12-23 16:22:43 +01:00
Seungheon Oh
1e4842d129 Fix mc/mark-all-in-region leaving fake cursor.
Previously this function left a remain of fake function if there was
only one matching string in selected region.
2022-08-21 11:32:12 +02:00
Jason May
aae47aebc0 eliminate byte-compilation warnings
- long docstrings
- "defcustom fails to specify type" - use '(sexp)
- keyword arguments in define-minor-mode
- deprecations
2022-03-28 19:24:00 +02:00
Johannes Lippmann
b139bb6b30 introduce function mc/disable-multiple-cursors-mode 2021-11-12 23:23:42 +01:00
Johannes Lippmann
4975afedb3 Run hook when mc is disabled 2021-11-12 23:23:42 +01:00
Masahiro Nakamura
6a04a147ce Fix docstrings
Fix wrong docstrings of mc/mark-next-word-like-this and
mc/mark-next-symbol-like-this.
2020-10-18 07:37:54 +02:00
Renato Ferreira
b39e9631d6 Faster line-number-at-pos calculation 2019-08-18 13:44:55 -03:00
Matus Goljer
6a7c3c0853 Fix whitespace 2018-09-13 14:37:07 +02:00
Dror Levin
038815b2b9
Make "no more matches found." user-error, fix #218 2018-06-06 22:33:08 +03:00
Josh Hunsaker
7cb18b8aec Fix bug in mc/mark-all-in-region-regexp. Fixes #293 2017-06-29 16:30:04 -07:00
Andrea Orru
21e48250ec mc/mark-previous-like-this-word/symbol. 2016-07-17 02:56:48 +02:00
Jules Tamagnan
a9daac129a Add/fix docstring to functions. fix #161
functions documented added:
 - mc/mark-next-word-like-this,
 - mc/mark-next-symbol-like-this
 - mc/mark-previous-word-like-this
 - mc/mark-previous-symbol-like-this

functions documented fixed:
 - mc/mark-previous-like-this
2016-05-20 08:51:09 -04:00
Bozhidar Batsov
741eec6766 Update some copyright years 2016-05-19 20:29:36 -07:00
Josh Hunsaker
9f4cdd0907 Modified mc/mark-lines to allow skipping 2016-04-29 12:22:07 -07:00
Steve Purcell
4bf9860bcc Use cl-lib instead of shimming, which breaks in older emacsen
Aliasing built-in (cl) functions to cl-lib versions when they are
available in older Emacs versions can seemingly lead to problems
including infinite loops during byte compilation.

Since cl-lib works with all Emacs versions supported by
multiple-cursors, just depend on this directly instead.

This commit makes the necessary changes, both to code, documentation and
package metadata.
2016-04-25 11:19:06 +12:00
Nicolas Richard
06a2985db0 * mc-mark-more.el (mc/mark-all-in-region-regexp): Don't infloop when regexp matches empty string 2016-03-04 13:01:29 +01:00
Ingo Lohmar
e17851efd3 Fix click-toggling and make it robust (address all PR #239 comments)
- use marker-position for cursor overlay's point
- new helper function finds fake cursor with its actual *point* where we
  want it
- this also eliminates any need for additional require statements
2016-03-02 21:28:45 +01:00
Ingo Lohmar
40eb74e3e4 Extend mc/add-cursor-on-click to toggle fake cursors
- rename function accordingly and add alias
2016-03-01 20:31:47 +01:00
Jules Tamagnan
8703b19872 Add mark-next-like-this-symbol function
* README.md: Update readme to include mark-next-like-this symbol
 * features/step-definitions/multiple-cursors-steps.el: Add phrase for
   mark-next-like-this-symbol
 * features/support/env.el: Add keyboard shortcut for
   mark-next-like-this-symbol and fix shortcut for
   mark-next-like-this-word
 * mc-mark-more.el: Add mc/mark-next-like-this-symbol function
 * multiple-cursors-core.el: Add mc/mark-next-like-this-symbol to
   functions to run only once
 * multiple-cursors.el: Add to readme section.
2015-12-04 16:56:50 -05:00
Jules Tamagnan
bbbe90d274 Minor changes mark-next-like-this-word and readme
* README.md: Adjust read to no longer recommend extend region if user
   is using mark-next-like-this-word
 * mc-mark-more.el: mark-next-like-this-word makrs whole word and not
   only from point to the end of the word
2015-12-04 16:28:29 -05:00
Jules Tamagnan
36b7025a35 Add alternative to mc/mark-next-like-this
* README.md: Add mc/mark-next-like-this-word tidbits to readme.
 * features/step-definitions/multiple-cursors-steps.el: Add
   mc/mark-next-like-this-word call.
 * features/support/env.el: Add shortcut for mc/mark-next-like-this-word
   as "C-S-c C->".
 * mc-mark-more.el: Add to mc/mark-next-like-this description to explain
   what happens when no region is selected. Add
   mc/mark-next-like-this-word function.
 * multiple-cursors-core.el: Add mc/mark-next-like-this-word to commands
   to run once.
 * multiple-cursors.el: Add information about mc/mark-next-like-this-word.
2015-12-04 13:34:47 -05:00
Justin Dove
5d677f765c Unrevert "Support unmarking with no region. Change mc/mark-lines to preserve point."
This reverts commit 2588ccef6939b77896105f23642483c30c4a4e06.
2015-06-08 09:20:46 -04:00
Justin Dove
49c9f7f6bf Merge remote-tracking branch 'upstream/master' 2015-06-08 09:18:33 -04:00
Justin Dove
c90bb624db Changed mc/furthest-cursor-after(before)-point to check if mark is active. 2015-06-07 18:06:55 -04:00
Magnar Sveen
2588ccef69 Revert "Support unmarking with no region. Change mc/mark-lines to preserve point."
This reverts commit 2d6ffce4c94cdbec1ea8ec086ea346423bafcdf1.

Fixes #201
2015-05-29 08:03:15 +02:00
Magnar Sveen
66b1127489 Merge pull request #192 from uk-ar/add_search_word
Enable to specify search word in mc/mark-all-in-region
2015-05-24 11:19:34 +02:00
Justin Dove
2d6ffce4c9 Support unmarking with no region. Change mc/mark-lines to preserve point. 2015-04-05 17:26:07 -04:00
uk-ar
72b4bf3911 Enable to specify search word in mc/mark-all-in-region 2015-04-04 06:29:46 +09:00
Magnar Sveen
da2a9abfd8 Add mc/mark-all-in-region-regexp
Thanks to Gabriel Antonioli :-)
2014-04-16 20:07:26 +02:00
Kouhei Yanagita
00aea4c9d7 Show appropriate error messages on trying skipping/unmarking commands with no fake cursors 2014-01-03 13:00:13 +09:00
Magnar Sveen
17c48f972a Merge pull request #111 from mathrick/mark-all-dwim
Add mc/mark-all-dwim to autoloads
2013-09-13 11:48:11 -07:00
Maciej Katafiasz
6467fe251d Add mc/mark-all-dwim to autoloads 2013-09-13 18:29:22 +02:00
Magnar Sveen
65c0c0c6fe Merge pull request #104 from mathrick/mark-all-dwim
Add new command, mark-all-dwim
2013-09-06 12:57:31 -07:00
Maciej Katafiasz
ec4781394c Derp, multiple cursors means > 1, not > 0. 2013-09-06 19:44:31 +02:00
Maciej Katafiasz
18d858f0de Fall straight through in 'mc/mark-all-dwim' if multiple cursors are already active, as that means we can't sensibly edit lines or mark all in region 2013-09-06 14:52:16 +02:00
Maciej Katafiasz
a86daa79ce Guard with 'if' rather than defun*/return-from 2013-09-06 09:33:37 +02:00
Maciej Katafiasz
8dfe725c4f Abort immediately when empty search pattern is passed to 'mc/mark-all-in-region' 2013-09-05 23:53:59 +02:00
Maciej Katafiasz
af66635a05 Make 'mc/mark-all-dwim' into 'mc/edit-lines' if prefix arg is passed 2013-09-05 18:16:39 +02:00
Maciej Katafiasz
5e879f9b5c Guard against empty search pattern in 'mc/mark-all-in-region', otherwise it will enter an infinite loop 2013-09-05 17:42:36 +02:00
Maciej Katafiasz
45c6cd0be4 Add mc/mark-all-dwim 2013-08-30 22:36:01 +02:00
Akinori MUSHA
2186e1b6e5 mc/mark-lines: Mark by logical lines. 2013-08-01 17:00:03 +09:00
Magnar Sveen
754de4e63b Backport set-temporary-overlay-map to emacs <24.3
Fixes #88
2013-07-11 09:14:06 +02:00
Magnar Sveen
cc45842384 Improved mc/mark-more-like-this-extended
- support for terminal
 - more instructive message
 - keymap that can be rebound

Fixes #84
2013-06-07 23:18:19 +02:00
Magnar Sveen
ccb42b5d70 Inline defun for better readability. 2013-03-15 20:21:34 +01:00
Takafumi Arakaki
1cdd73037f Automatically select word/symbol 2013-03-10 06:53:53 +01:00
Magnar Sveen
0ee76bfad1 Add mc/add-cursor-on-click 2013-02-20 07:05:18 +01:00
Magnar Sveen
bc8af45bfe Use derived-mode-p to check for sgml-mode-ishness. 2012-11-21 13:22:27 +01:00
Magnar Sveen
0a081a7c5f Move mc/maybe-multiple-cursors-mode to core. 2012-11-18 21:10:09 +01:00
Magnar Sveen
7d79b983ea Autoload new functions. 2012-11-18 16:08:10 +01:00
Magnar Sveen
c010afbbef Rename mc/mark-sgml-tags to mc/mark-sgml-tag-pair 2012-11-18 14:45:25 +01:00