AppendRune adds one rune and associated formatting info
(r rune, face font.Face, clr image.Image, bg image.Image, deco styles.TextDecorations)
| 158 | |
| 159 | // AppendRune adds one rune and associated formatting info |
| 160 | func (sr *Span) AppendRune(r rune, face font.Face, clr image.Image, bg image.Image, deco styles.TextDecorations) { |
| 161 | sr.Text = append(sr.Text, r) |
| 162 | rr := Rune{Face: face, Color: clr, Background: bg, Deco: deco} |
| 163 | sr.Render = append(sr.Render, rr) |
| 164 | sr.HasDecoUpdate(bg, deco) |
| 165 | } |
| 166 | |
| 167 | // AppendString adds string and associated formatting info, optimized with |
| 168 | // only first rune having non-nil face and color settings |
no test coverage detected