次の方法で共有


Text Services: Language Bar

If your text service wishes to display some UI on the language bar, then your service will need to create objects that implement one (or more) of the following interfaces:

Interface

How Obtained

ITfLangBarItem

Pass this base interface to ITfLangBarItemMgr::AddItem

ITfLangBarItemButton

Derived from ITfLangBarItem

ITfLangBarItemBitmapButton

Derived from ITfLangBarItem

ITfLangBarItemBitmap

Derived from ITfLangBarItem

ITfLangBarItemBalloon

Derived from ITfLangBarItem

If your text service has an object that implements ITfLangBarItem (or one of its subclasses), and that object updates the item, that object must also implement ITfSource (and call ITfLangBarItemSink::OnUpdate) so that TSF can redraw the language bar correctly.  See the article in MSDN on Implementing a Language Bar Object, and the sample source code.