fletcher / peg-multimarkdown

An implementation of MultiMarkdown in C, using a PEG grammar - a fork of jgm's peg-markdown. No longer under active development - see MMD 5.
Other
523 stars 55 forks source link

Added case to support scaling of LaTeX images #117

Closed michaelshiel closed 12 years ago

michaelshiel commented 12 years ago

Just added a quick case for something I needed in a document I am writing. The scale parameter is useful as it is the only way I am aware of to size an image with reference to it's own dimensions, rather than based on dimensions specified or in relation to the document width/height. First real usage of github so I hope I'm doing it right.

Thanks for the awesome multimarkdown either way.

fletcher commented 12 years ago

Why not just use something like the scale parameter that already exists?

width="50%"
michaelshiel commented 12 years ago

I had tried that, however the problem is that the percentage is relative to the document, rather than the image size. The scale parameter uses the inherent size of the image itself to determine the width. I have created an example to illustrate this better than I can explain it: https://github.com/michaelshiel/FileStorage

fletcher commented 12 years ago

I'll have to think about this - it will break parity with other output formats. I'm also trying to think about how often this would come up.

michaelshiel commented 12 years ago

I'll close this for now, since you are right in that it is a bit of a specific requirement. I hadn't thought of the parity issue either.