rich text box savefile - textbox

While saving a .rtf file from rich text box the file orientation is not preserved, can anyone give me the solution for this?

Printer settings are not encoded in rtf files (they only describe basic formatting information for the text).

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.

How to make a Photoshop (.psd) file have hyperlinks when saved as a .PDF file?

I created a template for a document i want to use, in photoshop.
I want to share this document as a PDF file.
I want some of the text i made in photoshop to work as hyperlinks and direct ppl to websites.
How do i save a photoshop file as a PDF and get hyperlinks to work in the PDF file?
I have tried using the slice tool. It works to assign a url and target.
But when saved as a PDF the links do not work.
Anyone?
I know that indesign allows for saving pdf documents in either print or web format. the latter allows for hyperlinks to be available. if photoshop does not offer this you can always add them in acrobat (not reader) and then resave the .pdf.

rails editing rtf documents

I want to edit (for example, replace any placeholder by any text) a rtf documents in Rails application.
What is the simplest way to provide it?
Thanks.
There are a few options based on these SO Posts --this too.
TinyMCE
Rich Text Editor
CKEditor
MarkItUp
WMD
However those are all from the UI.
If you want to manipulate it behind the scenes:
Updated branch of ruby-rtf
Ruby-rtf

RTF editor

I have a templates written in RTF(with some tags which are replaced by data from DB in app), but when I edit them in MS Word, Word put some invisible tags to the templates, which destruct my tags(I must open template in Notepad and edit code).
Do you know some editor for RTF, which strict follows RTF specification?
Thanks
On Windows, the included app Wordpad is pretty decent in my opinion.
The RTF spec allows an RTF editor such as Word or a third party control to sprinkle the tags in-between the RTF text, provided that the actually RTF display is maintained. For this reason, there is no way to guarantee that your original template text will not be disturbed. For this reason, I recommend using an RTF editor API to do any search/replacement within your template. The RTF editor knows to put aside the RTF tags and access the original text as intended.
OK, I know that google find bunch of editors, but I don`t have time to try each of them to find out best one.
so I search for advice which is good, not which is avialable
EDIT: I found and for weeks use this solution
TE EDIT
and is very good, I recommend it.

Resources