# File lib/Dnsruby/resource/TXT.rb, line 140
      def TXT.display(str, do_escapes = true)
        output = ""
        # Probably need to scan through each string manually

        # Make sure to remember to escape binary characters.

        # Go through copying to output, and adding "\" characters as necessary?

        str.each_byte {|c|
          if (c == 34) || (c == 92) # || (c == 59)

            if (do_escapes)
            output+='\\'
            end
            output+=c.chr
          elsif (c < 32) # c is binary

            if (ESCAPE_CODES[c])
              output +=  c.chr
            else
              output+= '\\'
              num = c.to_i.to_s
              (3-num.length).times {|i|
                num="0"+num
              }
              output+= num # Need a 3 digit number here.

            end

          else
            output += c.chr
          end
        }
        return output
      end