Skip to content

SelectableText widget supports WidgetSpan #38474

@chunhtai

Description

@chunhtai
Contributor

Currently SelectableText.rich can only support textspan. We would like to be able to support different type of inlinespan eventually as Text.rich did.

This might require some discussions on how should we deal with copying or pasting a widgetspan.

Activity

added
c: new featureNothing broken; request for a new capability
frameworkflutter/packages/flutter repository. See also f: labels.
f: material designflutter/packages/flutter/material repository.
a: qualityA truly polished experience
on Aug 13, 2019
zmtzawqlp

zmtzawqlp commented on Nov 10, 2019

@zmtzawqlp
Contributor

_textPainter.getOffsetForCaret return Offset.zero for WidgetSpan. _textPainter.getBoxesForSelection is right for WidgetSpan, so I do a workaround for get caret position with selection boxs.

but at version is high than 1.7.8 , _textPainter.getBoxesForSelection is also breaking. selection function about WidgetSpan are all breaking for https://github.com/fluttercandies/extended_text and https://github.com/fluttercandies/extended_text_field.

i look forward that it will be fixed asap.

AlexV525

AlexV525 commented on Dec 9, 2019

@AlexV525
Member

Is there any updates?

zmtzawqlp

zmtzawqlp commented on Dec 19, 2019

@zmtzawqlp
Contributor

getPositionForOffset always return 0, after 1.7.8

AxesandGrinds

AxesandGrinds commented on Apr 22, 2020

@AxesandGrinds

It's 2020 April, any update on this?

chunhtai

chunhtai commented on Apr 22, 2020

@chunhtai
ContributorAuthor

I would like to gather some feedbacks on what does it mean to copy and paste a widget span.

If possible, please share your use cases that require widget span selection.

41 remaining items

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    a: qualityA truly polished experiencec: new featureNothing broken; request for a new capabilitycustomer: crowdAffects or could affect many people, though not necessarily a specific customer.f: material designflutter/packages/flutter/material repository.frameworkflutter/packages/flutter repository. See also f: labels.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Participants

      @snoe@daohoangson@justinmc@goderbauer@GaryQian

      Issue actions

        SelectableText widget supports WidgetSpan · Issue #38474 · flutter/flutter