I am trying to include some styled html text in a PDF Report.
So, I have a text html Attribute and I stuff it with the styled html that I want.....
Here is the string....
<div style="font-family:'Courier New';font-size:6px;">A: PU648YF / <span style="color:red;">⚠ B: AEBY-426</span></div>
But, not matter what font I use or size etc.... the text is displayed fuzzy...
Has anyone done this? Any ideas how to fix and make the text sharp would be greatly appreciated.
HTML in a PDF Report
-
- Posts: 2425
- Joined: Mon Jul 02, 2012 12:24 am
- Location: Ulaanbaatar, Mongolia
HTML in a PDF Report
Cheers,
Mark
_________________
AwareIM 6.0, 8.7, 8.8, 9.0 , MariaDB, Windows 10, Ubuntu Linux. Theme: Default, Browser: Arc
Upcloud, Obsidian....
Mark
_________________
AwareIM 6.0, 8.7, 8.8, 9.0 , MariaDB, Windows 10, Ubuntu Linux. Theme: Default, Browser: Arc
Upcloud, Obsidian....
-
- Posts: 2425
- Joined: Mon Jul 02, 2012 12:24 am
- Location: Ulaanbaatar, Mongolia
Re: HTML in a PDF Report
Yes Joben
Makes no difference
Makes no difference
Cheers,
Mark
_________________
AwareIM 6.0, 8.7, 8.8, 9.0 , MariaDB, Windows 10, Ubuntu Linux. Theme: Default, Browser: Arc
Upcloud, Obsidian....
Mark
_________________
AwareIM 6.0, 8.7, 8.8, 9.0 , MariaDB, Windows 10, Ubuntu Linux. Theme: Default, Browser: Arc
Upcloud, Obsidian....
Re: HTML in a PDF Report
IF I remember correctly, this has been an issue for years and has something to do with how Aware integrates the HTML into the report. I don´t think there is a workaround (I could be wrong) other than creating a picture programmatically (that has the html text looking good etc.) and then showing that picture instead of the HTML on the report.
Henrik (V8 Developer Ed. - Windows)
Re: HTML in a PDF Report
It would be interesting to look at the source code of this PDF, and focus on the code in question.
Wondering if there is some “surrounding” code, causing the blurriness.
I would assume that code is either coming from Vlad’s JavaScript routines, in which case it should be edible and correctable by us,
Or it’s coming from a third-party jar, which would be a bit tougher to resolve.
Wondering if there is some “surrounding” code, causing the blurriness.
I would assume that code is either coming from Vlad’s JavaScript routines, in which case it should be edible and correctable by us,
Or it’s coming from a third-party jar, which would be a bit tougher to resolve.
Click Here to see a collection of my tips & hacks on this forum. Or search for "JaymerTip" in the search bar at the top.
Jaymer
Aware Programming & Consulting - Tampa FL
Jaymer
Aware Programming & Consulting - Tampa FL
Re: HTML in a PDF Report
Henrik (V8 Developer Ed. - Windows)
-
- Posts: 7559
- Joined: Sun Apr 24, 2005 12:36 am
- Contact:
Re: HTML in a PDF Report
The problem with fuzziness will be fixed in the next build.
Aware IM Support Team
Re: HTML in a PDF Report
Mark,
why am I not seeing HTML in my report?
Ver 8.6
The field def:
The report def:
The result:
why am I not seeing HTML in my report?
Ver 8.6
The field def:
The report def:
The result:
Click Here to see a collection of my tips & hacks on this forum. Or search for "JaymerTip" in the search bar at the top.
Jaymer
Aware Programming & Consulting - Tampa FL
Jaymer
Aware Programming & Consulting - Tampa FL
Re: HTML in a PDF Report
Mark? Ideas?
Click Here to see a collection of my tips & hacks on this forum. Or search for "JaymerTip" in the search bar at the top.
Jaymer
Aware Programming & Consulting - Tampa FL
Jaymer
Aware Programming & Consulting - Tampa FL
-
- Posts: 2425
- Joined: Mon Jul 02, 2012 12:24 am
- Location: Ulaanbaatar, Mongolia
Re: HTML in a PDF Report
You need to add a html parameter in your tag
<<mmBO.myAttribute, ‘html’>>
<<mmBO.myAttribute, ‘html’>>
Cheers,
Mark
_________________
AwareIM 6.0, 8.7, 8.8, 9.0 , MariaDB, Windows 10, Ubuntu Linux. Theme: Default, Browser: Arc
Upcloud, Obsidian....
Mark
_________________
AwareIM 6.0, 8.7, 8.8, 9.0 , MariaDB, Windows 10, Ubuntu Linux. Theme: Default, Browser: Arc
Upcloud, Obsidian....
Re: HTML in a PDF Report
ok, thx
that worked - forgot about that
problems now:
1) sucks that you have to use inline 'styles' - tried class and it doesn't pick it up.
2) cant get the text tight...
here is the html in a browser
and shown in chrome explorer but directly in the PDF its this:
(the left one is non-html) I'm not as concerned with the 'fuzziness', since its fixed now in v9.
but I MUST have the lines tightened or its a non-starter.
must be using something other than line-height.
EDIT
Also tried multiple variations of Margin to no avail. No change at all.
Applied to the inside DIVs, not the wrapper.
margin-bottom: 20px !important;
margin-bottom: -20px !important;
that worked - forgot about that
problems now:
1) sucks that you have to use inline 'styles' - tried class and it doesn't pick it up.
2) cant get the text tight...
here is the html in a browser
and shown in chrome explorer but directly in the PDF its this:
(the left one is non-html) I'm not as concerned with the 'fuzziness', since its fixed now in v9.
but I MUST have the lines tightened or its a non-starter.
must be using something other than line-height.
EDIT
Also tried multiple variations of Margin to no avail. No change at all.
Applied to the inside DIVs, not the wrapper.
margin-bottom: 20px !important;
margin-bottom: -20px !important;
Click Here to see a collection of my tips & hacks on this forum. Or search for "JaymerTip" in the search bar at the top.
Jaymer
Aware Programming & Consulting - Tampa FL
Jaymer
Aware Programming & Consulting - Tampa FL
Re: HTML in a PDF Report
Instead of divs, try using span tags and see if that makes a difference? Also, take a look at the padding CSS and see if that changes anything.Jaymer wrote: ↑Wed Mar 27, 2024 4:02 am ok, thx
that worked - forgot about that
problems now:
1) sucks that you have to use inline 'styles' - tried class and it doesn't pick it up.
2) cant get the text tight...
here is the html in a browser
Screenshot 2024-03-26 at 11.54.38 PM.png
and shown in chrome explorer
Screenshot 2024-03-26 at 11.56.47 PM.png
but directly in the PDF its this:
(the left one is non-html)
Screenshot 2024-03-27 at 12.00.57 AM.png
I'm not as concerned with the 'fuzziness', since its fixed now in v9.
but I MUST have the lines tightened or its a non-starter.
must be using something other than line-height.
EDIT
Also tried multiple variations of Margin to no avail. No change at all.
Applied to the inside DIVs, not the wrapper.
margin-bottom: 20px !important;
margin-bottom: -20px !important;
Henrik (V8 Developer Ed. - Windows)
Re: HTML in a PDF Report
damn, what a pain in the ass.
and i just did an upgrade on saturday the 30th, and a new version with new Report HTML Library comes out 2 days later.
spent many hours trying to get this HTML to be anywhere close to useable - and it was broke all along.
Hope the new April 1 build finally works.
and i just did an upgrade on saturday the 30th, and a new version with new Report HTML Library comes out 2 days later.
spent many hours trying to get this HTML to be anywhere close to useable - and it was broke all along.
Hope the new April 1 build finally works.
Click Here to see a collection of my tips & hacks on this forum. Or search for "JaymerTip" in the search bar at the top.
Jaymer
Aware Programming & Consulting - Tampa FL
Jaymer
Aware Programming & Consulting - Tampa FL
Re: HTML in a PDF Report
Mark
still broke after upgrading to bld 3249
sux
I used your html line from the first post.
here it is in my text field.
here's how the report looks
after being sized up - maybe 12px
still broke after upgrading to bld 3249
sux
I used your html line from the first post.
here it is in my text field.
here's how the report looks
after being sized up - maybe 12px
Click Here to see a collection of my tips & hacks on this forum. Or search for "JaymerTip" in the search bar at the top.
Jaymer
Aware Programming & Consulting - Tampa FL
Jaymer
Aware Programming & Consulting - Tampa FL
Re: HTML in a PDF Report
But the fonts are crap.
Always "blocky", jagged
can't find ANY combination of 'font-family' that it will accept.
got a couple of hours in it just tonight, after the new build
It does change typeface... just not very well. And never to a smooth font. Always a poor bitmap.
Always "blocky", jagged
can't find ANY combination of 'font-family' that it will accept.
got a couple of hours in it just tonight, after the new build
It does change typeface... just not very well. And never to a smooth font. Always a poor bitmap.
Click Here to see a collection of my tips & hacks on this forum. Or search for "JaymerTip" in the search bar at the top.
Jaymer
Aware Programming & Consulting - Tampa FL
Jaymer
Aware Programming & Consulting - Tampa FL