Thanks you for your answer, thanks for the tips, I will see that in detail.
Le ven. 4 nov. 2022 à 05:53, Ihor Radchenko <yanta...@posteo.net> a écrit : > Cletip Cletip <clement020...@gmail.com> writes: > > > My problem is quite simple to understand: when I activate > > "org-toggle-inline-images", I would like my images to be centered. > Indeed, > > I tried this in a org-file > > > > #+ATTR_ORG: :width 800 :center t > > > > [[file:images/anImage.png]] > > > > > > But it obviously doesn't work. > > AFAIK, there is no easy way to do this, especially if you want the > centering to be preserved on resize. > > > Does anyone have a tip? > > > > (I'm thinking of creating a function that, each time the size of the > window > > changes, readjusts the number of spaces to put so that my image is > > centered. It's not a very clean solution, but could it work?) > > What you are thinking is probably the only sane way. Though you do not > have to insert actual spaces. May instead use display property. See > 40.16.3 Pixel Specification for Spaces section of Elisp manual. > > -- > Ihor Radchenko // yantar92, > Org mode contributor, > Learn more about Org mode at <https://orgmode.org/>. > Support Org development at <https://liberapay.com/org-mode>, > or support my work at <https://liberapay.com/yantar92> >