MCPcopy Create free account
hub / github.com/microsoft/SandDance / fitSize

Function fitSize

docs/app/js/sanddance-app.js:134080–134088  ·  view source on GitHub ↗
(projection, size, object)

Source from the content-addressed store, hash-verified

134078 }, object);
134079}
134080function fitSize(projection, size, object) {
134081 return fitExtent(projection, [
134082 [
134083 0,
134084 0
134085 ],
134086 size
134087 ], object);
134088}
134089function fitWidth(projection, width, object) {
134090 return fit(projection, function(b) {
134091 var w = +width, k = w / (b[1][0] - b[0][0]), x = (w - k * (b[1][0] + b[0][0])) / 2, y = -k * b[0][1];

Callers

nothing calls this directly

Calls 1

fitExtentFunction · 0.70

Tested by

no test coverage detected