Comments (4)
Yes, scaleto
would be the same as scale --to --keep-proportions
, with an option to not keep proportions.
from vpype.
Thanks for the feedback, this is very useful. I see how this could be confusing.
On several occasions I did use the ability to do (relative) scale
with units in factors, especially when using script
or writing plugins. This allows me to use arbitrary units when generating geometries (for example a regular grid whose cells have unit width and height) and subsequently scale it to a predictable physical size (the unit-cell grid, when scaled with scale 1cm 1cm
, would then have 1cm-sized cells, irrespective of the number of cell). This (admittedly advanced) use-case leads me to reject (1) and, thus, (2).
Having a separate scaleto
command (for the lack of a better name) would definitely make sense, and would be easy to implement. I further think than it should default to the keep proportion behaviour since its the most common use-case, with an option to tight fit. Would that make sense to you? Any proposal for the command name?
from vpype.
Makes sense, I didn't think of this use case.
So as I understand the --to
parameter would be dropped and scaleto
would then be the same as what scale --to
is now? I don't have any preference on the naming to be honest...
from vpype.
Further commit d2be51f to default to keeping proportions.
from vpype.
Related Issues (20)
- `read` entirely discards file containing NaN
- Is there a way to use vpype to count the number of lines/paths in an svg file? HOT 1
- Pyside 6.5.0 breaking changes (Linux) HOT 1
- Enhancement suggestion -- allow getting document width/height in non-pixel units HOT 2
- Change the layer ID interpretation to match EMSL standard HOT 1
- `--fit-to-margins` adds boarder around margin HOT 1
- Curved Line Spacing Problem HOT 4
- Allow for `layout` arg to maintain size of svg element
- Output error messages when using `execute` from vpype API HOT 4
- Cursive font glyphs are split in multiple strokes HOT 2
- Examples in `lreverse`'help are wrong
- Add support for various stroke font format
- Remove mentions of `--page-size` in `layout` help
- Extra layer when running two read/writes within one pipeline HOT 1
- Color overwritten using dipping pattern recipe
- Request: linemerge option to only merge when turn angle is small HOT 1
- Is there a way to tostring() a Document? HOT 1
- Simplification fails in my installation (vpype read -s <svg_file>) HOT 1
- VirusTotal
- Site-packages pollution from README
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vpype.