Why google sheets save as PDF doesn't show emoji in Cell? - google-sheets

Do you know why some times the emoji icons show normal and some times show as just empty square in google sheets , also when I save sheet as PDF the icon show as line ! , can anyone advise the reason ? what should i do ?
Here is a link of the sheet ( ICON in B24 )
https://docs.google.com/spreadsheets/d/1LRmyNlKSQjADz0bG_-mDf6w0LqEg7IcPgVizXF4C-Xc/edit?usp=sharing
this is the link were i took the icon from .
https://emojipedia.org/emoji/%F0%9F%8C%9E/
Thanks,

Why This is Impossible
Google Sheets does not export emoji to .pdf because it does not know what an emoji is. Google Sheets is able to display emoji when doing work not because Google Sheets itself can display emoji, but because your browser/operating system can. If everything was left only to Google Sheets, it wouldn't know how to display emoji at all.
The one exception to this is Noto Emoji (as already mentioned by Max Makhrov). Through this page, it can be seen that no font built into Google Sheets has the ability to display emoji except Noto Emoji. Even then, Noto Emoji only displays it as a black-and-white outline. Every other font available in Google Sheets does not have support for emojis.
If Google Sheets allowed the addition of custom fonts, this would be fixable. However, it is currently not possible to add custom fonts into Google Sheets. There are additional "advanced" fonts hidden in the "Fonts Dropdown->More Fonts" menu (one of which is Noto Emoji), but adding truly custom fonts is not possible.
Perhaps a correctly built extension could fix this issue. Currently though, no such extension seems to exist. One Google Sheets add-on called Free and New Font purports to add this functionality, but it has absolutely abysmal reviews and demands some very dodgy permissions regarding one's Google account. I have not tested it, and have intentionally refrained from linking to it because it seems nearer to a virus than actual solution. I would not want anyone skimming this to get the wrong idea.
All of that leaves us with no way (except Noto Emoji) to have Google Sheets recognize emoji; therefore, there is no way to use the built-in Google Sheets "Export as PDF" functionality and have emoji be exported correctly.
Alternatives
Since it is not possible to complete this task directly, I have provided some alternatives below.
Use Noto Emoji
Noto Emoji itself is the closest option Google Sheets has for exporting to .pdf which include emoji. The downside of this is that Noto Emoji only exports emoji as black-and-white outlines. If this is serviceable, Noto Emoji can be accessed by:
Selecting all cells with emoji in them.
Clicking the fonts dropdown menu.
Selecting "More Fonts" at the top of the list.
Searching for "Noto Emoji" and selecting it.
Pressing "OK"
Export Using Another Method
As OSM suggests, exporting as an .html document instead of a .pdf would retain colored emoji correctly. Another program can then be used to convert the .html document into a .pdf. Similarly (with even more jankiness), a screenshot of the document could be taken, and the image added to a PDF later. If access to Excel is possible, Google Sheets supports exporting to .xlsx, and Excel has better support for exporting emojis into PDFs.
The downside of this solution is that it requires numerous additional steps that take place outside of Google Sheets. If this is serviceable, refer to OSM's answer for steps to implement the .html solution, or Microsoft documentation for steps to implement the .xlsx solution.
Use Images Instead
Rather than using emoji, images could instead be used as this answer by pjmg suggests. Using the =IMAGE() formula (documentation here), a picture of an emoji could be pulled from an outside source. Google Sheets would correctly export that image when a .pdf file is created.
The downside of this solution is that it is cumbersome to find sources for external images, the images are not true emoji (which will be evident when editing the document), and if the host of the image goes down, exporting will no longer function correctly. If this is serviceable:
Find a website that hosts images of emoji. In this answer, jpmg suggests iEmoji. The Emojipedia website would also work.
Right click the image and click "Open in New Tab".
Copy the link and put it into an =IMAGE() formula in the desired cell.
For example (courtesy of jpmg), if you wanted the "face with tears of joy" emoji, you could use =IMAGE("https://s3.amazonaws.com/pix.iemoji.com/images/emoji/apple/ios-12/256/face-with-tears-of-joy.png") or =IMAGE("https://emojipedia-us.s3.dualstack.us-west-1.amazonaws.com/thumbs/120/apple/325/face-with-tears-of-joy_1f602.png")
Create New Functionality
If none of the above solutions are serviceable, it's possible to request that Google update their software to fix the problem. Max Makhrov has already submitted a bug report here, which can be voted on to improve the chances that Google updates things. Though, it should be noted: I think that this is technically all intended functionality, so a feature request might be a better route.
Furthermore, if anyone is particularly motivated, creating a non-shady alternative to the add-on I previously mentioned could also be a solution. Ultimately though, I suspect this would be a very time-consuming task for little gain.
Conclusion
It is not possible to use the built-in "Export as PDF" functionality in Google Sheets to get a resulting file with colored emoji. This is because there are no appropriate fonts available in Google Sheets. Workarounds exist, but none are optimal.

