Return-Path: X-Original-To: apmail-forrest-user-archive@www.apache.org Delivered-To: apmail-forrest-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 014529539 for ; Wed, 1 Feb 2012 13:02:54 +0000 (UTC) Received: (qmail 25255 invoked by uid 500); 1 Feb 2012 13:02:53 -0000 Delivered-To: apmail-forrest-user-archive@forrest.apache.org Received: (qmail 25118 invoked by uid 500); 1 Feb 2012 13:02:52 -0000 Mailing-List: contact user-help@forrest.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: Reply-To: user@forrest.apache.org List-Id: Delivered-To: mailing list user@forrest.apache.org Received: (qmail 25111 invoked by uid 99); 1 Feb 2012 13:02:52 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 01 Feb 2012 13:02:52 +0000 X-ASF-Spam-Status: No, hits=-0.7 required=5.0 tests=RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of daddywri@gmail.com designates 209.85.215.48 as permitted sender) Received: from [209.85.215.48] (HELO mail-lpp01m010-f48.google.com) (209.85.215.48) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 01 Feb 2012 13:02:46 +0000 Received: by lagw12 with SMTP id w12so911445lag.21 for ; Wed, 01 Feb 2012 05:02:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; bh=b+WxIJ3ixBQHTG1z+7Ep/mjaFd51GhhNgqezoGugHGo=; b=QdLerP0Tm1ePk5RPbodpzaTX8Yl2Y1+TvrKgVj8N0ImLHboHgMQImhL01ttnawubMB 0DuYXv5yf3smBCDdJolAXXTB6iYthx4YSUsNavJEfvZflobIXEAMPgpGHJf9NxbLcjdp 9glnYUkybLth5IfBmxpMl0XwK1d3UXw910pn0= MIME-Version: 1.0 Received: by 10.152.147.103 with SMTP id tj7mr13656490lab.3.1328101344543; Wed, 01 Feb 2012 05:02:24 -0800 (PST) Received: by 10.112.36.37 with HTTP; Wed, 1 Feb 2012 05:02:24 -0800 (PST) In-Reply-To: References: <4F2221AB.6040905@ogis-ri.co.jp> Date: Wed, 1 Feb 2012 08:02:24 -0500 Message-ID: Subject: Re: Is there a decent way of using different PDF fonts for different parts of a Forrest site? From: Karl Wright To: user@forrest.apache.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable FWIW, the $path has just what I hoped in it and works well. Thanks! Karl On Tue, Jan 31, 2012 at 9:23 PM, Karl Wright wrote: >> Then, inside your own document-to-fo.xsl you should have access >> to a "path" parameter. =A0You may add an additional condition to the >> font of interest (e.g. rootFontFamily) that uses XSL string functions >> against your $path parameter. >> > > I've set things up so that my document path includes the language code > (e.g. 'en_US') as the first part of the path under > src/documentation/content/xdocs. =A0For example, > src/documentation/content/xdocs/en_US/mydocument.xml would be the > starting point. =A0The question is what the $path variable will contain > - if it's just "en_US/mydocument.xml" my job is easy. =A0If it could be > "en_US\mydocument.xml" on Windows and "en_US/mydocument.xml" on Unix > it's a bit harder. =A0 But if it is the absolute path xsl expressions > aren't going to help me and I'd better find a better solution. > > What I'd do (and this might even make a decent general patch) is look > for the property with the language specifier first. =A0For example, > instead of looking for "output.pdf.fontFamily.sansSerif" first, I'd > look for "output.pdf.fontFamily.sansSerif.en_US" first, and only look > for the other if that property is not found. > > So, what can I expect to see for the $path parameter? > > Thanks again for your help! > Karl