On 31 Mar 2007, Michael Olson wrote:

> Jim Ottaway <[EMAIL PROTECTED]> writes:
>
>> (defun muse-publish-mark-inline (beg end atts)
>> (let ((style (cdr (assoc "style" atts))))
>> (if (and style
>> (or (equal (muse-style style)
>> muse-publishing-current-style)
>> (muse-style-derived-p
>> style
>> muse-publishing-current-style)))
>> (muse-publish-mark-read-only beg end)
>> (delete-region beg end))))
>
> Nifty!  Does the following also work?
>
> (defun muse-publish-mark-inline (beg end atts)
> (let ((style (cdr (assoc "style" atts))))
> (if (and style
> (muse-style-derived-p
> style
> muse-publishing-current-style))
> (muse-publish-mark-read-only beg end)
> (delete-region beg end))))

No, because

(muse-style-derived-p "latex" (muse-style "latex"))

returns nil, since latex isn't derived from itself.

I also thought that there should be an attribute to limit the check to
the style itself without looking to see if the style was derived,
something like 

<inline style="pdf" not-derived="true">

but I couldn't think of a good attribute name or determine an idiomatic
value [true, t, yes,...?].


Regards,

-- 
Jim Ottaway

_______________________________________________
Muse-el-discuss mailing list
[email protected]
https://mail.gna.org/listinfo/muse-el-discuss

Reply via email to