Eclipse Platform
Release 3.1

org.eclipse.help
Interface IContext2

All Superinterfaces:
IContext

public interface IContext2
extends IContext

Extends IContext to provide support for styled text and topic categorization.

Since:
3.1

Method Summary
 String getCategory(IHelpResource topic)
          Returns the category of the provided topic.
 String getStyledText()
          Returns the text description for this context with bold markers.
 String getTitle()
          Returns the optional title for this context.
 
Methods inherited from interface org.eclipse.help.IContext
getRelatedTopics, getText
 

Method Detail

getTitle

public String getTitle()
Returns the optional title for this context. If the title is specified, it will be used for the presentation of this context. Otherwise, a default title will be used.

Returns:
the title to use for this context or null to use the default title.

getStyledText

public String getStyledText()
Returns the text description for this context with bold markers. The markers are used to allow the UI to distinguish between bold markup and bold tags that are intended to remain part of the original text.

Returns:
String with <@#$b>and to mark bold range (as IContext.getText() used to in 2.x)

getCategory

public String getCategory(IHelpResource topic)
Returns the category of the provided topic. The category will be used in the UI to render all the topics that belong to the same category grouped together. The category string is expected to be NL-ready i.e. presentable in all NL locales.

Parameters:
topic - the topic to be categorized
Returns:
the presentable name of the category that the topic belongs to, or null if the topic belongs to the default category.

Eclipse Platform
Release 3.1

Guidelines for using Eclipse APIs.

Copyright (c) IBM Corp. and others 2000, 2005. All rights reserved.