Hi,
What's it all about?
:help motion.txt
/FORCING
Patch attached.
Cheers,
--
Krzysiek
--~--~---------~--~----~------------~-------~--~----~
Yi development mailing list
[email protected]
http://groups.google.com/group/yi-devel
-~----------~----~----~----~------~----~------~--~---
Fri Dec 5 17:44:40 CET 2008 Krzysztof Goj <[EMAIL PROTECTED]>
* forcing RegionStyle
Fri Dec 5 18:21:28 CET 2008 Krzysztof Goj <[EMAIL PROTECTED]>
* Force-operation chaining (eg. dVvvVvvVvj)
New patches:
[forcing RegionStyle
Krzysztof Goj <[EMAIL PROTECTED]>**20081205164440] hunk ./Yi/Keymap/Vim.hs 494
let i = maybe 1 id cnt
choice $ [let onMove regionStyle move =
onRegion regionStyle =<< withBuffer0' (regionOfViMove
move regionStyle)
+ applyOperator frs (regionStyle, m) = write $ onMove (frs
regionStyle) (Replicate m i)
s1 = prefix [c]
ss = nub [[c], s1]
in
hunk ./Yi/Keymap/Vim.hs 499
pString s1 >>
- choice ([ gen_cmd_move >>= (\(regionStyle, m) -> write $
onMove regionStyle (Replicate m i))
- , select_any_unit (onRegion Exclusive)] ++
- [ pString s >>! onMove LineWise (Replicate (Move
VLine Forward) (i-1))
- | s <- ss ])
+ choice ([ forceRegStyle >>= \ frs -> gen_cmd_move >>=
applyOperator frs -- TODO: text units (eg. dViB)
+ , gen_cmd_move >>= applyOperator id
+ , select_any_unit (onRegion Exclusive) ] ++
+ [ pString s >>! onMove LineWise (Replicate (Move
VLine Forward) (i-1)) | s <- ss ]
+ )
| (prefix,c,onRegion) <- opCmdFM
]
hunk ./Yi/Keymap/Vim.hs 508
where
+ -- | Forces RegionStyle; see motion.txt, line 116 and below (Vim
7.2)
+ -- TODO: chainging (vVVvVv), CTRL+v
+ forceRegStyle :: KeymapM (RegionStyle -> RegionStyle)
+ forceRegStyle = choice [ char 'V' ?>> return (\_ -> LineWise)
+ , char 'v' ?>> return swpRsOrIncl]
+ where swpRsOrIncl Exclusive = Inclusive
+ swpRsOrIncl _ = Exclusive
-- | operator (i.e. movement-parameterised) actions
opCmdFM = [ (id, 'd', \s r -> cutRegion s r >> withBuffer0
leftOnEol)
, (id, 'y', yankRegion)
[Force-operation chaining (eg. dVvvVvvVvj)
Krzysztof Goj <[EMAIL PROTECTED]>**20081205172128] hunk ./Yi/Keymap/Vim.hs 500
in
pString s1 >>
choice ([ forceRegStyle >>= \ frs -> gen_cmd_move >>=
applyOperator frs -- TODO: text units (eg. dViB)
- , gen_cmd_move >>= applyOperator id
, select_any_unit (onRegion Exclusive) ] ++
[ pString s >>! onMove LineWise (Replicate (Move
VLine Forward) (i-1)) | s <- ss ]
)
hunk ./Yi/Keymap/Vim.hs 508
]
where
-- | Forces RegionStyle; see motion.txt, line 116 and below (Vim
7.2)
- -- TODO: chainging (vVVvVv), CTRL+v
- forceRegStyle :: KeymapM (RegionStyle -> RegionStyle)
- forceRegStyle = choice [ char 'V' ?>> return (\_ -> LineWise)
- , char 'v' ?>> return swpRsOrIncl]
+ -- TODO: CTRL+v
+ forceRegStyle = do
+ style <- many $ choice [ char 'V' ?>> return (\_ -> LineWise)
+ , char 'v' ?>> return swpRsOrIncl]
+ return $ last (id:style)
where swpRsOrIncl Exclusive = Inclusive
swpRsOrIncl _ = Exclusive
-- | operator (i.e. movement-parameterised) actions
Context:
[Vim: better handling of extra spaces when using minibuffer (:e...)
Nicolas Pouillard <[EMAIL PROTECTED]>**20081205104507
Ignore-this: c2421a4ce3f3c0fa948a1d4028e2927e
]
[Vim: don't leftOnEol in the minibuffer.
Nicolas Pouillard <[EMAIL PROTECTED]>**20081205101252
Ignore-this: 25d2a1737e7f75e6d0d41f19a0df4a36
]
[Optimize going to begin of line.
Nicolas Pouillard <[EMAIL PROTECTED]>**20081205094727
Ignore-this: e9edc3fb2ede3cdac0a096d9367423ac
]
[Vim: add :nohlsearch,:noh to reset the current search.
Nicolas Pouillard <[EMAIL PROTECTED]>**20081205093930
Ignore-this: 77fc9e61e12a04cba2a6523dcc35395d
]
[Yi.Search: add resetRegexE.
Nicolas Pouillard <[EMAIL PROTECTED]>**20081205093855
Ignore-this: d324123e57013fc9ded8b11a84d85c7b
]
[Vim: more leftOnEol fixes.
Nicolas Pouillard <[EMAIL PROTECTED]>**20081205092513
Ignore-this: 8195b31b4126d05722f0f197591acb45
]
[Fixes 'c$' and 'C' in normal mode
Krzysztof Goj <[EMAIL PROTECTED]>**20081205010649]
[Lexer.GNUMake: Adding a test of mixing bracket styles in a variable expansion
[EMAIL PROTECTED]
[Lexer.GNUMake: Adding recursive variable expansion as required by function
calls
[EMAIL PROTECTED]
[Adding a test for use of $$ as a variable identifier.
[EMAIL PROTECTED]
[Lexer.GNUMake: Rule commands can contain variable expansion
[EMAIL PROTECTED]
[Lexer.GNUMake: Handle $$ correctly
[EMAIL PROTECTED]
[Adding a test of $$ to escape a variable expansion
[EMAIL PROTECTED]
[Lexer.GNUMake: Add support for '\' continueing a rule command
[EMAIL PROTECTED]
[Lexer.GNUMake: Small additions.
[EMAIL PROTECTED]
[Lexer.GNUMake: Adding to test data
[EMAIL PROTECTED]
[Lexer.GNUMake: Expansions of variables with single character names
[EMAIL PROTECTED]
[Lexer.GNUMake: Start of variable expansion parsing
[EMAIL PROTECTED]
[Style.Library.darkBlueTheme: cyan for variables. Operators should be brown.
[EMAIL PROTECTED]
[Vim: systematic and localised leftOnEol rule.
Nicolas Pouillard <[EMAIL PROTECTED]>**20081204225652
Ignore-this: 793b88201c1f7b05fd5f2bf7a4399be9
]
[Vim: a bunch of style changes.
Nicolas Pouillard <[EMAIL PROTECTED]>**20081204225639
Ignore-this: 8bfe306f46da28f1bcf0d5ff8889d5b1
]
[Vim: fix more cutting+adjBlock
Nicolas Pouillard <[EMAIL PROTECTED]>**20081204203501
Ignore-this: bb11a79597f31265a4e62cfcb9c563d5
]
[Vim: "J" doesn't cut the newline it replace it by a space.
Nicolas Pouillard <[EMAIL PROTECTED]>**20081204203257
Ignore-this: 800eb5d71bdd6eedd74cd4cad608006d
]
[Lexer.GNUMake: Adding basic include directive support
[EMAIL PROTECTED]
[Adding more include directive test cases to Makefile lexer test data
[EMAIL PROTECTED]
[Adding include directive tests to Makefile lexer test data
[EMAIL PROTECTED]
[Vim: replace z+ by z<CR> and save the current column.
Nicolas Pouillard <[EMAIL PROTECTED]>**20081204171358
Ignore-this: 3f73bbedc7e2d02b5b35d907ad4c1f7d
]
[Vim: use moveToColB for N| command.
Nicolas Pouillard <[EMAIL PROTECTED]>**20081204171332
Ignore-this: 56f99d9b7ddffb93ea19459e3dd023c5
]
[Buffer: wall and style.
Nicolas Pouillard <[EMAIL PROTECTED]>**20081204170727
Ignore-this: 452d30e302e2114620e712a100283817
]
[Buffer: refactor lineMoveRel, add moveToColB, movingToPrefCol and solPointB
Nicolas Pouillard <[EMAIL PROTECTED]>**20081204170427
Ignore-this: 38655198619a876821f1fafb0219d4a4
]
[More scrolling
Krzysztof Goj <[EMAIL PROTECTED]>**20081204025147
Normal mode: zz zt zb z. z+ z-
Insert mode: ^y ^e
]
[Vim: fix multiline cutting/pasting w.r.t. adjBlock.
Nicolas Pouillard <[EMAIL PROTECTED]>**20081204154310
Ignore-this: 5a7a134165571142cec59f93187cea06
]
[Vim: N% move now go to first non space.
Nicolas Pouillard <[EMAIL PROTECTED]>**20081204104245
Ignore-this: 49b00315b215893831191932a388daaf
]
[cabal lexer: follow more closely the actual Cabal tool
Nicolas Pouillard <[EMAIL PROTECTED]>**20081204103504
Ignore-this: 668b9a8f6589e0dbad8c52f519d239a5
In particular concerning comments.
]
[remove a bad usage of List.head
[EMAIL PROTECTED]
[Yi.IReader: more comments
[EMAIL PROTECTED]
Ignore-this: c413390c7fd7ae85f76734fa3c5a8b54
]
[Yi/Users/Corey: Replaced hardcoded 4 in KBS handling to be shift width.
[EMAIL PROTECTED]
[Yi.Users.Corey: minor suggestions
Nicolas Pouillard <[EMAIL PROTECTED]>**20081203214045
Ignore-this: c7357f691ea18c8a89db9b3e7293b762
]
[Vim: less parens.
Nicolas Pouillard <[EMAIL PROTECTED]>**20081203214311
Ignore-this: 22702b54973afdb5c77d67929452a695
]
[Vim: ":<int>" also have to go to first non space char.
Nicolas Pouillard <[EMAIL PROTECTED]>**20081203213806
Ignore-this: 69ee440d16448b21851ddbc06352b37f
]
[Vim: improve 'G' code.
Nicolas Pouillard <[EMAIL PROTECTED]>**20081203213640
Ignore-this: 8cbd5f1a5c13ca99bc7dc0404563a147
]
['gg' and 'G' should go to first non-space char of line
Krzysztof Goj <[EMAIL PROTECTED]>**20081203212353]
[Vim normal mode: "gg" with count argument
Krzysztof Goj <[EMAIL PROTECTED]>**20081203203817]
[Main.hs: M-x ireadMode to just iread
[EMAIL PROTECTED]
Ignore-this: b307ff52b630f8500f05218d4a5aa5c0
So I don't need to constantly disambiguate.
]
[last of the LANGUAGE pragmas
[EMAIL PROTECTED]
Ignore-this: 8a1bd56c03682e4c9b163a615263af84
I have cast the extensions field into perdition, and added the missing
per-file declarations.
]
[Shim/*: +pragmas, rm unused imports
[EMAIL PROTECTED]
Ignore-this: eff16eba16ed8e3b98fdfe9420f1ab2b
]
[fix up Shim/ w/r/t Control.Exception
[EMAIL PROTECTED]
Ignore-this: 4ec9ae4bafcf9b98c07acd0a6cbab9e
]
[Shim/; some -Wall cleanup
[EMAIL PROTECTED]
Ignore-this: bcfe4c1e2d239472e56d08fe0eee0bd4
]
[Comments fix
Krzysztof Goj <[EMAIL PROTECTED]>**20081203155512
- Esc leaves visual mode -- dropping comment
- Explain and extend a FIXME for S and C
]
[Add Yi.Region.regionIsEmpty
Nicolas Pouillard <[EMAIL PROTECTED]>**20081203175753
Ignore-this: c075fd46a14a991d5476770b9faafed7
]
[Vim: do nothing when cuting/pasting empty regions
Nicolas Pouillard <[EMAIL PROTECTED]>**20081203155544
Ignore-this: e0b4bc63452e1e2df93b4e3a2a841413
This avoid marking the buffer as unsaved.
]
[Vim: style, parens, and trailing white-spaces.
Nicolas Pouillard <[EMAIL PROTECTED]>**20081203155350
Ignore-this: 3d959998aed83292f5fac99a7a8d6f44
]
[Vim: when leaving insert/replace mode, use moveXorSol 1 instead of leftB
Nicolas Pouillard <[EMAIL PROTECTED]>**20081203155247
Ignore-this: f2766bc3a75501484a524d241f84e025
]
[Corrected 'x' and 'X' behaviour
Krzysztof Goj <[EMAIL PROTECTED]>**20081203125741
Now 'x' and 'X' are aliases to dl and dh (as in Vim) -- they cannot delete
newline character.
]
[Ctrl+h in insert and replace mode; Ctrl+w in replace mode
Krzysztof Goj <[EMAIL PROTECTED]>**20081203012614]
[Ctrl+h in Ex mode
Krzysztof Goj <[EMAIL PROTECTED]>**20081203000017]
[Ctrl+p, Ctrl+n in Ex mode
Krzysztof Goj <[EMAIL PROTECTED]>**20081202235807]
[Vim visual mode: 's' is synonym to 'c'
Krzysztof Goj <[EMAIL PROTECTED]>**20081202233509]
[Vim: ctrl+u, ctrl+d scrolling
Krzysztof Goj <[EMAIL PROTECTED]>**20081202231544]
[Behaviour at end of line (BIG PATCH)
Krzysztof Goj <[EMAIL PROTECTED]>**20081203031045
- Doesn't allow to go to EOL in normal mode
- Does allow it in other (visual, insert, replace) modes
- Corrected D, and '$' command
- cursor moves left after leaving insert and replace mode
]
[Ctrl-t and Ctrl-d in insert mode (indentation)
Krzysztof Goj <[EMAIL PROTECTED]>**20081202223751]
[Better percent move.
Krzysztof Goj <[EMAIL PROTECTED]>**20081202162105]
[Issue 202: indentation and Vim commands
Krzysztof Goj <[EMAIL PROTECTED]>**20081202183446
Added indentation-awareness to cutRegion, pasteBefore and pasteAfter.
]
[Fixed isMakefile: takeBaseName should be takeFileName. Otherwise makefile's
named like foo.mk would not be recognized.
[EMAIL PROTECTED]
[replace all: more helpful message
[EMAIL PROTECTED]
[fix build
[EMAIL PROTECTED]
[Better word and WORD motions for Vim keymap.
Krzysztof Goj <[EMAIL PROTECTED]>**20081202132813]
[doc
[EMAIL PROTECTED]
[Yi/Users/Gwern.hs: +shorter binding for gotoLn
[EMAIL PROTECTED]
Ignore-this: 5defc56344c3e1c61bd602d192e06af3
I find the default Emacs binding of M-g g tedious; why not just M-g?
]
[doc
[EMAIL PROTECTED]
[make Accessor instance of Category
[EMAIL PROTECTED]
[use Control.Category
[EMAIL PROTECTED]
[Yi.Keymap.Emacs: +standard emacs M-; binding
[EMAIL PROTECTED]
Ignore-this: 5abf2d7154acfdcce44286f34ec238b9
]
[update to base>=4; replace all Control.Exception with Control.OldException
[EMAIL PROTECTED]
Ignore-this: 205b7c23a4ffcc16b8612d0b4edc9352
]
[better support for vivid colors
[EMAIL PROTECTED]
[Main.hs: minor indent
[EMAIL PROTECTED]
Ignore-this: b53fd55beb556c92b6bba9ee4a49cd61
]
[added C-w and C-u to ex mode
Aleksandar Dimitrov <[EMAIL PROTECTED]>**20081201103414]
['ZZ' closes window, not editor, 'ZQ' == ':q!'
Aleksandar Dimitrov <[EMAIL PROTECTED]>**20081201103311]
[bump version number
[EMAIL PROTECTED]
[TAG 0.5.2
[EMAIL PROTECTED]
Patch bundle hash:
b257fd21f483682d4c29738ce520db189d38d18e