develooper Front page | perl.pod-people | Postings from October 2020

Re: [feature] Add =image to perl pod #18169

Thread Previous | Thread Next
From:
Patrice Dumas
Date:
October 4, 2020 19:23
Subject:
Re: [feature] Add =image to perl pod #18169
Message ID:
20201004192313.GC247598@free.fr
On Sun, Oct 04, 2020 at 05:11:35PM +0200, Dmitry Karasik wrote:
> Hello
> 
> Thank you all for review, it is clear that some things I wasn't focused at
> don't fall in as gracefully as I wanted. So it seems that P<> neither serves
> any good as an inline image anchor, nor versatile enough to specity
> accompanying text, and will require further additions to pod that would break
> backward compatibility. 
> 
> Having all of that in mind, I reworked the proposal, and here it's next iteration:
> 
> 1) Full syntax (somewhat YAML-inspired)
> 
> =begin image
> 
> src: file.png
> title: Figure.1
> comment:
> 	This is a multi-line
> 	comment. Must start end end with newline.
> 	Prefix spaces are skipped.
> 
> resolution: 120
> whatever: value
> 
> text:
> 	This is fallback text
> 	shown where graphics is unavailable
> 	but the formatter is smart and knows
> 	the =image tag.
> 
> =end image
> 
> 2) Short syntax that should cover 90% of use-cases
> 
> =for image src:file.png

Are spaces ignored between :?  Should there be a separator to simplify
parsing, like

=for image src:file.png, text:something

> 
> I think that covers it all now. What do you think?

It handles well my remarks.  It is quite complicated for pod, but I'll
let true poders (podlers?) comment further.

-- 
Pat

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About