I don't know what specifically are you trying to do, but I'll post a brief example of my idea.
Say you have a quad and you define it before the loop:
sf::Vertex vertices[] =
{
sf::Vertex(sf::Vector2f( 0, width), sf::Color::Red),
sf::Vertex(sf::Vector2f( width, width), sf::Color::Red),
sf::Vertex(sf::Vector2f(0, height), sf::Color::Red),
sf::Vertex(sf::Vector2f(width, heigth), sf::Color::Red)
};
///This is a straight vertical line.
///Color isn't relevant.
Then you want to make one side of your bold line to move with your cursor, so inside your loop you need something like this:
vertices[2].position = sf::Vector2i(sf::Mouse::getPosition().x + width/2, sf::Mouse::getPosition().y + heigth/2);
vertices[3].position = sf::Vector2i(sf::Mouse::getPosition().x - width/2, sf::Mouse::getPosition().y - height/2);
///Note that this isn't tested, but it kind of goes like this.
That would be a fast approach but it gives many problems, first is that if you move your mouse to certain positions it will not display the line properly (or even not at all). This only works if you want something extremely simple, when I gave the idea I didn't give it much thought. It would work on a line certainly, but not on a quad.
The approach that would really work is to use the rotation matrix in all the vertices positions, first you calculate the angle of where the mouse is according to the bold line's first two positions (use the mid point between both as an origin of angle calculation) and then you multiply each position vector using the rotation matrix with the angle that the mouse was calculated in. The height of line would depend if you want it to be fixed or to be extended as far as the mouse is located.
http://en.wikipedia.org/wiki/Rotation_matrixAs you can see it has a lot of linear algebra underneath, if it was a single line it would be as easy as changing the end point position, but given you want a bold line you need a quad, which requires mathematical rotation and so on.
Alternatively you could also use the not so efficient method of putting lots of lines in a VertexArray together so that they look like a bold line even though they are just many lines next to each other, it's easier to program (just change the end position of all of the with mouse position), but you may end up using a lot of vertexes for something that needs only four in the end.
http://www.sfml-dev.org/documentation/2.0/classsf_1_1Vertex.phphttp://www.sfml-dev.org/documentation/2.0/classsf_1_1Mouse.php#a93b4d2ebef728e77a0ec9d83c1e0b0c8http://www.sfml-dev.org/documentation/2.0/classsf_1_1VertexArray.phpThen again it all depends if you want a fixed height parameter. I just gave some bases of how it should be done, but it varies greatly on how you want to use mouse position for your bold line. The linear algebra approach is on order to get consistency in your bold lines (always same width, height maybe if you wish so). The first approach I listed can work if you don't care about it.