このページでは

フェイクビム

Vimスタイルの編集を設定するには、Preferences>FakeVim を開いてください。

Vim の動作を設定する

Vim の動作を設定するには、Preferences>FakeVim >General に進んでください。

FakeVim環境設定の「一般」タブ

プリセットを使う

  • テキストエディター用に指定されたインデント設定を事前に選択するには、Copy Text Editor Settings を選択します。
  • Qt コーディングスタイルを事前に選択するには、Set Qt Style を選択します。
  • 単純なインデント・スタイルを事前に選択するには、Set Plain Style を選択します。

次に、事前に選択された設定を変更します。

プラグインのエミュレート

Plugin Emulation でエミュレートする人気のある vim プラグインを選択します。

次の表は、利用可能なプラグインとそのリンクです。

Vim プラグイン説明
vim-commentarygc コード領域をコメントするアクション。例えば、gcc,gc2jgcip
ReplaceWithRegister
  • [count]["x]gr{motion}motion をレジスタx の内容に置き換える。
  • [x]grrで現在の行を置き換える。
argtextobj.vim関数のパラメータ用にiaaa テキストオブジェクトを定義します。
vim-exchangevim のテキスト交換演算子。
vim-surround周囲の削除、追加、変更のためのマッピングを追加します。

FakeVim コマンドのマッピング

FakeVim コマンドラインで入力されたコマンドをQt Creator 関数にマッピングします:

  1. Preferences>FakeVim >Ex Command Mapping に進みます。
  2. Filter フィールドに文字列を入力し、Qt Creator 関数を検索します。

    FakeVim環境設定のExコマンドマッピングタブ

  3. リストで関数を選択します。
  4. Regular expression フィールドに、関数のトリガーとなる文字列を入力します。

    Ex Trigger Expression フィールドにトリガー式が表示されます。

選択したトリガー式を削除するには、Reset を選択します。

すべての関数のトリガ式をリセットするには、Reset All を選択します。

ユーザーコマンドのマッピング

ユーザーコマンドをキーボードショートカットにマッピングするには、Preferences>FakeVim >User Command Mapping を選択します。ショートカットにマッピングされたユーザーコマンドは、FakeVim によって(マクロを再生するときのように)タイプしたかのように実行されます。

ユーザーコマンドマッピングタブ FakeVim環境設定

Edit like in VimFakeVim Modes and Commandsも参照してください

Copyright © The Qt Company Ltd. and other contributors. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.