[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: About abbrevs and spaces at end of line
From: |
Harry Putnam |
Subject: |
Re: About abbrevs and spaces at end of line |
Date: |
Wed, 11 Dec 2013 07:29:48 -0500 |
User-agent: |
Gnus/5.130008 (Ma Gnus v0.8) Emacs/24.0.92 (gnu/linux) |
Andreas Röhler <andreas.roehler@easy-emacs.de> writes:
> Am 10.12.2013 12:08, schrieb Harry Putnam:
>> Andreas Röhler <andreas.roehler@easy-emacs.de> writes:
>>
>>> Am 09.12.2013 22:46, schrieb Harry Putnam:
>>>> Is there some smooth way to avoid having a space at the end of line
>>>> when activating an abbrev as the last thing done before newline?
>>
>> [...]
>>
>>>> The short and long is: Invoking with spc leaves unsightly marks like
>>>> an underscore if done at the end of a line and invoking with <RET> is
>>>> not always desirable if a new line is not needed.
>>
>> [...]
>>
>>>>
>>>> I have visions of some tricky way of setting up an abbrev with hardly
>>>> any more effort than the normal
>>>>
>>>> M-x edit-abbrevs <RET>
>>>>
>>>> "tru" 0 "\"TRUE\";"
>>>>
>>>> In the cperl-table, then pressing C-c
>>>>
>>>> Where I only need to edit the cperl abbrev table.
>>>>
>>>>
>>>>
>>>>
>>>
>>> Problem results from binding abbrev-expand to SPACE.
>>> Abbrev is expanded, than SPACE is inserted, as you typed it.
>>>
>>> Solution: abbrev-mode off. Use any other key to M-x expand-abbrev RET.
>>> This will expand it, but not insert a space.
>>
>> Thank you.
>>
>> After looking into this a bit, I'm not seeing a handy way to set
>> something else permanently.
>>
>> In fact it appears there are nearly half a dozen ways to invoke
>> expansion.
>>
>> space, <RET>, C-x ' (At least two more key combos that I already
>> forgot)
>>
>> So there must be a list or regex or something.
>>
>
> Do you mean "list of keys"?
I'm suggesting there must already be a list of keys that invoke
expansion.
>> I'd like to add some other char to the list somehow.
>>
>
> Are you asking how to bind another key onto expand-abbrev command?
You seemed to be suggesting that could be done when you said:
>>> Solution: abbrev-mode off. Use any other key to M-x expand-abbrev RET.
>>> This will expand it, but not insert a space.
I was not sure what you mean by 'Use any other key . . . '