Just dealt with an issue with my app/game where I didn't know that setSize didn't adjust the RenderWindow's view as well.
My proposed patch would have an optional(default value would be false) boolean flag appended to the sf::RenderWindow::setSize() method that controls whether setSize would also resize the application's view. It wouldn't break API compatibility since it's defaulted to false while allowing future users to automatically resize their view to match their window size.
Quick snippet of how I would go about it.
//Window.h
void setSize(const Vector2u size, bool autoResizeView = false);
//snip
//Window.cpp
void Window::setSize(const Vector2u size,bool autoResizeView)
{
if (m_impl)
{
m_impl->setSize(size);
if(autoResizeView)
m_impl->setView(View(Vector2u(size.x / 2, size.y / 2), size));
}
}
Or if you don't wish to go down that route, I suggest updating the documentation of setSize to explicitly state that it doesn't affect the render window's view.