Bold or unbold?

Consider the following selections in a text editor:

enter image description here

At the end of the second line, there is an non-bold space.

For each example, when you click the Bold button, should it bold or unbold the selection?