-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
vector symbol size calculation is incorrect #2276
Comments
Author: tbonfort |
Author: havatv I agree that we should not allow negative values anymore, and shifting symbols to avoid negative coordinate values is acceptable for all cases, as far as I can see.
In order to create polygon fill symbols in a flexible way, it is extremely useful that it is possible to specify the left and "bottom" part of the symbol to be "blank" (see a simple example in the figure below). If the symbol coordinates are shifted down to (0,0), this possibility will be lost.
The "lower" corner of the bounding box of the points used to specify a vector symbol must be allowed to have x and y values greater than 0. Maintaining the desired behaviour for polygon fills could be achieved by changing:
to:
or (to save a for loop):
I reopen the ticket.
|
Author: tbonfort |
Author: havatv I think we should strive to make things as consistent (and easily documentable) as possible, and of course also as logical as possible. You know the implications for the rest of the code, so you can decide. I am fine with both solutions. Whatever we decide, it should be mentioned in the migration guide (even if the current behaviour is not documented...), and the docs have to be updated. I can update the docs, but I don't have edit rights to the migration guide, so someone else will have to handle that. |
Reporter: tbonfort
Date: 2011/12/08 - 14:55
in vector symbols, if any of the coordinates contain negative values, or if min(x) or min(y) is not exactly 0, then the size calculations and the positionning of the symbol is incorrect.
people used these kind of point coordinates to be able to offset the rendering of vector symbols, but this kind of usage is now unnecessary as we have ANCHORPOINT support
I suggest that we now translate the input vector points to ensure they are all positive and that min(x) = min(y) = 0
The text was updated successfully, but these errors were encountered: