Clipboard and soft hyphens

J

jpnewsgroup

When I copy and paste text from Word (11.2.x-11.3) into other text
capable applications other than TextEdit (e.g. TextWrangler, BBEdit,
TexEdit Plus, QuarkXPress) I get the soft hyphens created by Word's
autohyphenation converted to hard hyphens. The problem is consistent in
all versions of systemt 10.4.x and on Intel and PPC.

The problem is gone if I quit Word before I do the paste-command.
 
C

Clive Huggan

Thanks for letting us know this!

Cheers,

Clive Huggan
Canberra, Australia
(My time zone is 5-11 hours different from the US and Europe, so my
follow-on responses to those regions can be delayed)
============================================================
 
J

John McGhie [MVP - Word and Word Macintosh]

Nice pick-up! That's an "unintended consequence" of being quite clever
during copy and paste.

When you copy and paste in Word, Word does not usually put any text on the
clipboard until you "paste". It sets a "marker" in the source document.

It then waits to see where you are going to paste the text. When you hit
Paste, the receiving application advises the clipboard of the list of text
formats that it can accept.

Word looks up the list and picks the "richest" format. It then uses its
export filters to produce that format and move the requested format to the
clipboard for pasting. This way, Word can customise the output to best suit
the needs of the receiving application.

However, if you Copy and then Quit, Word is forced to populate the
clipboard. It does this in XML or RTF format (depending which version of
Word).

If You paste while Word is running, it helpfully converts the discretionary
hyphens to real hyphens when producing "plain text" for applications calling
for "text", assuming they can support only ANSI characters. However, most
"text" applications these days run in Unicode, which does contain the
discretionary hyphen character.

Hopefully, Microsoft will put that on the list for fixing in the next
version...

Cheers


When I copy and paste text from Word (11.2.x-11.3) into other text
capable applications other than TextEdit (e.g. TextWrangler, BBEdit,
TexEdit Plus, QuarkXPress) I get the soft hyphens created by Word's
autohyphenation converted to hard hyphens. The problem is consistent in
all versions of systemt 10.4.x and on Intel and PPC.

The problem is gone if I quit Word before I do the paste-command.

--

Please reply to the newsgroup to maintain the thread. Please do not email
me unless I ask you to.

John McGhie <[email protected]>
Microsoft MVP, Word and Word for Macintosh. Business Analyst, Consultant
Technical Writer.
Sydney, Australia +61 (0) 4 1209 1410
 
J

jpnewsgroup

Great! It completely explains my observation. But why doesn't Word
understand all those applications that accepts clipboard content
formatted as RTF-text?

It seems that there is some kind of format negotiation that goes wrong
between Word and the different text capable applications that I have
tested with.

thanks again,

Jacob

John McGhie [MVP - Word and Word Macintosh] skrev:
 
J

John McGhie [MVP - Word and Word Macintosh]

Hi Jacob:

Just because an application publishes the fact that it accepts RTF does NOT
mean it can accept Unicode :)

The discretionary hyphen is a Unicode character. My guess is that if the
application does not announce that it can accept UTF-16, it will be sent
ANSI, in which the discretionary hyphen will be converted to a fixed hyphen.

Cheers

Great! It completely explains my observation. But why doesn't Word
understand all those applications that accepts clipboard content
formatted as RTF-text?

It seems that there is some kind of format negotiation that goes wrong
between Word and the different text capable applications that I have
tested with.

thanks again,

Jacob

John McGhie [MVP - Word and Word Macintosh] skrev:
Nice pick-up! That's an "unintended consequence" of being quite clever
during copy and paste.

When you copy and paste in Word, Word does not usually put any text on the
clipboard until you "paste". It sets a "marker" in the source document.

It then waits to see where you are going to paste the text. When you hit
Paste, the receiving application advises the clipboard of the list of text
formats that it can accept.

Word looks up the list and picks the "richest" format. It then uses its
export filters to produce that format and move the requested format to the
clipboard for pasting. This way, Word can customise the output to best suit
the needs of the receiving application.

However, if you Copy and then Quit, Word is forced to populate the
clipboard. It does this in XML or RTF format (depending which version of
Word).

If You paste while Word is running, it helpfully converts the discretionary
hyphens to real hyphens when producing "plain text" for applications calling
for "text", assuming they can support only ANSI characters. However, most
"text" applications these days run in Unicode, which does contain the
discretionary hyphen character.

Hopefully, Microsoft will put that on the list for fixing in the next
version...

Cheers




--

Please reply to the newsgroup to maintain the thread. Please do not email
me unless I ask you to.

John McGhie <[email protected]>
Microsoft MVP, Word and Word for Macintosh. Business Analyst, Consultant
Technical Writer.
Sydney, Australia +61 (0) 4 1209 1410

--

Please reply to the newsgroup to maintain the thread. Please do not email
me unless I ask you to.

John McGhie <[email protected]>
Microsoft MVP, Word and Word for Macintosh. Business Analyst, Consultant
Technical Writer.
Sydney, Australia +61 (0) 4 1209 1410
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top