# Formatting Attributes

**URL:** <https://discourse.citationstyles.org/t/formatting-attributes/682>\
**Category:** CSL Development\
**Created:** [July 8, 2009, 5:53pm UTC](https://discourse.citationstyles.org/t/formatting-attributes/682 "2009-07-08T17:53:05Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![Rintze\_Zelle](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.citationstyles.org/rintze_zelle/32/175_2.png) [@Rintze\_Zelle](https://discourse.citationstyles.org/u/Rintze_Zelle)\
**Post date:** [July 8, 2009, 5:53pm UTC](https://discourse.citationstyles.org/t/formatting-attributes/682/1 "2009-07-08T17:53:05Z")

</div>

I’ve been working through the formatting attributes for the spec (  
[http://sourceforge.net/apps/trac/xbiblio/changeset/1051](http://sourceforge.net/apps/trac/xbiblio/changeset/1051)), and I’ve got some  
questions:

- should all the formatting attributes (quotes, italics, text-case) also  
work on the affixes? Currently Zotero doesn’t take them along, but I don’t  
know whether that’s the desired behavior.
- I still don’t understand inline-block. I’ve found this page,  
[http://www.quirksmode.org/css/display.html#inlineblock](http://www.quirksmode.org/css/display.html#inlineblock), but that seems to  
suggest inline-block only has use when you specify a width.
- how do you know what the options are for “font-family”. I guess that  
Zotero can draw on the fonts available within Firefox, but how does this  
work for a standalone CSL processor? Are then the system-fonts available?

Rintze

---

<div class="post-metadata">

**Author:** ![Bruce\_D\_Arcus1](https://avatars.discourse-cdn.com/v4/letter/b/4bbf92/32.png) [@Bruce\_D\_Arcus1](https://discourse.citationstyles.org/u/Bruce_D_Arcus1)\
**Post date:** [July 8, 2009, 8:25pm UTC](https://discourse.citationstyles.org/t/formatting-attributes/682/2 "2009-07-08T20:25:04Z")

</div>

> I’ve been working through the formatting attributes for the spec  
> ([XBib download | SourceForge.net](http://sourceforge.net/apps/trac/xbiblio/changeset/1051)), and I’ve got some  
> questions:
> 
> - should all the formatting attributes (quotes, italics, text-case) also  
> work on the affixes? Currently Zotero doesn’t take them along, but I don’t  
> know whether that’s the desired behavior.

This is a decision we need to make. Once case where they clearly  
should is with superscript for citation marks.

> - I still don’t understand inline-block. I’ve found this page,  
> [CSS2 - The display declaration](http://www.quirksmode.org/css/display.html#inlineblock), but that seems to  
> suggest inline-block only has use when you specify a width.

See the threads on the zotero forums about the damned anthropology styles.

> - how do you know what the options are for “font-family”. I guess that  
> Zotero can draw on the fonts available within Firefox, but how does this  
> work for a standalone CSL processor? Are then the system-fonts available?

I think we should remove this option entirely. It serves no useful  
purpose, and adds needless complexity.

Bruce

---

<div class="post-metadata">

**Author:** ![Frank\_Bennett](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.citationstyles.org/frank_bennett/32/198_2.png) [@Frank\_Bennett](https://discourse.citationstyles.org/u/Frank_Bennett)\
**Post date:** [July 8, 2009, 9:05pm UTC](https://discourse.citationstyles.org/t/formatting-attributes/682/3 "2009-07-08T21:05:45Z")

</div>

> > I’ve been working through the formatting attributes for the spec  
> > ([XBib download | SourceForge.net](http://sourceforge.net/apps/trac/xbiblio/changeset/1051)), and I’ve got some  
> > questions:
> > 
> > - should all the formatting attributes (quotes, italics, text-case) also  
> > work on the affixes? Currently Zotero doesn’t take them along, but I don’t  
> > know whether that’s the desired behavior.
> 
> This is a decision we need to make. Once case where they clearly  
> should is with superscript for citation marks.

The new processor applies formatting in a different order on the  
layout element in order to capture affixes to the layout, but I think  
a uniform order of application can safely be used everywhere, if it’s  
made a bit more fine-grained than I now have it. From innermost to  
outermost:

text-case  
text-decoration  
font-style, font-weight, font-variant, \*font-family  
(pre-quote punctuation from suffix)  
quotes  
affixes (less pre-quote punctuation)  
vertical-align

- If at all – I like Bruce’s idea of dropping font-family.

---

<div class="post-metadata">

**Author:** ![Bruce\_D\_Arcus1](https://avatars.discourse-cdn.com/v4/letter/b/4bbf92/32.png) [@Bruce\_D\_Arcus1](https://discourse.citationstyles.org/u/Bruce_D_Arcus1)\
**Post date:** [July 8, 2009, 9:14pm UTC](https://discourse.citationstyles.org/t/formatting-attributes/682/4 "2009-07-08T21:14:44Z")

</div>

> > > I’ve been working through the formatting attributes for the spec  
> > > ([XBib download | SourceForge.net](http://sourceforge.net/apps/trac/xbiblio/changeset/1051)), and I’ve got some  
> > > questions:
> > > 
> > > - should all the formatting attributes (quotes, italics, text-case) also  
> > > work on the affixes? Currently Zotero doesn’t take them along, but I don’t  
> > > know whether that’s the desired behavior.
> > 
> > This is a decision we need to make. Once case where they clearly  
> > should is with superscript for citation marks.
> 
> The new processor applies formatting in a different order on the  
> layout element in order to capture affixes to the layout, …

FWIW, in my code, the formatting attributes always stay with the  
content strings. So it doesn’t really make any difference to me.

But there is an open question about the correct behavior. For example,  
if you (gasp) have an underlined title, then it looks wrong to have  
the affixes underlined too. So I think we’re going to have to make  
these calls for each of the formatting attributes, unfortunately. Feel  
free to make suggestions.

---

<div class="post-metadata">

**Author:** ![Frank\_Bennett](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.citationstyles.org/frank_bennett/32/198_2.png) [@Frank\_Bennett](https://discourse.citationstyles.org/u/Frank_Bennett)\
**Post date:** [July 8, 2009, 9:30pm UTC](https://discourse.citationstyles.org/t/formatting-attributes/682/5 "2009-07-08T21:30:16Z")

</div>

That’s what I had done. 🙂 I’m saying that for any rendering  
element, applying the formatting attributes to its content in the  
order I’ve suggested will produce correct output in all cases.

---

<div class="post-metadata">

**Author:** ![Bruce\_D\_Arcus1](https://avatars.discourse-cdn.com/v4/letter/b/4bbf92/32.png) [@Bruce\_D\_Arcus1](https://discourse.citationstyles.org/u/Bruce_D_Arcus1)\
**Post date:** [July 8, 2009, 9:41pm UTC](https://discourse.citationstyles.org/t/formatting-attributes/682/6 "2009-07-08T21:41:32Z")

</div>

Doh!

OK, so you’re suggesting I put this in the spec more-or-less as is, as  
an ordered list?

Bruce

---

<div class="post-metadata">

**Author:** ![Frank\_Bennett](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.citationstyles.org/frank_bennett/32/198_2.png) [@Frank\_Bennett](https://discourse.citationstyles.org/u/Frank_Bennett)\
**Post date:** [July 8, 2009, 10:26pm UTC](https://discourse.citationstyles.org/t/formatting-attributes/682/7 "2009-07-08T22:26:06Z")

</div>

> > > Feel  
> > > free to make suggestions.
> > > 
> > > > but I think a uniform order of application can safely be used everywhere, if it’s  
> > > > made a bit more fine-grained than I now have it. From innermost to  
> > > > outermost:
> > > > 
> > > > text-case  
> > > > text-decoration  
> > > > font-style, font-weight, font-variant, \*font-family  
> > > > (pre-quote punctuation from suffix)  
> > > > quotes  
> > > > affixes (less pre-quote punctuation)  
> > > > vertical-align
> > 
> > That’s what I had done. 🙂 I’m saying that for any rendering  
> > element, applying the formatting attributes to its content in the  
> > order I’ve suggested will produce correct output in all cases.
> 
> Doh!
> 
> OK, so you’re suggesting I put this in the spec more-or-less as is, as  
> an ordered list?

Yes – it hasn’t been implemented or tested, but if neither you nor  
Rintze pick up any problems with it, I’d like to give it a try.

---

<div class="post-metadata">

**Author:** ![Rintze\_Zelle](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.citationstyles.org/rintze_zelle/32/175_2.png) [@Rintze\_Zelle](https://discourse.citationstyles.org/u/Rintze_Zelle)\
**Post date:** [July 9, 2009, 5:46am UTC](https://discourse.citationstyles.org/t/formatting-attributes/682/8 "2009-07-09T05:46:44Z")

</div>

If I recall correctly, in my lifelong experience as CSL style author (:P) I  
only ever had trouble with a lack of affix-superscripting in citation  
clusters. Any rare cases where affixes should receive all the same  
formatting as the main output can always be handled with a conditional and  
separate text element for the affixes, e.g.:

 \> 

Alternatively the output can be put into a group, specifying the markup:

 \> 

Label output doesn’t even need the conditional. The only limitation of  
Frank’s suggestion I can come up with is formatting of the affixes of the  
layout element in citation. You wouldn’t be able to specify (Doe 1999, 2000;  
Johson 2000) with everything in bold, right? E.g. by using ‘\<layout  
font-weight=“bold” prefix="(" suffix=") delimiter="; "\>’. Now that I think  
of it: Frank, does your CSL processor currently format delimiters as  
specified in the calling rendering element, as is the case in the current  
Zotero CSL processor\*? I think that’s desired behavior.

\*With I  
get:

(_Baranowska et al., 2009; Fayed, 2008; Gerstein, 2008_) [i.e. the delimiters show up as italics, but the affixes don’t]

RintzeOn Thu, Jul 9, 2009 at 12:26 AM, Frank Bennett \<@Frank\_Bennett\>wrote:

---

<div class="post-metadata">

**Author:** ![Frank\_Bennett](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.citationstyles.org/frank_bennett/32/198_2.png) [@Frank\_Bennett](https://discourse.citationstyles.org/u/Frank_Bennett)\
**Post date:** [July 9, 2009, 7:58am UTC](https://discourse.citationstyles.org/t/formatting-attributes/682/9 "2009-07-09T07:58:29Z")

</div>

By golly, you’re right. And that’s something a style might want –  
superscripting plus boldface. So maybe what the processor does right  
now is more correct.\*\*

The current setup works like this:

(a) On ordinary rendering elements, applying formatting attributes  
first, then affixes, in the following order, with jiggery-pokery for  
punctuation and quotes:

text-case  
text-decoration  
font-style  
font-weight  
font-variant  
\*font-family  
(pre-quote punctuation from suffix)  
quotes  
vertical-alignOn Thu, Jul 9, 2009 at 2:46 PM, Rintze Zelle\<@Rintze\_Zelle\> wrote:

> On Thu, Jul 9, 2009 at 12:26 AM, Frank Bennett \<@Frank\_Bennett\> \> wrote:
> 
> > > > > > but I think a uniform order of application can safely be used  
> > > > > > everywhere, if it’s  
> > > > > > made a bit more fine-grained than I now have it. From innermost to  
> > > > > > outermost:
> > > > > > 
> > > > > > text-case  
> > > > > > text-decoration  
> > > > > > font-style, font-weight, font-variant, \*font-family  
> > > > > > (pre-quote punctuation from suffix)  
> > > > > > quotes  
> > > > > > affixes (less pre-quote punctuation)  
> > > > > > vertical-align
> > > > 
> > > > That’s what I had done. 🙂 I’m saying that for any rendering  
> > > > element, applying the formatting attributes to its content in the  
> > > > order I’ve suggested will produce correct output in all cases.
> > > 
> > > Doh!
> > > 
> > > OK, so you’re suggesting I put this in the spec more-or-less as is, as  
> > > an ordered list?
> > 
> > Yes – it hasn’t been implemented or tested, but if neither you nor  
> > Rintze pick up any problems with it, I’d like to give it a try.
> 
> If I recall correctly, in my lifelong experience as CSL style author (:P) I  
> only ever had trouble with a lack of affix-superscripting in citation  
> clusters. Any rare cases where affixes should receive all the same  
> formatting as the main output can always be handled with a conditional and  
> separate text element for the affixes, e.g.:
> 
> \> 
> 
> Alternatively the output can be put into a group, specifying the markup:
> 
> \> 
> 
> Label output doesn’t even need the conditional. The only limitation of  
> Frank’s suggestion I can come up with is formatting of the affixes of the  
> layout element in citation. You wouldn’t be able to specify (Doe 1999, 2000;  
> Johson 2000) with everything in bold, right?

- 

affixes (less pre-quote punctuation)

(b) On layout, apply affixes first, then formatting, as follows:

affixes  
+  
text-case  
text-decoration  
font-style  
font-weight  
font-variant  
\*font-family  
quotes  
vertical-align

\*\* “Correct” is looking more elastic to me with every passing day,  
pretty soon it will have achieved the amorphous transcendence of terms  
like “cool” and “legal in Nevada”.

Frank

> E.g. by using ‘\<layout  
> font-weight=“bold” prefix=“(” suffix=“) delimiter=”; "\>’. Now that I think  
> of it: Frank, does your CSL processor currently format delimiters as  
> specified in the calling rendering element, as is the case in the current  
> Zotero CSL processor\*? I think that’s desired behavior.
> 
> \*With I  
> get:
> 
> (_Baranowska et al., 2009; Fayed, 2008; Gerstein, 2008_) [i.e. the delimiters show up as italics, but the affixes don’t]

Yes, delimiters would be boldfaced there. To avoid that, the bold  
would go a group enclosing the full content of the layout. The group  
would apply to each cite, while the layout applies to the result of  
rendering all of the cites.

---

<div class="post-metadata">

**Author:** ![Bruce\_D\_Arcus1](https://avatars.discourse-cdn.com/v4/letter/b/4bbf92/32.png) [@Bruce\_D\_Arcus1](https://discourse.citationstyles.org/u/Bruce_D_Arcus1)\
**Post date:** [July 9, 2009, 1:06pm UTC](https://discourse.citationstyles.org/t/formatting-attributes/682/10 "2009-07-09T13:06:00Z")

</div>

Can I suggest that as these issues come up and people have ideas for  
how they should be dealt with, that you just add them to the spec  
document\*?

Bruce

- csl/doc/specification.mdml
