Open jayaike opened 4 years ago
What is a Widget Tree?
Because it sounds like what you are describing is what zefyr does, convert a document to a tree of widget. (to display the document).
Zyfer, based on what I have seen so far, turns into json. Where the document is then defined with different keys such as "insert", "embed". How can I get it to show as, for example, RichText, TextSpan, etc. @cgestes
You can turn the list of insert into your widget tree if you want. would that fit your usecase?
On Wed, Feb 5, 2020 at 3:54 PM jayy notifications@github.com wrote:
Zyfer, based on what I have seen so far, turns into json. Where the document is then defined with different keys such as "insert", "embed". How can I get it to show as, for example, RichText, TextSpan, etc.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/memspace/zefyr/issues/243?email_source=notifications&email_token=AAAL75MDRC3Z53TONMUGHVTRBLHKZA5CNFSM4KQDXKJ2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEK3WTYI#issuecomment-582445537, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAAL75OOEIP2NX7JFIWEJVTRBLHKZANCNFSM4KQDXKJQ .
Yes it would! How can I do that that @cgestes
have a look here: https://github.com/memspace/zefyr/pull/194/files
Insead of generating html, generate your widget tree.
By the way, why can't you use zefyr for displaying the content (a ZefyrView for example)?
I am not too sure how to modify that PR to change it to widgets. @cgestes . It is actually pretty urgent so I might even have the time to modify the PR. Maybe later, I would be able to do that.
I didn't see any reference to ZyferView in the docs. Where can I get docs on that and how to use it?
Afaik you have to read the code. Its quite easy. Parameters are similar to ZefyrEditor.
But where is the code for the ZefyrView. I can't find any reference to it @cgestes
Thanks! I found some docs here https://pub.dev/documentation/zefyr/latest/zefyr/ZefyrView-class.html.
How do I make the image made with image delegate occupy full width and maintain aspect ratio?
Is there any way to export the document as a Widget Tree?
OR
Is there a function that can convert the document to a Widget Tree?
Maybe it would automatically decode the document format and insert the appropriate widget?