Re: Modifying Info.plist at runtime
Re: Modifying Info.plist at runtime
- Subject: Re: Modifying Info.plist at runtime
- From: Evan Gross <email@hidden>
- Date: Fri, 17 Feb 2006 05:15:44 -0500
- Thread-topic: Modifying Info.plist at runtime
On 2/11/06 3:07 PM, "Filipp Lepalaan" <email@hidden> wrote:
> I've sort of hit a vicious cycle trying to create a spell checker that would
> support other languages.
<snip>
> This however has to be defined already in the spellchecker's Info.plist,
> otherwise the choices simply don't show up in the list of spell checkers.
>
Yep, kind of ridiculous.
> Yeah, I guess there's no sure way to do this (and spellcheckers run with
> individual users' permissions so the write access problem's kind of a show
> stopper).
> I guess one way to deal with it is to distribute dictionary packs as
> installers that just add an entry to the spellcheckers Info.plist.
> It just seems like the lack of modularity is one reason why the spellchecker
> "aftermarket" is so fragmented, especially after the major languages've been
> included in the OS box.
There is actually a way to accomplish what you want. What you need to do is
create an add-on service on-the-fly based on which languages are actually
installed. Save the file to the user's home Library/Services directory,
update the services menu, and kill and re-launch your spell server (if
necessary) so it (re)registers its languages.
Definitely much more work than it should be, but the same approach has
worked since Jaguar.
Feel free to take a look at what my product (Spell Catcher X) does if that
will help. Note that it may not be necessary to create an actual helper app
like I do just for spell server languages - a properly-created bundle with
just an Info.plist may be enough. I have to do much more because of the
other types of dynamic services my product uses.
If your product is a stand-alone spell server, you'll need some sort of
installer or updater app to do some of the work (like terminating and
re-launching your spell server). If you can get away with forcing the user
to log out and in again after installing or removing languages, then the
procedure should be simpler.
> And I've filed a bugreport on the misleading documentation.
I think it's more of a hole in the spellserver/services API (one of many
IMO) than a documentation issue...
Hope that helps,
Evan Gross
--
+------------------------------------------------------------------------+
| Evan Gross, President, Rainmaker Research Inc. |
| - Developers of Macintosh and Windows Software - |
| Spell Catcher for Mac OS and Windows |
| Visit <http://www.rainmakerinc.com> |
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden