Escolar Documentos
Profissional Documentos
Cultura Documentos
XML Publisher enables you to use fonts in your output that are not normally available on the server. To set up a new font for your report output, use the font to design your template on your client machine, then make it available on the server, and configure XML Publisher to access the font at runtime. 1. Use the font in your template. i. Copy the font to your <WINDOWS_HOME>/fonts directory.
ii. iii.
Open Microsoft Word and build your template. Insert the font in your template: Select the text or form field and then select the desired font from the font dialog box (Format > Font) or font drop down list.
2.
Font Name: Choose any descriptive name. Ex: IDAutomationSHI25M File: Browse the appropriate font file. Upload the .ttf file you want to upload. 3. Navigate to Font Mappings Create Font Mapping Set.
Mapping Name: The name given to a set of fonts. Ex: IDAutomationSHI25M Mapping Code: The internal name you will give to this set. Ex: IDAutomationSHI25M Type: 'PDF Form' for PDF templates. 'FO to PDF' for all other template types. Click Apply 4. Create Font Mapping (this allows you to add fonts to a set).
Font Family is the exact same name you see in Word under Fonts. (Note: If you don't use the same name the font will not be picked up at runtime.) Style and Weight must also match how you use the font in windows. Normal and Normal are defaults. Font Type is to be selected as Truetype After providing all the above details, click on Continue tab
5. Navigate to Configuration General FO Processing Font Mapping Set. This can also be done at Data Definition and Template level under Edit Configuration. Hierarchy is Site Data Definition Template.
Select your new mapping set. 6. Make sure the font is not referenced under File Properties Custom in the RTF template file. 7. Under General set a Temporary Directory. The font will be downloaded here under /tmp/fonts to be used at runtime (the first time the font is used). 8. Upload a template that uses your special font and test using preview or by submitting a concurrent request.
TEST_DEPT_EMP.rdf
DEPT_EMP.rtf
2. Select
Department
number
field
and
make
its
font
type
as
IDAutomationSHI25M
3. Create Concurrent program, data definition and Template with the above RDF and RTF.
Click Open,
Output:
3.
Now navigate to File > Properties > Custom Tab Add a custom font: Name: xdo-font.IDAutomationSHI25M.normal.normal Type: Text Value: truetype.C:\WINDOWS\Fonts\IDAutomationSHI25M.ttf
4.
Load the XML data and Preview the output in Local machine. Output: