We don't want to specify fonts char-by-char, we want them picked.

On Mon, Jan 4, 2010 at 7:35 AM, Abel Braaksma <[email protected]> wrote:
> I'm under the impression that Benson means selection strategy based on
> availability. Suppose the "A" is available in Candara, but the other
> letters/symbols are not, and the needed font selection strategy is
> "character by character" then the result must be similar to what you wrote,
> but automatically so. According to
> http://xmlgraphics.apache.org/fop/trunk/fonts.html#selection this is not
> implemented yet.
>
> Note that "auto" (which is implemented) means "the selection criterion is
> implementation defined". For FOP that means (afaik) that word boundaries and
> element boundaries work and that the "largest portion of a text or word
> that's available in a particular font" will be chosen. In the example above,
> the Gothic font will be used, because that has the largest part of the
> word/text.
>
> Changing to "character-by-character" means that each character is considered
> individually.
>
> Naturally, if Candara would contain all capital letters only, choosing
> character-by-character in the following:
>
>  <fo:inline  font-family="Caldara, 'Century Gothic'">A=E3=81=82</fo:inline>
>
> then the rendering with character-by-character would be equivalent with the
> following:
>
>  <fo:inline  font-family="Caldara">A</fo:inline>
>  <fo:inline  font-family="'Century Gothic'">=</fo:inline>
>  <fo:inline  font-family="Caldara">E</fo:inline>
>  <fo:inline  font-family="'Century Gothic'">3=81=82</fo:inline>
>
> Obviously, either this or the original example from Benson cannot be
> achieved with current means (unless you add some rather prolific XSLT 2.0
> preprocessing, i.e., give it a list of fonts and do the selection strategy
> in the earlier processing step, using some home-brewed extension functions,
> which could be a possible alternative while waiting for the implementation).
>
> Cheers,
> Abel
>
>
> Jason Harrop wrote:
>>
>> I don't have a font called "MS Gothic" on my XP / Word 2007 PC, so
>> i've used "Century Gothic" instead, but subject to that, and assuming
>> the relevant fonts are available, isn't this just:
>>
>>            <fo:block>
>>                <fo:inline  font-family="Candara">A</fo:inline>
>>                <fo:inline  font-family="Century
>> Gothic">=E3=81=82</fo:inline>
>>            </fo:block>
>>
>> with a config such as:
>>
>> <fop version="1.0">
>>    <strict-configuration>true</strict-configuration>
>>    <renderers>
>>        <renderer mime="application/pdf">
>>            <fonts>
>>                <font embed-url="file:/C:/WINDOWS/FONTS/CANDARA.TTF">
>>                    <font-triplet name="Candara" style="normal"
>> weight="normal"/>
>>                </font>
>>                <font embed-url="file:/C:/WINDOWS/FONTS/GOTHIC.TTF">
>>                    <font-triplet name="Century Gothic" style="normal"
>> weight="normal"/>
>>                </font>
>>            </fonts>
>>        </renderer>
>>    </renderers>
>> </fop>
>>
>> cheers .. Jason
>>
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to