Difference between text and IText in fabricJS

Can someone tell me what makes fabric.IText different from fabric.Text ? Can I look at any demo? Only the official Fabric tutorial describes the text , and I see no difference in usage in the official IText demo .

+5
source share
1 answer

In the text: you can set any style (e.g. fill, textBackgroundColor, fontSize ... etc.), it will be applied to the whole text.

But in IText: you can set styles to β€œany number of characters (you selected)” from your text, and it will only apply to the selected part of the text.

To select characters from Itext you can use:

+22
source

Source: https://habr.com/ru/post/1201776/


All Articles