From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1883 invoked by alias); 5 Jul 2016 09:17:54 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: X-Seq: 38795 Received: (qmail 5326 invoked from network); 5 Jul 2016 09:17:53 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM, T_DKIM_INVALID autolearn=ham autolearn_force=no version=3.4.1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.co.uk; s=s2048; t=1467709896; bh=FynXMEhedoq1Wmf3K3HB4ZtYud9vrY43WnDcS7jAqZo=; h=Date:From:Reply-To:To:Subject:References:From:Subject; b=QdZcaQ77iP6vCQ0h3srPCMnUzZyj0vwHq3gp51DGX2Igt8384ku50P8JxH7uJbx6FI1Q7TpXKp7F/5sgSJjlc2gWi1YUqUk6MDFq0irKNDGl/GYtpkSDgmONop1lNN2PcHStnYTHZzfzkd7ohnEIS/TFd2gqZ9QDE3KQ8W7OMlgZu326cykEIDhex0vt3mt4/TiFCD3W1dSE7XjH8qsJuHlBVeWUqF4mxhL/3e+VfcLTLZ9Iw99pUo6IwQMHKuxIwwsoX0fiQldWN5vreMDdpoApRGCe2LasrRaSwZs4blEBD21Cz+9BrHHQ1HJY2gUGsxGxFRz3UnBAdtjqcpz4cw== X-Yahoo-Newman-Property: ymail-4 X-Yahoo-Newman-Id: 398528.30711.bm@omp1007.mail.ir2.yahoo.com X-YMail-OSG: u203eccVM1k6bzrs4Ck4fZ0g4S4w.0pbVzvgl3AsFh_swEgmKJITzKsrRA5azcm g0mFxDOz7Ftex7NEPaiIKi4t.5tPOdeUNwBM333E3uj5GqmQVRrXsJsFhO8MuuTCiYCbIxGSp38N ts..vNDBUvsdiNbosB4rEt6Z68OR4bi5KSMHR_D75inpDYBWkgDZtAiTbi7MpzDdAU2azY6l_VTr 4miVk7HmunRBqgssO4LQ1StPF10DDSOuXwq5hGcD6RRFCm3I09r24H5vS9R.Lt6NFqxNltzNlk8g TpAPVgDTF3zf9AjOUAlg85sZIg3lWsGvsRWL9FxiJZluxLC8yyrtLo0nPn9fkHL6PgrA7VBHOOHq LhX.eprHKdEeSTavPepiXKjKv0grIbMqyBs77UhfuPpjmpWHMcyS1vpPsFk_5VMqNsaY6J3DGKf7 mPGDhIoAXcG8HDTcfBAEhKEzbNtUUczUJEjjqm0e.9DMP9wbkE8ripwcguqYLJCH68Ofil3psc8o VneyuvwTJs_lFHhKTMGAfBp6FwChy_2WD Date: Tue, 5 Jul 2016 09:08:46 +0000 (UTC) From: Oliver Kiddle Reply-To: Oliver Kiddle To: Message-ID: <588168129.3340906.1467709726474.JavaMail.yahoo@mail.yahoo.com> Subject: bug with camel case and delete-whole-word-match function MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit References: <588168129.3340906.1467709726474.JavaMail.yahoo.ref@mail.yahoo.com> I took a look at the word style widgets in the contributed functions with a view to perhaps adding a vim style text object based on them. delete-whole-word-match appears to be the most useful example because it operates on a whole word rather than just forward of backward. Unfortunately, it doesn't seem to work too well for the subword (camel case) word style. The presence of white space before the cursor position is used as an indication that the cursor is on the first character of the word but with camel case, there isn't necessarily any whitespace. Perhaps I'm missing something in the configuration but I have: autoload -U delete-whole-word-match zle -N delete-whole-word-match zstyle ':zle:*' word-style normal-subword bindkey '^K delete-whole-word-match On the first character of a camel case word, both the current and previous word are deleted. On the last letter, it deletes up to the next real whitespace. Oliver