module Asciidoctor::PdfCore::PdfObject
Public Instance Methods
str2pdfobj(string)
click to toggle source
str2pdfval(string)
click to toggle source
Convert the string to a PDF literal string if it can be encoded as ASCII-8BIT. Otherwise, return the specified string.
# File lib/asciidoctor-pdf/pdf_core_ext/pdf_object.rb, line 8 def str2pdfval string if string && string.ascii_only? ::PDF::Core::LiteralString.new(string.encode ::Encoding::ASCII_8BIT) else string end end