SFML community forums

Help => Graphics => Topic started by: MrMou6 on February 24, 2015, 03:37:36 pm

Title: Window right and left sides
Post by: MrMou6 on February 24, 2015, 03:37:36 pm
Hi, i draw two rectangles:
padas1.setPosition(sf::Vector2f(10, (waukstis/2)-25));
padas2.setPosition(sf::Vector2f(wilgis-10, (waukstis / 2) - 25));
and i get this:
(http://i.imgur.com/TWv96G3.png?1)
why these spaces is different?
Title: Re: Window right and left sides
Post by: Laurent on February 24, 2015, 03:51:52 pm
Second one should be wilgis - 10 - width. Don't forget that by default, the position refers to the top-left corner.