0

我想生成 SlickEdit 18.0.0+ 中未填充的键绑定列表

有没有一种简单的方法可以做到这一点?

目前,当我写一个新的宏时,我必须寻找和啄尝试各种组合,以找出是否有一个我可以不用的键序列。

我在互联网上找到的唯一内容是对此的邮件列表功能请求,SlickEdit 员工建议使用命令行界面而不是绑定的热键。不完全是我所希望的。

4

1 回答 1

1

我使用的是 v17,但“未使用的键”是一个无限集,因为它是一个多键热键系统。我想它可以基于现有的密钥树来完成,但我不想写它。

如果您正在寻找一种快速的手动方法来查找空键路径,请使用以下命令:

// list keys in sorted fashion to new buffer
_command list_keydefs()
// Find command assigned to a key-path
_command what_is()
// Find commands assigned to key-paths
_command what_are()
// Find key-paths assigned to command
_command where_is(_str commandName='', _str quiet='',_str separatorChar=',') name_info(COMMAND_ARG',')
// Bind to a key
_command bind_to_key(_str commandName='') name_info(COMMAND_ARG',')
// Bind current word (proc name) to key
_command bind_cur_word_alt(){
  if (command_state()) {
    return(0);
  }
  _str s=cur_word(0);
  if (s==''||!is_cmd(s)) {
    s=current_proc_name(false);
  }
  if (!is_cmd(s)) {
    _message_box(s' is not a command');
    return(0);
  }
  _str sa=letter_prompt('Number of Keys or 0 to Quit','1234567890');
  if (sa==''||sa=='0') {
    _message_box(1);return(0);
  }
  _str ss='-'sa' -r 's;
  bind_to_key(ss);
  ss=where_is(s,1);
  sticky_message(ss);
}
// utils
_command is_cmd(...){
  _str p=current_proc(false);//was current_proc_name
  if (arg()==1) {
    p=arg(1);
  }
  return(find_index(p,COMMAND_TYPE)!=0);
}
于 2014-03-27T09:30:57.883 回答