質問

I'm writing my thesis in Sublime Text 3 but can't seem to work out how to resize the images that I need to insert. Or how to wrap the text around the images. Any ideas?

This is how I'm inserting images:

![Agential Realism](/Users/fdudhwala/Dropbox/DPhil/Thesis_Chapters/Barad_Chapter/Images/agential_intra-action1.png)

I want to make the images a little smaller.

I also want to know how to align the picture to the left/centre/right, and then wrap my text around it....

役に立ちましたか?

解決

This question is actually unrelated to Sublime Text. You are writing a markdown document which could be written in any text editor; the particular editor has no control over how your document is rendered to HTML (and the sizing of images is part of this rendering). This is instead decided by the markdown interpreter and the content of the document.

There are several widely used versions of the Markdown interpreter that support different features. Most do not support special syntax for resizing images, but MultiMarkdown does. Adapted from the docs:

This is a formatted ![image][] and a [link][] with attributes.

...more text...

[image]: http://path.to/image "Image title" width=40px height=400px
[link]:  http://path.to/link.html "Some Link" class=external
         style="border: solid black 1px;"

Note that this syntax lets you insert arbitrary HTML attributes for images and links.

On another note, one of the great things about Markdown (all versions of the interpreter) is that you can just use HTML when you need to. So, if you don't use MultiMarkdown, in place of your current markdown image syntax you could put this to make a 200 by 200 image:

<img src="/path/to/your/image.jpg" style="width: 200px;height: 200px"/>

Finally, you can resize the images before insertion using a program like imagemagick.

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top