* Re: auto-indent in emacs [not found] ` <87tywc9gpi.fsf@ergodik.univ-brest.fr> @ 2009-11-30 15:58 ` Lennart Borgman 2009-11-30 16:48 ` Sebastian Rose 0 siblings, 1 reply; 12+ messages in thread From: Lennart Borgman @ 2009-11-30 15:58 UTC (permalink / raw) To: harven; +Cc: emacs help, Emacs-Devel devel On Mon, Nov 30, 2009 at 4:26 PM, harven <harven@free.fr> wrote: > Kenneth Brun Nielsen <kenneth.brun.nielsen@googlemail.com> writes: > >> I want to auto-indent a section (actually a whole file) in Emacs. >> >> I googled, that the shortcut C-M-\ ("CTRL+ALT+backspace") does the >> job, but since I have a danish keyboard, where "backspace" requires me >> to push the META-button "Alt Gr", it seems I'm not able to push this >> combination. >> >> Any suggestions for another way to auto-indent? >> >> Best regards, >> Kenneth > > C-M-\ runs the command indent-region (check it by typing C-h k C-M-\). > So bind that command to another shortcut. For example, to bind it to C-c i > put the following line in your .emacs > > (global-set-key (kbd "C-c i") 'indent-region) Please see also the page http://www.emacswiki.org/emacs/AltGrKey for how to type C-M-\. Emacs Devel: Could we please get this information into the manual? I think it fits under (info "(emacs) Windows Keyboard") where AltGr is mentioned. ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: auto-indent in emacs 2009-11-30 15:58 ` auto-indent in emacs Lennart Borgman @ 2009-11-30 16:48 ` Sebastian Rose 2009-11-30 17:06 ` Lennart Borgman 2009-11-30 17:26 ` Dan Nicolaescu 0 siblings, 2 replies; 12+ messages in thread From: Sebastian Rose @ 2009-11-30 16:48 UTC (permalink / raw) To: Lennart Borgman; +Cc: emacs help, harven, Emacs-Devel devel Lennart Borgman <lennart.borgman@gmail.com> writes: > On Mon, Nov 30, 2009 at 4:26 PM, harven <harven@free.fr> wrote: >> Kenneth Brun Nielsen <kenneth.brun.nielsen@googlemail.com> writes: >> >>> I want to auto-indent a section (actually a whole file) in Emacs. >>> >>> I googled, that the shortcut C-M-\ ("CTRL+ALT+backspace") does the >>> job, but since I have a danish keyboard, where "backspace" requires me >>> to push the META-button "Alt Gr", it seems I'm not able to push this >>> combination. >>> >>> Any suggestions for another way to auto-indent? C-x h M-x indent-region RET I have bound `indent-region' to <f5>. >>> Best regards, >>> Kenneth >> >> C-M-\ runs the command indent-region (check it by typing C-h k C-M-\). >> So bind that command to another shortcut. For example, to bind it to C-c i >> put the following line in your .emacs >> >> (global-set-key (kbd "C-c i") 'indent-region) > > > Please see also the page http://www.emacswiki.org/emacs/AltGrKey for > how to type C-M-\. All those commands are unusable anyway for they're to difficult to type. But four of those come with easier to type alternatives, which are not mentioned there. Why? C-M-@ => C-M-SPC C-@ => C-SPC C-x C-@ => C-x C-SPC C-x r C-@ => C-x r SPC Only backslash commands might be problem. They are not on none of my (German) keyboards. I guess it's a problem of the underlying system (Windows I guess). How about filing a bug report there? Those commands are: `indent-region' has to be rebound (<f5> here). `set-input-method' `abort-recursive-edit' I think http://www.emacswiki.org/emacs/AltGrKey is obsolete and should be fixed. Sebastian ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: auto-indent in emacs 2009-11-30 16:48 ` Sebastian Rose @ 2009-11-30 17:06 ` Lennart Borgman 2009-11-30 18:11 ` Lennart Borgman 2009-11-30 17:26 ` Dan Nicolaescu 1 sibling, 1 reply; 12+ messages in thread From: Lennart Borgman @ 2009-11-30 17:06 UTC (permalink / raw) To: Sebastian Rose; +Cc: emacs help, harven, Emacs-Devel devel On Mon, Nov 30, 2009 at 5:48 PM, Sebastian Rose <sebastian_rose@gmx.de> wrote: > > All those commands are unusable anyway for they're to difficult to type. > But four of those come with easier to type alternatives, which are not > mentioned there. Why? > > C-M-@ => C-M-SPC > C-@ => C-SPC > C-x C-@ => C-x C-SPC > C-x r C-@ => C-x r SPC That is a good observation. > Only backslash commands might be problem. They are not on none of my > (German) keyboards. I guess it's a problem of the underlying system > (Windows I guess). How about filing a bug report there? Please do. > I think http://www.emacswiki.org/emacs/AltGrKey is obsolete and should > be fixed. Please help rewriting the page. ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: auto-indent in emacs 2009-11-30 17:06 ` Lennart Borgman @ 2009-11-30 18:11 ` Lennart Borgman 2009-11-30 19:22 ` Lennart Borgman 2009-11-30 21:05 ` Sebastian Rose 0 siblings, 2 replies; 12+ messages in thread From: Lennart Borgman @ 2009-11-30 18:11 UTC (permalink / raw) To: Sebastian Rose; +Cc: emacs help, harven, Emacs-Devel devel On Mon, Nov 30, 2009 at 6:06 PM, Lennart Borgman <lennart.borgman@gmail.com> wrote: > >> I think http://www.emacswiki.org/emacs/AltGrKey is obsolete and should >> be fixed. > > > Please help rewriting the page. Since no one answered I am doing that right now. ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: auto-indent in emacs 2009-11-30 18:11 ` Lennart Borgman @ 2009-11-30 19:22 ` Lennart Borgman 2009-11-30 21:05 ` Sebastian Rose 1 sibling, 0 replies; 12+ messages in thread From: Lennart Borgman @ 2009-11-30 19:22 UTC (permalink / raw) To: emacs help; +Cc: Emacs-Devel devel On Mon, Nov 30, 2009 at 7:11 PM, Lennart Borgman <lennart.borgman@gmail.com> wrote: > On Mon, Nov 30, 2009 at 6:06 PM, Lennart Borgman > <lennart.borgman@gmail.com> wrote: >> >>> I think http://www.emacswiki.org/emacs/AltGrKey is obsolete and should >>> be fixed. >> >> >> Please help rewriting the page. > > Since no one answered I am doing that right now. I have rewritten the wiki page. There are now also a summary of problematic key bindings (which I think should be fixed). Comments and critique is (almost) welcome. ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: auto-indent in emacs 2009-11-30 18:11 ` Lennart Borgman 2009-11-30 19:22 ` Lennart Borgman @ 2009-11-30 21:05 ` Sebastian Rose 1 sibling, 0 replies; 12+ messages in thread From: Sebastian Rose @ 2009-11-30 21:05 UTC (permalink / raw) To: Lennart Borgman; +Cc: emacs help, harven, Emacs-Devel devel Lennart Borgman <lennart.borgman@gmail.com> writes: > On Mon, Nov 30, 2009 at 6:06 PM, Lennart Borgman > <lennart.borgman@gmail.com> wrote: >> >>> I think http://www.emacswiki.org/emacs/AltGrKey is obsolete and should >>> be fixed. >> >> >> Please help rewriting the page. > > Since no one answered I am doing that right now. Sorry, I was into something else. I saw you added more of these `impossible-to-type' keys. I've thought of switching the keyboard layout to neo2 already :-) Thank's for the update. Sebastian ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: auto-indent in emacs 2009-11-30 16:48 ` Sebastian Rose 2009-11-30 17:06 ` Lennart Borgman @ 2009-11-30 17:26 ` Dan Nicolaescu 2009-11-30 19:20 ` Davis Herring 1 sibling, 1 reply; 12+ messages in thread From: Dan Nicolaescu @ 2009-11-30 17:26 UTC (permalink / raw) To: Sebastian Rose; +Cc: emacs help, Lennart Borgman, harven, Emacs-Devel devel Sebastian Rose <sebastian_rose@gmx.de> writes: > Lennart Borgman <lennart.borgman@gmail.com> writes: > > > On Mon, Nov 30, 2009 at 4:26 PM, harven <harven@free.fr> wrote: > >> Kenneth Brun Nielsen <kenneth.brun.nielsen@googlemail.com> writes: > >> > >>> I want to auto-indent a section (actually a whole file) in Emacs. > >>> > >>> I googled, that the shortcut C-M-\ ("CTRL+ALT+backspace") does the > >>> job, but since I have a danish keyboard, where "backspace" requires me > >>> to push the META-button "Alt Gr", it seems I'm not able to push this > >>> combination. > >>> > >>> Any suggestions for another way to auto-indent? > > > C-x h M-x indent-region RET > > I have bound `indent-region' to <f5>. > > > >>> Best regards, > >>> Kenneth > >> > >> C-M-\ runs the command indent-region (check it by typing C-h k C-M-\). > >> So bind that command to another shortcut. For example, to bind it to C-c i > >> put the following line in your .emacs > >> > >> (global-set-key (kbd "C-c i") 'indent-region) > > > > > > Please see also the page http://www.emacswiki.org/emacs/AltGrKey for > > how to type C-M-\. > > > All those commands are unusable anyway for they're to difficult to type. > But four of those come with easier to type alternatives, which are not > mentioned there. Why? > > C-M-@ => C-M-SPC > C-@ => C-SPC > C-x C-@ => C-x C-SPC > C-x r C-@ => C-x r SPC > > > Only backslash commands might be problem. They are not on none of my > (German) keyboards. I guess it's a problem of the underlying system > (Windows I guess). How about filing a bug report there? > > Those commands are: > > `indent-region' has to be rebound (<f5> here). Why? TAB does `indent-region' just fine > `set-input-method' > `abort-recursive-edit' > > > > > I think http://www.emacswiki.org/emacs/AltGrKey is obsolete and should > be fixed. > > > > Sebastian ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: auto-indent in emacs 2009-11-30 17:26 ` Dan Nicolaescu @ 2009-11-30 19:20 ` Davis Herring 2009-11-30 19:23 ` Dan Nicolaescu 0 siblings, 1 reply; 12+ messages in thread From: Davis Herring @ 2009-11-30 19:20 UTC (permalink / raw) To: Dan Nicolaescu Cc: Sebastian Rose, Lennart Borgman, emacs help, harven, Emacs-Devel devel > Why? > TAB does `indent-region' just fine Only with Transient Mark Mode. Davis -- This product is sold by volume, not by mass. If it appears too dense or too sparse, it is because mass-energy conversion has occurred during shipping. ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: auto-indent in emacs 2009-11-30 19:20 ` Davis Herring @ 2009-11-30 19:23 ` Dan Nicolaescu 2009-11-30 19:39 ` Davis Herring 0 siblings, 1 reply; 12+ messages in thread From: Dan Nicolaescu @ 2009-11-30 19:23 UTC (permalink / raw) To: herring Cc: Sebastian Rose, Lennart Borgman, emacs help, harven, Emacs-Devel devel "Davis Herring" <herring@lanl.gov> writes: > > Why? > > TAB does `indent-region' just fine > > Only with Transient Mark Mode. i.e. by default. ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: auto-indent in emacs 2009-11-30 19:23 ` Dan Nicolaescu @ 2009-11-30 19:39 ` Davis Herring 2009-11-30 19:44 ` Lennart Borgman 2009-11-30 20:08 ` Dan Nicolaescu 0 siblings, 2 replies; 12+ messages in thread From: Davis Herring @ 2009-11-30 19:39 UTC (permalink / raw) To: Dan Nicolaescu Cc: Sebastian Rose, Lennart Borgman, emacs help, Emacs-Devel devel > > > Why? > > > TAB does `indent-region' just fine > > > > Only with Transient Mark Mode. > > i.e. by default. Well, either `indent-region' is important enough, even in the presence of TAB/TMM, to get a keybinding (currently C-M-\), in which case it's worthwhile to consider whether certain keyboards have difficulty generating that event, or it's not, in which case we can just get rid of the keybinding altogether now that TMM is the default and have one more available for user customization (for those users on whose keyboards it is a convenient chord). Saying "it's a bad keybinding but we really don't want it anyway" strikes me as nonsensical. Davis -- This product is sold by volume, not by mass. If it appears too dense or too sparse, it is because mass-energy conversion has occurred during shipping. ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: auto-indent in emacs 2009-11-30 19:39 ` Davis Herring @ 2009-11-30 19:44 ` Lennart Borgman 2009-11-30 20:08 ` Dan Nicolaescu 1 sibling, 0 replies; 12+ messages in thread From: Lennart Borgman @ 2009-11-30 19:44 UTC (permalink / raw) To: herring; +Cc: Sebastian Rose, Dan Nicolaescu, emacs help, Emacs-Devel devel On Mon, Nov 30, 2009 at 8:39 PM, Davis Herring <herring@lanl.gov> wrote: > > Well, either `indent-region' is important enough, even in the presence of > TAB/TMM, to get a keybinding (currently C-M-\), in which case it's > worthwhile to consider whether certain keyboards have difficulty > generating that event, or it's not, in which case we can just get rid of > the keybinding altogether now that TMM is the default and have one more > available for user customization (for those users on whose keyboards it is > a convenient chord). Saying "it's a bad keybinding but we really don't > want it anyway" strikes me as nonsensical. I agree. Let us get rid of C-M-\. And I think we should get rid of the other troublesome keybindings too, see http://www.emacswiki.org/emacs/AltGrKey where I have listed those now. If some of them are important (and I think some of them are) they should get new key bindings. ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: auto-indent in emacs 2009-11-30 19:39 ` Davis Herring 2009-11-30 19:44 ` Lennart Borgman @ 2009-11-30 20:08 ` Dan Nicolaescu 1 sibling, 0 replies; 12+ messages in thread From: Dan Nicolaescu @ 2009-11-30 20:08 UTC (permalink / raw) To: herring; +Cc: Sebastian Rose, Lennart Borgman, emacs help, Emacs-Devel devel "Davis Herring" <herring@lanl.gov> writes: > > > > Why? > > > > TAB does `indent-region' just fine > > > > > > Only with Transient Mark Mode. > > > > i.e. by default. > > Well, either `indent-region' is important enough, even in the presence of > TAB/TMM, to get a keybinding (currently C-M-\), in which case it's C-M-\ was there before t-m-m was the default. t-m-m by default just made the binding not as useful as it used to be by default, but people might still be using it. TAB is a simple solution, it works by default. We cannot provide generic solutions for all non-default options. > worthwhile to consider whether certain keyboards have difficulty > generating that event, or it's not, in which case we can just get rid of > the keybinding altogether now that TMM is the default and have one more > available for user customization (for those users on whose keyboards it is > a convenient chord). Saying "it's a bad keybinding but we really don't > want it anyway" strikes me as nonsensical. I have not said or implied anything of the sort. ^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2009-11-30 21:05 UTC | newest] Thread overview: 12+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- [not found] <6bd43112-0ffd-482a-be72-0cbb579ed1b8@o13g2000vbl.googlegroups.com> [not found] ` <87tywc9gpi.fsf@ergodik.univ-brest.fr> 2009-11-30 15:58 ` auto-indent in emacs Lennart Borgman 2009-11-30 16:48 ` Sebastian Rose 2009-11-30 17:06 ` Lennart Borgman 2009-11-30 18:11 ` Lennart Borgman 2009-11-30 19:22 ` Lennart Borgman 2009-11-30 21:05 ` Sebastian Rose 2009-11-30 17:26 ` Dan Nicolaescu 2009-11-30 19:20 ` Davis Herring 2009-11-30 19:23 ` Dan Nicolaescu 2009-11-30 19:39 ` Davis Herring 2009-11-30 19:44 ` Lennart Borgman 2009-11-30 20:08 ` Dan Nicolaescu
Code repositories for project(s) associated with this public inbox https://git.savannah.gnu.org/cgit/emacs.git This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).