"Look up " strangeness . . .

Everything related to our flagship word processor.
Post Reply
goldste4
Posts: 98
Joined: 2010-02-22 15:06:48

"Look up " strangeness . . .

Post by goldste4 »

Hello All,

Happily using NWP2 and discovered the other day that if I right-click a highlighted word I can "Look Up" the dictionary meaning of that word in a way similar to using Spotlight. Perhaps this feature had been there forever and I'm a little slow, who knows. In any case, here is what is happening on my install of NWP2 . . .

When I 'Look Up' a highlighted word that is near to the beginning of a paragraph, Look Up works perfectly (see the attached 'Look Up Okay After' for the expected results). However, as I try looking up words farther from the beginning of the paragraph a consistent weirdness erupts. Look Up shows the desired word highlighted and in context menu (see 'Look Up Problem Before') but actually looks up the end of the previous word and the first characters of the desired word (see 'Look Up Problem After').

Now, I can unfailingly replicate this problem with my install of NWP2 on different documents. The problem persists after restarting the computer. However, I can't replicate it on my wife's install of NWP2.

Obviously this problem is more in the realm of intrigue rather than something that is mission critical, but I thought I would pass it on anyway.

I'm using NWP2 2.0.2 and OS X 10.7.3 on mid-2010 macbook pro.

Thanks,
Josh

LOOK UP OKAY
Look Up Okay After.jpg
Look Up Okay After.jpg (91.86 KiB) Viewed 10085 times
LOOK UP PROBLEM BEFORE
Look Up Problem Before.jpg
Look Up Problem Before.jpg (34.84 KiB) Viewed 10085 times
LOOK UP PROBLEM AFTER
Look Up Problem After.jpg
Look Up Problem After.jpg (28.6 KiB) Viewed 10085 times
User avatar
Hamid
Posts: 777
Joined: 2007-01-17 03:25:42

Re: "Look up " strangeness . . .

Post by Hamid »

I cannot reproduce the problem. Perhaps clearing font caches will help.
goldste4 wrote:Perhaps this feature had been there forever ...
You are quite right.

Also, regardless of cursor position or selection, you can look up words from within Cocoa apps in Apple Dictionary/Thesaurus/Wikipedia (and any other installed dictionaries following the same protocol) by hovering the mouse over a word and pressing Command-Control-d and then releasing ‘d’ while holding Command-Control.
goldste4
Posts: 98
Joined: 2010-02-22 15:06:48

Re: "Look up " strangeness . . .

Post by goldste4 »

Thanks, Hamid, for the Cmd-Control-d tip.

Strangely, when I use Cmd-Control-d on a word in NWP2 I get the correct result. When I then try to "Look Up" that same word, I get the same problem. Also, just tried clearing the Font cache then restarting; no change.

Of course, now with the keyboard shortcut, I don't need the NWP2 "Look Up" feature anymore so this bug (or whatever) has produced one happy result. . .

Thanks again,
Josh
User avatar
martin
Official Nisus Person
Posts: 5227
Joined: 2002-07-11 17:14:10
Location: San Diego, CA
Contact:

Re: "Look up " strangeness . . .

Post by martin »

Do the documents where this problem occurs have any special kinds of content, say tables or images?
goldste4
Posts: 98
Joined: 2010-02-22 15:06:48

Re: "Look up " strangeness . . .

Post by goldste4 »

Hi Martin,

I think you have hit the nail on the head with the table causing the problem. Although I was testing the "Look Up" feature on a paragraph of text that was not in a table, the document does have a table in it above that paragraph. So, I just now tried starting a new file and typing in some plain text. Used the "Look Up" feature. Everything works. Then, I added a 3x3 table before the paragraph (entered some dummy text in two or three different cells), and when I went back to original paragraph to use "Look Up", the problem detailed in my first post appeared. Deleted the table, tried Look Up again, everything works exactly as it should. Added the table back in, the problem with Look Up returned. So, one portion of the mystery solved!

Josh
User avatar
martin
Official Nisus Person
Posts: 5227
Joined: 2002-07-11 17:14:10
Location: San Diego, CA
Contact:

Re: "Look up " strangeness . . .

Post by martin »

Excellent, thanks for verifying that Josh. Then your problem is actually the same as an issue we've already encountered.

The problem is with Apple's text engine, or at least a problem with how Apple's "look up" command decides what word is selected. You can observe the same problem in TextEdit: just insert an inline image into any document, and any look-ups following that image will be off one character. The effect is cumulative, so if you insert two images, any following look-ups will be off by two characters. Tables in Nisus Writer are internally implemented using something like an image, so each table row will contribute one unwanted look-up character shift.

This bug is new to OSX 10.7, and is something we've reported to Apple. Sorry for the trouble.
goldste4
Posts: 98
Joined: 2010-02-22 15:06:48

Re: "Look up " strangeness . . .

Post by goldste4 »

Thanks for the quick and enlightening follow up! Josh
Post Reply