* Re: New Link Syntax: Adding ATTRIBUTES (Was: org-e-html: Including ATTR_HTML)
@ 2012-06-15 0:53 William Crandall
2012-06-15 4:14 ` New Link Syntax: Adding ATTRIBUTES Thomas S. Dye
2012-06-15 15:15 ` New Link Syntax: Adding ATTRIBUTES (Was: org-e-html: Including ATTR_HTML) Avdi Grimm
0 siblings, 2 replies; 6+ messages in thread
From: William Crandall @ 2012-06-15 0:53 UTC (permalink / raw)
To: Nicolas Goaziou; +Cc: emacs-orgmode, Jambunathan K
Hello Nicolas,
Many thanks for expanded clarity, and a new direction.
On Thu, Jun 14, 2012 at 2:51 AM,
Nicolas Goaziou <n.goaziou@gmail.com> wrote:
> I understand your problem, but inserting ATTR_HTML
> keywords in a paragraph isn't possible anymore. I cannot
> allow that as it would defeat a fundamental change in the
> new Org syntax.
This is good. While not familiar with the details, I clearly
see the value of maintaining the logical integrity of the new
architecture.
> ATTR_HTML could ... accept a list of properties that would
> be applied in order to each link in the paragraph. But it
> wouldn't scale well...
Agreed; this is not the way to go.
> I'm open to any other suggestion. For example, link's
> syntax could be extended to allow attributes.
I like this idea, and think it is the way to go.
--------------------------------------------------
One approach would be to expand the current link syntax
from TWO to THREE pairs of square brackets.
Current syntax:
http://orgmode.org/org.html#Link-format
New syntax:
[[link]]
[[link][description]]
[[link][description][ATTRIBUTES]]
Description and attributes would be optional.
ATTRIBUTES would consisting of name:value pairs, perhaps
giving names export-type prefixes, such as HTML_STYLE and
HTML_TITLE, or LATEX_PDFBORDER and LATEX_URLCOLOR.
HTML ATTRIBUTES would map to HTML 'attributes':
http://www.w3.org/TR/html5/section-index.html#attributes-1
LATEX ATTRIBUTES would map to Latex \hypersetup 'options':
http://en.wikibooks.org/wiki/LaTeX/Hyperlinks#.5Chyperref
(Subsection: Customization)
--------------------------------------------------
This would be a significant change, but it would make LINKS
"first class objects," and allow Org mode users to directly
apply rich families of link attributes/options.
The Manual should then indicate that ATTR_HTML is a
/paragraph/-level mechanism, and is no longer intended
for use with links:
http://orgmode.org/org.html#Links-in-HTML-export
There may, of course, be different/better solutions.
Thanks for continuing to move this forward!
-BC
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: New Link Syntax: Adding ATTRIBUTES
2012-06-15 0:53 New Link Syntax: Adding ATTRIBUTES (Was: org-e-html: Including ATTR_HTML) William Crandall
@ 2012-06-15 4:14 ` Thomas S. Dye
2012-06-19 2:29 ` Samuel Wales
2012-06-15 15:15 ` New Link Syntax: Adding ATTRIBUTES (Was: org-e-html: Including ATTR_HTML) Avdi Grimm
1 sibling, 1 reply; 6+ messages in thread
From: Thomas S. Dye @ 2012-06-15 4:14 UTC (permalink / raw)
To: William Crandall; +Cc: emacs-orgmode, Nicolas Goaziou, Jambunathan K
William Crandall <bc3141592@gmail.com> writes:
> Hello Nicolas,
>
> Many thanks for expanded clarity, and a new direction.
>
> On Thu, Jun 14, 2012 at 2:51 AM,
> Nicolas Goaziou <n.goaziou@gmail.com> wrote:
>
>> I understand your problem, but inserting ATTR_HTML
>> keywords in a paragraph isn't possible anymore. I cannot
>> allow that as it would defeat a fundamental change in the
>> new Org syntax.
>
> This is good. While not familiar with the details, I clearly
> see the value of maintaining the logical integrity of the new
> architecture.
>
>> ATTR_HTML could ... accept a list of properties that would
>> be applied in order to each link in the paragraph. But it
>> wouldn't scale well...
>
> Agreed; this is not the way to go.
>
>
>> I'm open to any other suggestion. For example, link's
>> syntax could be extended to allow attributes.
>
> I like this idea, and think it is the way to go.
> --------------------------------------------------
>
> One approach would be to expand the current link syntax
> from TWO to THREE pairs of square brackets.
>
> Current syntax:
> http://orgmode.org/org.html#Link-format
>
> New syntax:
>
> [[link]]
>
> [[link][description]]
>
> [[link][description][ATTRIBUTES]]
>
>
> Description and attributes would be optional.
>
> ATTRIBUTES would consisting of name:value pairs, perhaps
> giving names export-type prefixes, such as HTML_STYLE and
> HTML_TITLE, or LATEX_PDFBORDER and LATEX_URLCOLOR.
>
> HTML ATTRIBUTES would map to HTML 'attributes':
>
> http://www.w3.org/TR/html5/section-index.html#attributes-1
>
> LATEX ATTRIBUTES would map to Latex \hypersetup 'options':
>
> http://en.wikibooks.org/wiki/LaTeX/Hyperlinks#.5Chyperref
> (Subsection: Customization)
>
>
> --------------------------------------------------
>
> This would be a significant change, but it would make LINKS
> "first class objects," and allow Org mode users to directly
> apply rich families of link attributes/options.
>
> The Manual should then indicate that ATTR_HTML is a
> /paragraph/-level mechanism, and is no longer intended
> for use with links:
> http://orgmode.org/org.html#Links-in-HTML-export
>
> There may, of course, be different/better solutions.
>
> Thanks for continuing to move this forward!
>
> -BC
>
>
Is Samuel Wales' extensible syntax proposal germane?
http://article.gmane.org/gmane.emacs.orgmode/10204/match=link+syntax
All the best,
Tom
--
Thomas S. Dye
http://www.tsdye.com
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: New Link Syntax: Adding ATTRIBUTES (Was: org-e-html: Including ATTR_HTML)
2012-06-15 0:53 New Link Syntax: Adding ATTRIBUTES (Was: org-e-html: Including ATTR_HTML) William Crandall
2012-06-15 4:14 ` New Link Syntax: Adding ATTRIBUTES Thomas S. Dye
@ 2012-06-15 15:15 ` Avdi Grimm
2012-06-19 1:47 ` William Crandall
1 sibling, 1 reply; 6+ messages in thread
From: Avdi Grimm @ 2012-06-15 15:15 UTC (permalink / raw)
To: William Crandall; +Cc: emacs-orgmode, Nicolas Goaziou, Jambunathan K
[-- Attachment #1: Type: text/plain, Size: 792 bytes --]
On Thu, Jun 14, 2012 at 8:53 PM, William Crandall <bc3141592@gmail.com>wrote:
> ATTRIBUTES would consisting of name:value pairs, perhaps
> giving names export-type prefixes, such as HTML_STYLE and
> HTML_TITLE, or LATEX_PDFBORDER and LATEX_URLCOLOR.
>
> HTML ATTRIBUTES would map to HTML 'attributes':
>
> http://www.w3.org/TR/html5/section-index.html#attributes-1
>
> LATEX ATTRIBUTES would map to Latex \hypersetup 'options':
>
> http://en.wikibooks.org/wiki/LaTeX/Hyperlinks#.5Chyperref
> (Subsection: Customization)
>
>
> --------------------------------------------------
>
> This would be a significant change, but it would make LINKS
> "first class objects," and allow Org mode users to directly
> apply rich families of link attributes/options.
>
>
I really like this idea!
--
Avdi
[-- Attachment #2: Type: text/html, Size: 1359 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: New Link Syntax: Adding ATTRIBUTES (Was: org-e-html: Including ATTR_HTML)
2012-06-15 15:15 ` New Link Syntax: Adding ATTRIBUTES (Was: org-e-html: Including ATTR_HTML) Avdi Grimm
@ 2012-06-19 1:47 ` William Crandall
0 siblings, 0 replies; 6+ messages in thread
From: William Crandall @ 2012-06-19 1:47 UTC (permalink / raw)
To: Avdi Grimm; +Cc: emacs-orgmode, Nicolas Goaziou, Jambunathan K
Hello Avdi,
I'm glad you like it!
On Fri, Jun 15, 2012 at 8:15 AM, Avdi Grimm <groups@inbox.avdi.org> wrote:
> I really like this idea!
>
This change may be Herculean--giving links full access to
target attributes--but I certainly hope not.
As I thought about it, it seems like fair amount of abstraction will be
possible, creating one org-attribute name that would export appropriately
to each target, without attaching destination prefixes to every item.
But some will likely need to be target specific.
Thanks again,
-BC
> On Thu, Jun 14, 2012 at 8:53 PM, William Crandall <bc3141592@gmail.com>
> wrote:
>>
>> ATTRIBUTES would consisting of name:value pairs, perhaps
>> giving names export-type prefixes, such as HTML_STYLE and
>> HTML_TITLE, or LATEX_PDFBORDER and LATEX_URLCOLOR.
>>
>> HTML ATTRIBUTES would map to HTML 'attributes':
>>
>> http://www.w3.org/TR/html5/section-index.html#attributes-1
>>
>> LATEX ATTRIBUTES would map to Latex \hypersetup 'options':
>>
>> http://en.wikibooks.org/wiki/LaTeX/Hyperlinks#.5Chyperref
>> (Subsection: Customization)
>>
>>
>> --------------------------------------------------
>>
>> This would be a significant change, but it would make LINKS
>> "first class objects," and allow Org mode users to directly
>> apply rich families of link attributes/options.
>>
>
> I really like this idea!
>
> --
> Avdi
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: New Link Syntax: Adding ATTRIBUTES
2012-06-15 4:14 ` New Link Syntax: Adding ATTRIBUTES Thomas S. Dye
@ 2012-06-19 2:29 ` Samuel Wales
2012-06-19 20:11 ` Thomas S. Dye
0 siblings, 1 reply; 6+ messages in thread
From: Samuel Wales @ 2012-06-19 2:29 UTC (permalink / raw)
To: Thomas S. Dye
Cc: emacs-orgmode, William Crandall, Nicolas Goaziou, Jambunathan K
Hmm, maybe something like this:
$[link "http://mysite.example" :label "Example" :html-attr "..."
:latex-attr "..."]
Code that adds functionality or safety to this syntax (including all
future code) will also apply to other features than links. For a new
feature, replace the first element with id, fancy-date, or whatever
idea you have. It might even be possible to open it up to the user in
a safe and convenient way.
Samuel
--
The Kafka Pandemic: http://thekafkapandemic.blogspot.com
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: New Link Syntax: Adding ATTRIBUTES
2012-06-19 2:29 ` Samuel Wales
@ 2012-06-19 20:11 ` Thomas S. Dye
0 siblings, 0 replies; 6+ messages in thread
From: Thomas S. Dye @ 2012-06-19 20:11 UTC (permalink / raw)
To: Samuel Wales
Cc: William Crandall, emacs-orgmode, Nicolas Goaziou, Jambunathan K
Samuel Wales <samologist@gmail.com> writes:
> Hmm, maybe something like this:
>
> $[link "http://mysite.example" :label "Example" :html-attr "..."
> :latex-attr "..."]
>
> Code that adds functionality or safety to this syntax (including all
> future code) will also apply to other features than links. For a new
> feature, replace the first element with id, fancy-date, or whatever
> idea you have. It might even be possible to open it up to the user in
> a safe and convenient way.
>
> Samuel
Neat idea. IIUC, a read macro and something like funcall would do a lot
of the work.
I'd like to see something like this, so the Org-mode buffer could
reflect the underlying, possibly user-extended, semantics:
$[link "http://mysite.example" :label "Example" :html-attr "..."
:latex-attr "..." :org-attr "..."]
All the best,
Tom
--
Thomas S. Dye
http://www.tsdye.com
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2012-06-19 20:12 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-06-15 0:53 New Link Syntax: Adding ATTRIBUTES (Was: org-e-html: Including ATTR_HTML) William Crandall
2012-06-15 4:14 ` New Link Syntax: Adding ATTRIBUTES Thomas S. Dye
2012-06-19 2:29 ` Samuel Wales
2012-06-19 20:11 ` Thomas S. Dye
2012-06-15 15:15 ` New Link Syntax: Adding ATTRIBUTES (Was: org-e-html: Including ATTR_HTML) Avdi Grimm
2012-06-19 1:47 ` William Crandall
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.