Welcome Guest Search | Active Topics | Sign In | Register

Help: Font-Awesome Icons Not Rendering In PDF Options
Alfred
Posted: Thursday, August 27, 2015 12:42:58 PM
Rank: Newbie
Groups: Member

Joined: 8/27/2015
Posts: 4
Hi All,

I came across a problem in our application where font-awesome icons failed to render in our PDF. In light of trying to see if a newer version of EO PDF would fix the issue, I downloaded the trial and included the references and using the convertUrl:

HtmlToPdf.ConvertUrl("C:\test.html", "C:\test.pdf");

A pdf was indeed outputted a pdf, but only text would appear and not the icons. However, after uploading the same "test.html" to the demo site for the same function.

Here is the file I used:

Quote:

<html>
<head>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.4.0/css/font-awesome.min.css">
</head>
<body>
<i class="fa fa-camera-retro fa-lg"></i> fa-lg
<i class="fa fa-camera-retro fa-2x"></i> fa-2x
<i class="fa fa-camera-retro fa-3x"></i> fa-3x
<i class="fa fa-camera-retro fa-4x"></i> fa-4x
<i class="fa fa-camera-retro fa-5x"></i> fa-5x
<img height="50" width="50" src="https://www.google.com/images/srpr/logo8w.png">
</body>
</html>


*Note notice the img at the end does appear in the pdf.
eo_support
Posted: Thursday, August 27, 2015 1:47:38 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,067
Hi,

We tested the latest build and it seems to work fine. Our steps are:

1. Save the HTML into a file;
2. Run our EOPdfDemo sample application;
3. Go to All Demos -> HTML to PDF -> Basic -> Url to PDF;
4. Enter the file name in step 1 and then click "Run";

The result PDF file does contain both the icons and the Google image.

Can you try the same and see if it works for you?

Thanks!
Alfred
Posted: Friday, August 28, 2015 10:12:55 AM
Rank: Newbie
Groups: Member

Joined: 8/27/2015
Posts: 4
Thank you for the quick reply.

I opened the EO.Pdf Demo executable and went to the "Convert URL" dropdown. Entered the URL and saw the same behavior (no icons).

eo_support
Posted: Friday, August 28, 2015 11:33:28 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,067
What version of EO.Pdf do you use? Are you using the latest version (DLL version number 15.2.37.0)?

Thanks
Alfred
Posted: Friday, August 28, 2015 3:06:55 PM
Rank: Newbie
Groups: Member

Joined: 8/27/2015
Posts: 4
Yes, I downloaded the trial version to test with.
Alfred
Posted: Friday, August 28, 2015 3:07:54 PM
Rank: Newbie
Groups: Member

Joined: 8/27/2015
Posts: 4
Just realized if I try to do http://www.google.com/ as the url, the request timeout.
eo_support
Posted: Friday, August 28, 2015 3:53:59 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,067
We are not sure what to tell you then. You might have some issues with your network. We have tested both cases here and it works fine.
sean.hogg
Posted: Tuesday, September 15, 2015 12:22:25 PM
Rank: Newbie
Groups: Member

Joined: 9/15/2015
Posts: 1
Hi,

I have a follow-up to this...

if (typeof window.CSSMediaRule !== "function") {
document.write("EO PDF doesn't support - CSSMediaRules");
return false; //Your browser doesn't support media query feature
}

This always returns "EO PDF doesn't support - CSSMediaRules" when running EO PDF.


Do you support window.CSSMediaRule (AKA stylesheets ==> @media)?

Are you using chrome to generate the pdf? If so, what version?

Thanks,
Sean
eo_support
Posted: Wednesday, September 16, 2015 8:34:15 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,067
Hi,

EO.Pdf does not support media rule yet because it uses an early version of WebKit. This is not the same as the blink engine Chrome currently use (blink was forked from WebKit). Currently our EO.WebBrowser product uses a rather update to date blink engine (based on Chromium V41). We are in the process of moving EO.Pdf to use the same engine. Once that is done it will support media rules.

Thanks!


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.