Solution
You can print easily with few steps, Colored and with any font.
1 - Add a dot in the right bottom corner to indicate the edge
and Go to File > Download > Web Page (.html)
2 - Open the webpage in your browser and print as a PDF
Edit with Pdf editor
3 - Open the PDF file with illustrator or a PDF editor, delete the grid and columns and rows.
Print and Enjoy :)

Running into the same problem, and so far the only work-around I have discovered is to go to File > Download > Web Page and then print the resulting HTML file for that sheet. You have to check the option in your browser's print dialogue to print background and images to get some of the formatting to print correctly.

I've reported this as an issue here:
https://issuetracker.google.com/issues/241147770
Please wote the issue if you want Google to solve it.
Note: when I use fonr Noto Emoji emojis are printed, but they are not colored.
To use this font select 'More Fonts' option.

The original solution: change the font
if you don't have to choose exact font, emoji containing cells that are formatted with Inconsolata or Sawarabi Mincho fonts are perfectly exported to PDF.
UPD. It appears that these fonts export correctly only certain emojis like arrows, card signs, etc... while others popular emojis are not exported correctly.
Notes
As #Osm noted:
failed with Inconsolata and Sawarabi Mincho see this
Noto Emoji seems to be the only font to work. Still Google has tons of fonts and we have no solid proof if some or any of them will work.
Chnaging the font seems to be the only programmable solution at the moment.
Vote the issue if you are effected.

Emojis are considered to be special characters.
So according to this, if you want to insert a special character, it is recommended you follow the steps mentioned in there.
As for the reason why the PDF is not exported in the way you expect it - this is due to encoding since emojis are special characters. I suggest you insert the emoji as an image and only afterwards export the spreadsheet.

Pdf translators cannot support exotic fonts like woof or csvg. commonly the html styles are
"Noto Color Emoji" (often via Google android platform apps)
"Apple Color Emoji" (used on Apple platforms such as iOS and macOS)
"Segoe UI Emoji" (as used by Windows platform in NotePad etc.)
Here the source text is on left in windows 11 notepad, as inserted say on a keyboard.
Then we can see in windows 11 notepad (!argh !why two apps same name), what it would look like if on the web as HTML.
Then from that print to PDF is on right and its not same as source !argh !argh, why the differences
so for above the pdf shows
Title: try.txt - Notepad
PDF Producer: Microsoft: Print To PDF
PDF Version: 1.7
Fonts:
CIDFont+F1 (TrueType (CID); Identity-H; embedded)
CIDFont+F2 (TrueType (CID); Identity-H; embedded)
CIDFont+F3 (TrueType (CID); Identity-H; embedded)
CIDFont+F4 (TrueType (CID); Identity-H; embedded)
PDF has enough trouble using TTF monochromatic fonts as shown above so google export fonts in the sample file are
 
