Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8182147
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T00:45:41+00:00 2026-06-07T00:45:41+00:00

Emacs n00b here, I’ve fiddled a bit with it in graphical mode and so

  • 0

Emacs n00b here, I’ve fiddled a bit with it in graphical mode and so far I’ve found it great. I wanted to give the terminal version a try and found out that there’s a few annoying behaviour differences, in particular with shift-selection.

In graphical mode I can combine shift selection (ie holding shift to set a mark) with the arrow keys, the control key (to select whole words) or the origin or end keys (to select the whole/a large part of a line).

In terminal mode the keys work fine on their own (I can select regions while holding shift and moving with the arrow keys*, C-left/right allows me to jump whole words, origin and end bring me where I want to go) but I can’t combine them (can’t select whole words by holding shift and C-arrowing, or select the remaining part of a line with shift-end or shift-origin).

I also found that C-backspace didn’t work (ie didn’t erase the whole word) in console while it does in window mode, though I read about M-backspace after looking for a solution.

I searched as thoroughly as I could but could not find how to get the terminal version to behave like the graphical version… Lots of people seem to ask questions about Emacs’s shift selection but none of them have quite the same problem… Can someone explain where those behaviour differences come from?

Thanks in advance.

*Though, holding shift, if I go down (with the arrow key) to select whole lines, I can’t go up again to unselect them (” is undefined”).

[edit /] Okay, so obviously this comes from the fact that my terminal doesn’t have the same shortcuts as graphical Emacs does. Fair enough. I see a couple of solutions here:

  • getting used to default Emacs shortcuts
  • filling my .emacs with global-set-key’s. Although I tried

    (fset 'select-to-end
    [(kbd "C-<spc> <end>")])
    (global-set-key (kbd "S-<end>") 'select-to-end)
    


    but it doesn’t work as I intend it to -_-

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T00:45:44+00:00Added an answer on June 7, 2026 at 12:45 am

    The short answer is “if you’re happy using different keystrokes, that might be easier”. Personally, I’m a little neurotic about my keybindings and configuration, so I rarely go with this one; in particular, it’s frustrating when emacs modes override your bindings. (I don’t know if you’ve yet discovered that global-set-key really means “let anyone in the universe stamp on my keybinding”.)

    The longer answer to your question is “someone along the chain is ignoring your control characters, so you need to figure out who it is, fix it, and then repeat”. For the keybindings you’re talking about here — C-S-<arrows> — you can definitely get this to work; if you want something like \C-~, you’re going to have a much harder time. (The issue is that some bindings didn’t make sense in legacy terminals, so you basically have to use a nonstandard set of control codes to transmit the key combination, and then teach each program to recognize it. This is usually where a termcap comes in, since it’s a common language for teaching programs about key events.)

    Here are the steps I usually take:

    • Start with your terminal. You can use \C-v and then hit a key to insert the literal keystroke (at least in bash) — start by doing this with C-left, S-left, and C-S-left. Confirm that you’re getting three different control codes.
    • If you’re not, you need to investigate either (1) your readline settings, (2) your terminal program settings or (3) your termcap settings. Since TERM is xterm, the termcap should be fine. I don’t know what terminal program you’re using, but it may have its own key configuration. (For instance, I use a mac and use iTerm2, which is usually my first stop.) If you’re going to be spending time at a terminal anyway, you should definitely take the time to read the readline manual and play with your .inputrc a bit.
    • This chain is short: next is emacs. You can use \C-q in emacs to do the same thing \C-v does in bash, or use \C-h k to find out what the default bindings are. Again, start by making sure emacs sees distinct key events for the combinations you’re interested in. If not, you’ll probably want to start by looking at term/xterm.el in your site-lisp directory and modifying it to your liking.

    If you’re using tmux or screen, they also get a hand in this, and can usually be tamed. The process for finding those problems is the same as bash — use \C-v and man tmux to figure out how to get your extra keybindings.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

GNU Emacs 23.2.1 prolog-mode-version is a variable defined in `prolog.el'. Its value is 1.22
In emacs, is there a way to get hideshow-mode to recognize multiple regular expressions
Emacs 23 can view PDF files inside the editor which is great. However it
When Emacs runs under terminal, it sees different names for certain keys compared to
Emacs's auto-fill mode splits the line to make the document look nice. I need
Emacs noob here, For some reason, when I try to Open a existing C++
In emacs, while in Dired mode, I can use the ~ command to mark
In Emacs, the line gets indented only after hitting return (in cc-mode). Is that
Emacs cc-mode does not appear to yet recognize the type-safe enum class introduced in
My emacs (Aquamacs with AucTex) changes font size (in e.g. LaTeX mode) to show

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.