Skip to main content
New Participant
July 14, 2011
Answered

CFDocument and small caps

  • July 14, 2011
  • 1 reply
  • 1412 views

I have a paragraph tag inside a CFDOCUMENTITEM tag in a CFDOCUMENT tag with a CSS style of "...font-variant:small-caps;..." but the text isn't being rendered as small caps. I'm getting the problem with or without FONTEMBED and also if the small caps paragraph is in the body of the document instead of in the CFDOCUMENTITEM tag. Any suggestions?

Running ColdFusion 9.0.1.274733, Standard edition, on Windows 2003 (5.2).

Code...

<cfdocument
  format="PDF"
  margintop="1.1"
  marginbottom="1.1"
  marginright="0.4"
  marginleft="0.4"
  orientation="portrait"
  unit="in"
  backgroundvisible="yes"
  fontembed="yes"
  filename="..."
  overwrite="yes"
>
  <cfdocumentitem type="header">
    <p style="height:20px"> </p>
    <p style="
      border           : 2px solid #557799;
      font-family      : Georgia, Verdana, Arial, Helvetica, sans-serif;
      font-size        : 13pt;
      font-weight      : bold;
      font-variant     : small-caps;
      color            : #FFFFFF;
      background-color : #7799BB;
      padding          : 5px 0px 3px 0px;
      margin           : 0px;
      text-align       : center;
      vertical-align   : middle;
    ">Sample Text</p>
  </cfdocumentitem>
.
.
.

    This topic has been closed for replies.
    Correct answer Sean Coyne

    The list of supported CSS styles for CFDocument can be found here: http://livedocs.adobe.com/coldfusion/8/htmldocs/Tags_d-e_05.html#4015343

    font-variant is not supported by CFDocument

    1 reply

    New Participant
    October 13, 2011

    Did you ever figure out a work-around or find out if this just isn't an option? I've tried applying my small-caps style every way I can possibly think of to no avail. If I take away the <cfdocument...> the HTML renders fine and even passes validation on W3C. I'm assuming that PDFs just don't support that style. I just wanted to see if you had any other info on this since I can't seem to find any other posts from users trying to do this.

    Thanks!

    Sean Coyne
    Sean CoyneCorrect answer
    Participating Frequently
    October 13, 2011

    The list of supported CSS styles for CFDocument can be found here: http://livedocs.adobe.com/coldfusion/8/htmldocs/Tags_d-e_05.html#4015343

    font-variant is not supported by CFDocument

    New Participant
    October 13, 2011

    Thanks for the info Sean. I feel better knowing that it is a limitation rather than not knowing how to do it.

    Thanks,

    Emily