<office:font-face-decls><style:font-face style:name="Arial" svg:font-family="Arial" /><style:font-face style:name="Cambria" svg:font-family="Cambria" /><style:font-face style:name="Liberation Sans" svg:font-family="'Liberation Sans'" style:font-family-generic="swiss" style:font-pitch="variable" /><style:font-face style:name="DejaVu Sans" svg:font-family="'DejaVu Sans'" style:font-family-generic="system" style:font-pitch="variable" /><style:font-face style:name="Linux Libertine G" svg:font-family="'Linux Libertine G'" style:font-family-generic="system" style:font-pitch="variable" /></office:font-face-decls>
and the plain text is
<table:table-cell table:style-name="ce1" office:value-type="string"
calcext:value-type="string">text:p😂</text:p></table:table-cell>
but on a web that is naturally colour enhanced since lol is considered naff however in any of the above fonts it would be a null character, or plain text in black and white.
For non font supported characters you could see Fonts: <#4> (Type3; embedded)
As explained by others simply export the html with html iconic characters and then print html to pdf where you can use the html emojis as plain text for find etc.

Related

How to extract bold text from pdf file programmatically using PDFKit in iOS?

I am using PDFKit to display my pdf files. I've integrated the searching functionality but I want to search only bold texts/words.
I'm wondering is it possible to do what I'm looking for or does Apple don't allow it? Because String data type is from Foundation class and UIFont is from UIKit.
I can search text only on the basis of lowercase, uppercase or text color. I've googled a lot. And I found that pdf files are made up of vectors. So, sometimes its difficult to extract the font-family of the text.
hm.. I guess you want to show all pdf files from your device's storage.
Generally.. if you want to show pdf file on your app, you should mapped the path and file name of the special folder into your code.
But I think you can't get the result you want with this method.
I am not sure In case this but probably you should use "UIDocumentPickerViewController".
I think also you need to set the value of documentTypes by [String(kUTTypePDF)] because you want to only show all the pdf.
Please check the following link for more details:
How to open the Document files e.g(.pdf,.doc,.docx) in ios mobile when a button action using swift3.0?
The attributed string has the font attributes, using which you can achieve what you want.
pdfDocument.page(at: 0)?.attributedString

copy chinese text from pdf that created with ios sdk CGPDFContextCreateWithURL(), found it is dismiss text when i paste!

I use IOS SDK CGPDFContextCreateWithURL() created pdf file,it is fine to read, but when i copy Chinese text from pdf and paste to Pages (apple text editor) or other text editor, i found it dismiss text. but if the copy text is English word it is fine. why ? it is a bug for CGPDFContextCreateWithURL() ? or the problem with encoding ?
There appears to be some sort of issue with the Ping Fang Smallcaps font in the PDF and CGPDFContext isn't able to overcome the issue. You can see below that Adobe Acrobat also has trouble extracting the text accurately. Foxit PhantomPDF can successfully extract the text.
Adobe Acrobat
打发撒地⽅方阿斯蒂芬
fasdfd 1234567890
⼀一⼆二三四五六七⼋八九⼗十
Foxit PhantomPDF
打发撒地⽅阿斯蒂芬
fasdfd 1234567890
⼀⼆三四五六七⼋九⼗
Foxit PDF SDK
打发撒地⽅阿斯蒂芬
fasdfd 1234567890
⼀⼆三四五六七⼋九⼗
This isn't an uncommon scenario -- there are many malformed PDF files out in the wild and unfortunately it's often left up to PDF viewers to overcome these issues -- though it is unusual that the technology used to create the PDF (Quartz PDFContext) can't itself properly process the resulting PDF. It's unlikely you could repair the PDF manually.

Conditional formatting of exported filtered items in JIRA

I recently customized the structure of filter exports to Excel following the instructions found at https://developer.atlassian.com/display/JIRADEV/Customising+JIRA+Excel+Output. This is great if you want to change the look and feel of the exported excel file.
However, how would I achieve conditional formatting based on status of exported issue set. For example, I would always like to see the "Closed" issues in Green color and "Ready to Test" items in Yellow. How do I achieve this?
Expected outcome
You could also use the Traffic Light add-on to create a custom field with the chosen color.
https://marketplace.atlassian.com/plugins/de.polscheit.jira.plugins.traffic-light_status
This is less distracting than coloring an entire row I find.
Use the Better Excel Plugin to export JIRA issues to custom Excel spreadsheets.
Important difference: these are real Excel files (XLSX format), unlike the HTML tables produced by the built-in Excel export feature.
You can use so-called tags to implement custom behaviour in the template. These are similar to HTML or JSP tags. In your case you should use the jt:style tag to specify the fill-background-color and fill-pattern properties, and wrap it in a jt:if condition.
Disclaimer: I'm a developer working on this plugin.

