### Discussed in https://github.com/quarto-dev/quarto-cli/discussions/3826

<div type='discussions-op-text'>

<sup>Originally posted by **astoeriko** January  2, 2023</sup>
In my document, I would like to have some figures in the main column, and some figures as smaller images in the margin column. The figures in the main column should have their caption in the margin. However, the margin figures should have their captions below the image, not next to them.

I can place the captions of main-column figures in the margin by setting the option `cap-location: margin` in the yaml block.
However, that option messes up my margin figures. They will be too wide for the margin because 1) the image size increases and 2) their captions now appear next to them.

Can I locally override the caption placement? Or can I set it globally but differentiating between main-column and margin figures?

This is a minimum example showing what I mean:

```
---
cap-location: margin
---

![This is a figure that will be placed in the main column. However, its caption should be in the margin.](test.jpg){#fig-main-col}


::: {.column-margin}
![This figure is in the margin. I would like its caption to be right below the image, but it appears next to it, making the margin too wide.](test.jpg){#fig-margin-col}
:::

::: {.column-margin}
![This figure is in the margin. Its caption will not be visible.](test.jpg){#fig-margin-col2}
I can cheat a bit and write my caption below manually. However, it will not be a real caption. For example, it is not numbered, and the vertical spacing seems to be wrong.
:::
```

It looks like this for me:
![image](https://user-images.githubusercontent.com/42246615/210289269-be735980-5c5b-481a-a633-e0ce7756c39c.png)
</div>
dragonstyle
2023-01-03T01:41:56Z
dragonstyle
v1.3
closed
Don't reposition caption in margin figures when `cap-location: margin`
https://github.com/quarto-dev/quarto-cli/issues/3829