StyledText.setLineBackground

Sets the background color of the specified lines. <p> The background color is drawn for the width of the widget. All line background colors are discarded when setText is called. The text background color if defined in a StyleRange overlays the line background color. </p><p> Should not be called if a LineBackgroundListener has been set since the listener maintains the line backgrounds. </p><p> All line attributes are maintained relative to the line text, not the line index that is specified in this method call. During text changes, when entire lines are inserted or removed, the line attributes that are associated with the lines after the change will "move" with their respective text. An entire line is defined as extending from the first character on a line to the last and including the line delimiter. </p><p> When two lines are joined by deleting a line delimiter, the top line attributes take precedence and the attributes of the bottom line are deleted. For all other text changes line attributes will remain unchanged. </p>

@param startLine first line the color is applied to, 0 based @param lineCount number of lines the color applies to. @param background line background color @exception SWTException <ul> <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li> <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li> </ul> @exception IllegalArgumentException <ul> <li>ERROR_INVALID_ARGUMENT when the specified line range is invalid</li> </ul>

class StyledText
void
setLineBackground

Meta