03-05-2020, 03:39 AM,
|
|
Confucius
Member
|
Posts: 25
Threads: 7
Joined: Jan 2017
|
|
Resize Logo Image on Customer Invoice/Credit Note
The logo on the customer invoice/credit note is totally over sized and stretched. How would I resize the image. Thanks in advance.
|
|
03-05-2020, 04:09 AM,
(This post was last modified: 03-05-2020, 04:13 AM by dalescott.)
|
|
dalescott
Senior Member
|
Posts: 107
Threads: 23
Joined: Sep 2016
|
|
RE: Resize Logo Image on Customer Invoice/Credit Note
I suspect your logo size and shape is not what the invoice/credit note designer had in mind when they created the note. It may be simplest to crop and re-size your logo (my goto for this would be Irfanview). Sorry I can't say what size/shape is compatible, but assuming the logo in the demo looks acceptable I would start by simply making mine the same.
To look _really_ good, it is possible the design of the invoice/credit note will have to be changed to accommodate your particular logo size and shape, in which case you will have to decide how much effort is justified for the gain in cosmetic appearance.
Good luck,
Dale
http://www.dalescott.net
|
|
03-05-2020, 04:20 AM,
|
|
Confucius
Member
|
Posts: 25
Threads: 7
Joined: Jan 2017
|
|
RE: Resize Logo Image on Customer Invoice/Credit Note
Dale,
Thank you for the quick response. I will have a go at it.
Regards,
|
|
03-05-2020, 05:44 AM,
|
|
TimSchofield
Tim Schofield
|
Posts: 1,318
Threads: 22
Joined: Mar 2015
|
|
RE: Resize Logo Image on Customer Invoice/Credit Note
The files you ned to look at if you want to play around with the image file that you have are includes/PDFTransPageHeader.inc and includes/PDFTransPageHeaderPortrait.inc
Look for the lines like:
$pdf->addJpegFromFile($_SESSION['LogoFile'],$Page_Width/2 -120,$YPos-40,0,60);
where the parameters are horizontal position, the vertical position the width, and the height. You may need to play with some other lines as well if your logo pushes something out.
Hope this helps,
Tim
|
|
03-05-2020, 05:10 PM,
(This post was last modified: 03-05-2020, 05:37 PM by Confucius.)
|
|
Confucius
Member
|
Posts: 25
Threads: 7
Joined: Jan 2017
|
|
RE: Resize Logo Image on Customer Invoice/Credit Note
Tim, thanks. I did change the values in the PrintCustTrans.php but that was in hindsight the wrong spot.
Regards,
Hi Guys, is there anyone who has implemented alternate row backgrounds in the PDF reports, like the Price List etc? Any examples or pointers would be of value.
Thanks in advance.
|
|
03-06-2020, 03:10 PM,
(This post was last modified: 04-25-2020, 12:52 PM by TurboPT.)
|
|
TurboPT
Administrator
|
Posts: 727
Threads: 10
Joined: Jun 2012
|
|
RE: Resize Logo Image on Customer Invoice/Credit Note
Confucius Wrote:Hi Guys, is there anyone who has implemented alternate row backgrounds in the PDF reports, like the Price List etc? Any examples or pointers would be of value.
Thanks in advance.
I can help with the row shading, but it will not be until Saturday before I can give details and/or an example. (I've attached a 2-line example that I threw together for a quick check, below, but it's incomplete) It's already near midnight in my locale, and I don't know that I'll get to it tomorrow.
The shading is not easily done, but it is doable. The 'rows' are not really rows like a HTML table row concept, rather, the PDF 'rows' are line offsets, and the data within each line is (sort of) like cells, so it's a cell-by-cell shading on alternating lines to achieve the shading effect.
Where you say "like the Price List", is that the desired PDF to have shading, or does that imply that it already has shading?
(I don't currently have any pricing set, but I could surely add a few lines)
PDF row shading example
|
|
03-06-2020, 04:59 PM,
|
|
Confucius
Member
|
Posts: 25
Threads: 7
Joined: Jan 2017
|
|
RE: Resize Logo Image on Customer Invoice/Credit Note
TurboPT, I would appreciate the help. It can wait until you're able to assist. There is not shading done.
Thanks again.
Regards,
|
|
|