Let’s say that my NSTextView contains the following text:
Header Text For Section
This is some text for this section. Just about anything could be here.
So, I can easily set the background color of the text ‘Header Text For Section’ as shown here:

but the color ends at the end of the text and I would like it to extend to the end of the line as shown here:

What I am hoping is that this can be done without subclassing, but I expect subclassing will be necessary.
Try extending the color attribute (style run) to include the linefeed character at the end of the line.