Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/xslt/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Flutter 自动滚动到搜索的单词flatter_Flutter - Fatal编程技术网

Flutter 自动滚动到搜索的单词flatter

Flutter 自动滚动到搜索的单词flatter,flutter,Flutter,我正在开发一个搜索应用程序栏。我想在写完单词后自动滚动到搜索到的单词 我的代码 SingleChildScrollView( controller: _controller, child: SelectableText.rich( TextSpan( children: [ TextSpan(text: "long text",)]),

我正在开发一个搜索应用程序栏。我想在写完单词后自动滚动到搜索到的单词

我的代码

SingleChildScrollView(
        controller: _controller,
        child: SelectableText.rich(
          TextSpan(
              children: [
                TextSpan(text: "long text",)]),
                 textAlign: TextAlign.center,
        ),
)

目前还没有这样的包/小部件可用于执行此操作。最好的选择是删除不需要的数据。这样,自动书写的单词将出现在顶部。