You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
8.2 equivalent transform of an SVG viewport, step 7 and 8.
If align is not 'none' and meetOrSlice is 'meet', set the larger of scale-x and scale-y to the smaller.
I initially read this to say:
if align != SVG_VALUE_NONE and meet_or_slice == 'meet':
scale_x = scale_y = max(scale_x, scale_y)
The phrase larger of scale_x and scale_y sounded like max(scale_x, scale_y) then set that value to the one that wasn't the max the smaller which made sense, because the larger was already set to that. Set the larger value of the variables scale_x and scale_y and set the smaller variable to equal that value. Which is to say both variables have the larger value.
But, debugging clearly takes it to mean min(scale_x, scale_y) Which means I interpreted that wrongly, and it took a few reading for me to see the other way to take it. It means find whether scale_x or scale_y is larger then set the value of that larger variable to the value of the smaller variable. Which is to say both variables have the smaller value.
set the larger of scale-x and scale-y to the smaller.
Set the register holding the larger value to the equal that of the smaller value.
Set the register holding the smaller value equal to the larger value of scale_x or scale_y.
The line: Otherwise, if align is not 'none' and meetOrSlice is 'slice', set the smaller of scale-x and scale-y to the larger -- Has the same ambiguity. smaller could be smaller value or register containing the smaller value. And larger could equally mean register containing the larger value or the value which is larger.
The text was updated successfully, but these errors were encountered:
"Set x to y" is generally not ambiguous in English: it means "set variable x to value y".
I can't think of a case where it means "set value x into variable y" - that sounds awkward. "Put value into variable" maybe.
I'm just a bystander with an interest in the future of SVG. I sympathize, having tripped over similar phrases, but I don't think there is ambiguity here.
That isn't ambiguous, but it's not what it says. It says "set the larger of x and y to the smaller." That actually seems to be kind of ambiguous. As I can easily read that to mean set the larger value to the smaller variable, which in this case creates a bug.
Since larger of x and y can only be a reference to the value of the variable and not something which strictly speaking identifies it. The word larger there can only refer to the value and programmatically that easily means max(scale-x, scale-y) since that's the larger, but it wants the larger variable given the smaller value. I think it should read:
If align is not 'none' and meetOrSlice is 'meet', set the larger variable of scale-x and scale-y to the smaller value.
or:
If align is not 'none' and meetOrSlice is 'meet', set scale-x and scale-y to the smaller value
This implies setting the smaller value to itself, but that's pretty unambiguous that it means scale_x = scale_y = min(scale_x,scale_y).
8.2 equivalent transform of an SVG viewport, step 7 and 8.
I initially read this to say:
The phrase
larger of scale_x and scale_y
sounded like max(scale_x, scale_y) then set that value to the one that wasn't the maxthe smaller
which made sense, because the larger was already set to that. Set the larger value of the variables scale_x and scale_y and set the smaller variable to equal that value. Which is to say both variables have the larger value.But, debugging clearly takes it to mean
min(scale_x, scale_y)
Which means I interpreted that wrongly, and it took a few reading for me to see the other way to take it. It means find whether scale_x or scale_y is larger then set the value of that larger variable to the value of the smaller variable. Which is to say both variables have the smaller value.set the larger of scale-x and scale-y to the smaller.
The line:
Otherwise, if align is not 'none' and meetOrSlice is 'slice', set the smaller of scale-x and scale-y to the larger
-- Has the same ambiguity. smaller could be smaller value or register containing the smaller value. And larger could equally mean register containing the larger value or the value which is larger.The text was updated successfully, but these errors were encountered: