emacs c++-mode comment selection: Ctrl-C Ctrl-C

153 views
Skip to first unread message

petyanca

unread,
Feb 26, 2012, 12:39:22 PM2/26/12
to Emacs+ plugin discussion
Hello Group, I was trying to add "comment selection" feature in emacs+
and bind it to Ctr-C-C (hold Ctrl, press 'C' twice), as it is present
in emacs c++ mode. However, it doesn't work with emacs+. Is it
possible to make it work ? Thanks,

Petr

Mark Feber

unread,
Feb 26, 2012, 1:53:58 PM2/26/12
to emac...@googlegroups.com
Petr,
  Not sure why you need to 'add' this feature, as the command is already present in the cdt env: org.eclipse.cdt.ui.edit.text.c.toggle.comment
and should be bound to M-; in the default Emacs+ env (unless you are not using cdt?).  There shouldn't be any issue with rebinding it to C-c C-c following the usual Eclipse mechanisms (watch out for conflicts, use the correct 'When', etc.).
  Mark

petyanca

unread,
Feb 27, 2012, 11:03:10 PM2/27/12
to Emacs+ plugin discussion
Thanks Mark, there is a 'Comment' command with no default binding and
'when'='editing java source' which I tried to assign ctrl-c ctrl-c
binding and which doesn't work, and then there is a 'toggle comment'
command with default binding ctrl-/, which i am able to change to ctrl-
c ctrl-c and it does work. Its a bit confusing. I'm new to eclipse,
and I use original emacs for c++.
Reply all
Reply to author
Forward
0 new messages