Issue 106497 - linguistic: languages incorrectly marked as supported
Summary: linguistic: languages incorrectly marked as supported
Alias: None
Product: Writer
Classification: Application
Component: code (show other issues)
Version: DEV300m63
Hardware: All All
: P3 Trivial (vote)
Target Milestone: ---
Assignee: stefan.baltzer
QA Contact: issues@sw
Keywords: regression
Depends on:
Blocks: 99999
  Show dependency tree
Reported: 2009-10-30 16:16 UTC by caolanm
Modified: 2013-08-07 14:44 UTC (History)
2 users (show)

See Also:
Issue Type: PATCH
Latest Confirmation in: ---
Developer Difficulty: ---

empty entry for a language shouldn't be added when requesting non-existing support (504 bytes, patch)
2009-10-30 16:18 UTC, caolanm
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this issue.
Description caolanm 2009-10-30 16:16:22 UTC
If the document language does *not* have any spellchecker installed and the
first application launched is draw or impress then the edit engine in svx will
immediately try and spell check with that language. In lingucomponent there is
the code of...

LangSvcEntries_Spell *pEntry = aSvcMap[ nLanguage ].get();

so even though the pEntry returned is NULL, given how maps work, we have *added*
that nLanguage to the map so now if you use format->character the language will
have a little check box beside it because that language now appears in the map
even though we don't really have any support for it.

There's a few other uses of the map like this, might be worth checking the rest
of them too, but here's a patch to fix the immediate instance
Comment 1 caolanm 2009-10-30 16:18:09 UTC
Created attachment 65803 [details]
empty entry for a language shouldn't be added when requesting non-existing support
Comment 2 thomas.lange 2009-11-03 08:36:32 UTC
Comment 3 thomas.lange 2009-11-04 09:38:58 UTC
TL->CMC: Thanks for finding this weird one! 

As discussed with SBA, changing target to OOo 3.2 now.
Comment 4 thomas.lange 2009-11-04 09:54:08 UTC
Note: The very same problem will apply to the Thesaurus and Hyphenator as well.
The only difference is that it is not that readily visible in the UI. But
internally Thesaurus and Hyphenator will be reported as found when they are not

Will fix those cases as well.
Comment 5 thomas.lange 2009-11-04 11:02:26 UTC
Fixed in CWS fwk125.

Files changed in project linguistic:
M      hyphdsp.cxx
M      spelldsp.cxx
M      thesdsp.cxx

Patch itself should be without risk (just about the same two lines changes at
several places).
Comment 6 stefan.baltzer 2009-11-04 14:22:45 UTC
SBA->TL: As discussed, the scenario "invites" to get such fake entries and thus
generating support requests and hard-to-understand issues. Works for non-Western
languages, too. It is a regression (could not reproduce in OOo 3.0).
Comment 7 thomas.lange 2009-11-11 09:31:10 UTC
Comment 8 stefan.baltzer 2009-11-17 13:05:29 UTC
Verified in CWS fwk125.
Comment 9 stefan.baltzer 2009-12-01 11:03:22 UTC
OK in OOO320_m6. Closed.