I've developed a popup window and I use the body onload='window.print()' function to print the document, and then I choose the printer Microsoft Print to Pdf, which produces a PDF. However, the main logo I have at the top of the document goes missing. I have another website which uses the same approach with a different logo and that works fine.
I have attached the problematic logo below:
The image is a PNG. I originally used a transparent background, but I thought that maybe the PDF converter thinks the ratio of dark to light is too high and hides it, so I changed the background to white to increase the lightness ratio, but to no avail.
Is there something else I can do to force the logo to appear without the user having to tweak print configurations?
Related
For a deck of lecture slides, I have extracted several vector illustrations from a PDF-file. I did this by highlighting the relevant area in Preview.app, copying, and opening a new file from the clipboard.
The figures look just fine, even though I noticed that the files are a little large. When I open them in Illustrator, I can see what's described in the screenshot – that all of the page content is still there, it's just hidden because it lies outside the crop area.
Now I could simply remove everything except the relevant figures in Illustrator, but I would much rather automate the process, since I have a large number of figures.
How can I automate this process such that everything outside the crop area is discarded and everything inside it is preserved as a vector image?
You can use redact utility to remove the content.
Just go to https://doxiview.cib.de/showcase/index.html?locale=default
Choose redact tool
upload your PDF
Choose on the right Select Area and redact fill color as white
Mark all content, which you want to remove
click on apply
download PDF
Afterwards you can crop the PDF and you won't have the content being still there.
There's no need to rasterize. Just crop the pages then use Acrobat DC to "Sanitize" the document. That will completely remove any non-visible parts of the file.
In Acrobat Pro, go to Preflight and select the setting below.
Then click edit to the right
You should be able to create Adobe droplets with this preflight setting for automation
When printing to PDF from Visual Studio, all my .cs files get printed with black text on white background. On the other hand, the .css and .cshtml files get printed with white text on a black highlight. The first mode is usable while the latter isn't. However, both cases seem to ignore the Tools > Options > Environment > Fonts and Colors > Printer configuration, which is configured to colour syntax normally on printing and has no configuration whatsoever especifying a black highlight.
On the physycal side we have an even stranger output: when physically printing on a black-and-white laser printer we got a black text on white back (result is displayed on the right-hand side of the picture below). When printing on a colour laser printer we got a white text on black highlight (on the left-hand side of the picture).
Changing the Visual Studio Theme from Dark to Light has no effect
Using a third party tool such as VSCodePrint also prints the code with a black highlight
I have used both Adobe Acrobat Pro PDF printer and CutePDF Writer, but both give me the same results as the left-hand side of the picture in the PDF (digitally, of course)
Any contribution is welcome as there is little to no information on the Web about this.
According to visual studio editor team, it was a confirmed bug on 2012. There appeared to be a resolution (kb download) to fix that, but I don't see it being "applyable" to VS2013. See: http://connect.microsoft.com/VisualStudio/feedback/details/760291/vs2012-with-dark-theme-prints-code-with-black-background
I have a pdf book that is not showing up completely. I have attached a screenshot of acrobat's print preview showing what the issue is. As you can see there is more conentent on the left of the page that is not showing up.
I have tried:
Changing the paper size
Changing the dimensions to "fit"
Opening in Google docs
Opening in mac's preview
Opening in Google Books.
Any ideas of what I can try
As a late answer and when using Linux, one can use the command line tool "pdfjam".
Add margins to pages
Desired result: remove 0.5 cm from top and bottom of page, add 2 cm to right margin. Keep page size (important)
pdfjam --fitpaper true --trim "0cm 0.5cm -2cm 0.5cm" input.pdf -o output.pdf
Negative numbers in the trim-argument means "add", while a positive means "remove".
The four numbers within the trim-arguments relates to the left, bottom, right and top margin
If fitpaper is set to false the trim will move the content around the page and not resize the page.
You can add "--frame true" to see what's going on.
Move content to the left
Desired result: make right margin 1 cm larger and left margin 1 cm smaller
pdfjam --offset "-1cm 0cm" input.pdf -o output.pdf
The command below will move the content of the page 1 cm from right to left.
pdfjam and documentation
Documentation about pdfjam can be found here: http://www2.warwick.ac.uk/fac/sci/statistics/staff/academic-research/firth/software/pdfjam
The combination of pdfinfo, pdftk and pdfjam can be used to modify PDFs quickly on a more advanced level.
If I was you, I would check if PDF page boxes are correct. Especially if document looks fine in viewer but offset in print preview.
The issue might be caused by any of the boxes defined so they are outside of MediaBox.
Another approach to try is to impose this document onto other document with some offset. Others recommend Multivalent and Ghostscript for the task.
Without seeing the PDF it is hard to determine the exact reason for what you're seeing, but often the reason is that the CropBox is smaller than the MediaBox. The MediaBox is the size of the physical page and the CropBox is the area of the page that is viewed or printed. If no CropBox is specified then its value is inherited from the MediaBox.
You can programmatically get the page box dimensions and also set them using my companies free PDF SDK. It's an ActiveX for Windows and it is called Debenu Quick PDF Library Lite.
Upload the PDF and share a link if the page box dimensions do not solve the mystery.
Fixed it!
I had to change the page size of the file (Printing to pdf on a larger paper didnt work)
Steps to get it down:
Open Adobe Acrobat Plus
Click on "tools"
Click on "Crop" (which is under the "Page" section)
Double click anywhere on the pdf
Under "Change page size" make it larger then what it is
apply to all!
That's it!
The problem now we are facing is- We are loading some color Eng. graphics and doing annotation.
All looks fine and working well and good. Now, at the end of job completion we need to print the PDF file with annotation in black and white.
Here, since the PDF is colored one, we are not able to see print clearly.
Is there any option to make all content in PDF to black color later? So that print will be very clear.
Like this problem.
I created this PDF using PDFSharp.
When I print it (to my Brother HL 5140 laser printer, or to the XPS printer, but not to PDFCreator) it ends up looking like this XPS document does does when viewed with the XPS viewer built in to Windows 7. I've also taken a pair of screenshots.
The printed copy contains an extra line segment (actually two, a skinny white one atop a wider black one in a style commonly used to depict roads) that runs from top center to bottom left.
Does anyone know why this happens, whether it is a bug in PDFSharp or a problem with my geometry, or have any idea how to go about debugging something like this?