How to export interactive PDF for iOs?

I have an interactive PDF, a catalog, where you have to click on a image to go to a specific page. All images are converted in buttons with the option "Go to destination". On Windows and Mac it works perfectly. But on iPad all the links, all the images, are not showing.
I've already read on many forums about this common problem between iOs and interactive PDF's. But I have some old PDF's, with the same principle, and those are working great on iPad. The images are showed, the links works...
That's why I'm wondering if it's not my fault or maybe I export the PDF in a wrong way.
The links to the PDF's.
m.hconline.eu/Baby%20Catalogue.pdf
m.hconline.eu/LA Catalog 2013.pdf
"Buttons" are not compatible with most pdf readers (except Acrobat reader and a few others). Such buttons are not recognized on the standard pdf reader on the iPad. I have checked the old file on the iPad, it does not work as well.
What you need to do is to use regular pdf links instead of buttons. In order to do so, you can use Acrobat Pro, delete your buttons, and create new links using the chain icon. You can specify the area of the link, so the user experience will be the same.
This is an old issue, but I did find more information regarding this. (I'd add a comment to the accepted answer, but alas, i do not have 50 points.)
According to George Johnson, "The problem with InDesign is in using the Go To Next/Previous Page options in InDesign[buttons], it creates an Execute a Menu Item action when exported to PDF, and since Reader for iOS doesn’t have menu items or interprets such actions otherwise, they are just ignored." - https://forums.adobe.com/thread/1142056?tstart=0
As for work arounds, I found a tutorial by Steve Werner, outlining the method of changing your work flow around, and adding your buttons in Adobe Acrobat instead, as kind of a post production linking process. - http://indesignsecrets.com/navigation-button-tricks-for-interactive-pdf-on-an-ipad.php

Search Words in pdf files

Is it possible to search "words" in pdf files with delphi?
I have code with which I can search in many others files like (exe, dll, txt) but it doesn't work with pdf files.
It depends on the structure of the specific PDF.
If the pdf is made of images (scanned pages) then you have to OCR each image and build a full text index inside the PDF. (To see if its image based, open it with notepad and look for obj tags full of random chars). There are a few utilities and apps that do this kind of work for you, CVision PDF Compressor is one that I have used before.
If the pdf is a standard PDF, then you should be able to open it like any other text file and search for the words.
Here is page that will detail some of the structure of a PDF. This a SO post for the same.
The components/libraries mentioned in the answer to this question should do what you need.
I'm just working on a project that does this. The method I use is to convert the PDF file to plain text (with pdftotext.exe) and create an index on the resulting text. We do the same with word and other office files, works pretty good!
Searching directly into pdf files from Delphi (without external app) is more difficult I think. If you find anything, please update here as I would also be very interested in that!
One option I have used is to use Microsoft's ifilter technology, this is used by windows desktop search and many other products such as sharepoint and SQL server full-text search.
It supports almost any office/office-like file format, even dwg, msg, pdf, and files in zip/rar archives.
The easiest way to use it is to run FiltDump.exe on any files you have, and index the text output.
To know about the filters installed on your PC, you can use ifilter explorer.
Wikipedia has some links on its ifilters page.
Quick PDF Library's GetPageText function can give you the words from a PDF as well as the page number and the co-ordinates of those words - sometimes useful for highlighting.
PDF is not just a binary representation. Think of it as a tree of objects, where an object node has some metadata and some content information. Some of these objects have string data, some don't. Some of these are even encrypted, and some are compressed. So, there's very little chance your string finder will work on any arbitrary PDF.

Resources