[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Link preview generation with new link preview property
From: |
Ihor Radchenko |
Subject: |
Re: Link preview generation with new link preview property |
Date: |
Mon, 30 Dec 2024 17:05:59 +0000 |
Björn Bidar <bjorn.bidar@thaodan.de> writes:
>> It looks like you are respecting the alignment specifications, set via
>> org-image-align or the :align property of #+attr_*, but not the :width
>> property. Is the idea that the preview implementation that provides the
>> image should independently use org-display-inline-image--width?
>
> The width is set before the inline image is created. I'm not sure how
> this should be handled. Is the with set when creating the inline image
> Ihor?
> If the width is set before the image is created how should it be handled
> in
> the preview image-data function?
Both alignment and width are derived from LINK AST node.
I am not sure what is the problem.
AFAIU, Karthik is simply asking why you decided to calculate alignment
from LINK, but not width.
>> At minimum this requires making org-display-inline-image--width a public
>> function. But it would be good for org-link-preview-image-data to
>> respect both properties.
>
> I agree with both but I'm not sure what should be done on this.
If we think about the API function to be more useful, we can derive
alignment and width from LINK itself by default, but also provide
optional parameters, so that the caller can override the values
manually. If both alignment and width parameters are explicitly
specified, LINK does not have to be provided.
--
Ihor Radchenko // yantar92,
Org mode maintainer,
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>
- Re: Link preview generation with new link preview property, (continued)
- Re: Link preview generation with new link preview property, Karthik Chikmagalur, 2024/12/16
- Re: Link preview generation with new link preview property, Ihor Radchenko, 2024/12/17
- Re: Link preview generation with new link preview property, Björn Bidar, 2024/12/19
- Re: Link preview generation with new link preview property, Karthik Chikmagalur, 2024/12/19
- Re: Link preview generation with new link preview property, Ihor Radchenko, 2024/12/21
- Re: Link preview generation with new link preview property, Björn Bidar, 2024/12/23
- Message not available
- Re: Link preview generation with new link preview property, Karthik Chikmagalur, 2024/12/26
- Re: Link preview generation with new link preview property, Björn Bidar, 2024/12/29
- Re: Link preview generation with new link preview property,
Ihor Radchenko <=
- Re: Link preview generation with new link preview property, stardiviner, 2024/12/18
- Re: Link preview generation with new link preview property, Karthik Chikmagalur, 2024/12/18
- Re: Link preview generation with new link preview property, Björn Bidar, 2024/12/19
- Re: Link preview generation with new link preview property, Ihor Radchenko, 2024/12/21