I have an editor like this
var container = document.getElementById('editor');
var quill = new Quill(container);
quill.setText('Hello\nWorld!\n');
Im trying to change the color of the first line to blue. When I use the formatLine method like this
quill.formatLine(0, 1, {
color: 'rgb(0, 255, 0)'
});
Nothing happens
When I change it to formatText I see a color change (only a single character though)
quill.formatText(0, 1, {
color: 'rgb(0, 255, 0)'
});
Im guessing that color changes fall under inline formatting and are ignored
Formats all lines in given range, returning a Delta representing the change. See formats for a list of available formats. Has no effect when called with inline formats.
Does anyone know how I would change the color of a specific line? Is it possible to get the start and end character indices of a specific line?