# [OS X TeX] avoid space when pasting in TeXShop

Ross Moore ross at ics.mq.edu.au
Sat Apr 1 20:37:28 EST 2006

Hi all,

On 01/04/2006, at 4:13 AM, Adam R. Maxwell wrote:

>
> On Mar 31, 2006, at 09:02, Charilaos Skiadas wrote:
>
>> On Mar 31, 2006, at 10:36 AM, Justin C. Walker wrote:
>>
>>>  - if you double-click TEST, and TEST is a word by itself (spaces/
>>> newlines surround it), then pasting *will* include the spaces.
>>>
>> Hm, this certainly seems to be a "feature" in NSTextView, the view
>> that TeXShop is using. If you select the word by double-clicking,
>> it seems to understand that you selected a word and will insert it
>> "smartly", adding spaces as it sees appropriate. Same thing
>> happens in TextEdit.

This annoys me a lot, from time to time.
On the other hand, when you double click to select a macro-name
(such as \alpha) for copy-paste, then the \ comes along for the ride.

This is very desirable when editing (La)TeX source, especially
examples of coding tricks.
(In Textures, Alpha, and other editors you would have to drag across
the  word + escape-char  to get it all.)

So one just learns to live with it, and make good use of it when
possible.

>>
>> My guess then is that this can not be easily turned off, i.e. it
>> is not something TeXShop is doing, it's the system's behavior.
>
> Looks like it can be disabled with setSmartInsertDeleteEnabled:NO
> (but then you have an inconsistent user experience).

There's a big difference between editing the text of a manuscript
and the coding of a computer program.
So I don't know what the relevance of "consistency" means here.

Surely the most relevant thing is to be able to turn such
effects on and off, so as to see what is most convenient for

>
> --------

Cheers,

Ross

------------------------------------------------------------------------
Ross Moore                                         ross at maths.mq.edu.au
Mathematics Department                             office: E7A-419
Macquarie University                               tel: +61 +2 9850 8955
Sydney, Australia  2109                            fax: +61 +2 9850 8114
------------------------------------------------------------------------

------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/