tabs/script/text library

A text widget to display the R script for the SCRIPT tab.

Copyright (C) 2023-2025, Togaware Pty Ltd.

License: GNU General Public License, Version 3 (the "License") https://opensource.org/license/gpl-3-0

Authors: Graham Williams

Classes

ScriptText
Create a script text viewer that can scroll the text of the script widget.
ScriptTextState

Functions

buildHighlightSpans(String text, String query, List<int> matchIndices, int currentMatchIndex) List<TextSpan>
Build text spans highlighting matches of query in text. matchIndices contains the starting indices of each occurrence. The match at the current index (specified by currentMatchIndex) is highlighted in other color.