Google font CSS and PDF

166 views
Skip to first unread message

jd.fa...@gmail.com

unread,
May 19, 2015, 11:02:26 AM5/19/15
to suppor...@runmyprocess.com
Is it possible to use Google Font on in the Web interface and for generate a PDF?

Shobhit Tripathi

unread,
May 24, 2015, 6:38:11 AM5/24/15
to suppor...@runmyprocess.com
Hi,

Yes, you can integrate Google font(s) in your Web Interface.

As per your second query I am not getting this properly. Do you want to generate the PDF file by the use of any specific font or you want to use the same look and feel into the PDF as you used in Web Interface?

If you want any specific font then currently default fonts are "Arial" and "Times New Roman".

Hope this helps you.

Kindly let us know for further assistance to implementation on this. Please feel free to ask.

On Tue, May 19, 2015 at 8:32 PM, <jd.fa...@gmail.com> wrote:
Is it possible to use Google Font on in the Web interface and for generate a PDF?

--
Fujitsu - RunMyProcess
---
You received this message because you are subscribed to the Google Groups "Fujitsu RunMyProcess Developer Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to supportforum...@runmyprocess.com.
To post to this group, send email to suppor...@runmyprocess.com.
Visit this group at http://groups.google.com/a/runmyprocess.com/group/supportforum/.
To view this discussion on the web visit https://groups.google.com/a/runmyprocess.com/d/msgid/supportforum/c07afb7a-b102-434e-b059-112ec6cc7357%40runmyprocess.com.
For more options, visit https://groups.google.com/a/runmyprocess.com/d/optout.



--
Thanks & Regards,
Shobhit
Fujitsu- RunMyProcess

Jean-Daniel Faessler

unread,
May 24, 2015, 11:39:53 AM5/24/15
to stri...@runmyprocess.com, suppor...@runmyprocess.com

Hi,


Thanks for your answer and informations.


Regarding Google Font for the web interface, can you tell me how to integrate? Should I charge the police before? If so, how?

Concerning the PDF, it is also to use Google Font instead of Arial or Times. I have no problem with the look and feel.

Thank you in advance.


Jean-Daniel



De : Shobhit Tripathi <stri...@runmyprocess.com>
Envoyé : dimanche 24 mai 2015 12:37
À : suppor...@runmyprocess.com
Objet : Re: [supportforum:7425] Google font CSS and PDF
 
You received this message because you are subscribed to a topic in the Google Groups "Fujitsu RunMyProcess Developer Community" group.
To unsubscribe from this topic, visit https://groups.google.com/a/runmyprocess.com/d/topic/supportforum/bgNf0pDe86o/unsubscribe.
To unsubscribe from this group and all its topics, send an email to supportforum...@runmyprocess.com.

Shobhit Tripathi

unread,
May 26, 2015, 6:07:32 PM5/26/15
to Jean-Daniel Faessler, suppor...@runmyprocess.com
Hi,

Apology for delay.

To integrate the Google font in Web interface, please refer below steps-

1. You have to import below API link reference into the JavaScript tab (Web Interface)-

2. In WI you need to use two widgets (i.e. HTML widget and JavaScript widget).

3. In html widget you can use below code-
<html>
<head>
<style>
p.Baskerville{
font-family: 'Libre Baskerville', serif;
font-size: 15px;
}
</style>
</head>
<body>
<h3>Google font-</h3>
<p class="Baskerville">This is a paragraph, shown in the Libre Baskerville.</p>

</body>
</html>
4. In JS widget you have to use below code-
WebFontConfig = {
    google: { families: [ 'Libre+Baskerville::latin' ] }    // Here you have to use font-family name.
  };
  (function() {
    var wf = document.createElement('script');
    wf.src = ('https:' == document.location.protocol ? 'https' : 'http') +
    wf.type = 'text/javascript';
    wf.async = 'true';
    var s = document.getElementsByTagName('script')[0];
    s.parentNode.insertBefore(wf, s);
  })();
  
  
NOTE: Here I am taking an example of 'Libre Baskerville' font-family(provided by Google-font). You can use any font as per your requirement. 
The JS will also be slightly changed if you use any other font. 
You can also refer Google font site (https://www.google.com/fonts) for better understanding.
 
As per your second query for PDF generation with the use of different (Google-font) fonts. Currently XSL supported fonts are- Helvetica, Times, Courier, Arial. I am checking for different font-family integration (whether working or not) and will let you know soon.
Reply all
Reply to author
Forward
0 new messages