def _to_repeatmasker_string(pairwise_alignment, column_width=DEFAULT_COL_WIDTH,<EOL>m_name_width=DEFAULT_MAX_NAME_WIDTH):
s1 = pairwise_alignment.s1<EOL>s2 = pairwise_alignment.s2<EOL>s1_neg = not s1.is_positive_strand()<EOL>s2_neg = not s2.is_positive_strand()<EOL>size = pairwise_alignment.size()<EOL>s1_comp = "<STR_LIT:C>" if s1_neg else "<STR_LIT:U+0020>"<EOL>s2_comp = "<STR_LIT:C>" if s2_neg else "<STR_LIT:U+0020>"<EOL>s1_len = len(s1.name)<EOL>s2_len = len(s2.name)<EOL>f_len = max(s1_len, s2_len)<EOL>if m_name_width is not None:<EOL><INDENT>f_len = min(f_len, m_name_width)<EOL><DEDENT>s1_n = s1.name[:f_len] + ('<STR_LIT:U+0020>' * (f_len - s1_len))<EOL>s2_n = s2.name[:f_len] + ('<STR_LIT:U+0020>' * (f_len - s2_len))<EOL>s1_line_end_num = (s1.end if s1_neg else s1.start - <NUM_LIT:1>)<EOL>s2_line_end_num = (s2.end if s2_neg else s2.start - <NUM_LIT:1>)<EOL>max_num_len = max(len(str(s1.start + size)), len(str(s2.start + size)))<EOL>res = "<STR_LIT>"  <EOL>i = <NUM_LIT:0>     <EOL>res += _get_repeat_masker_header(pairwise_alignment) + "<STR_LIT>"<EOL>while i < len(pairwise_alignment.s1):<EOL><INDENT>s1_sub = s1.gapped_relative_subsequence(i + <NUM_LIT:1>, min(i + column_width + <NUM_LIT:1>, len(s1) + <NUM_LIT:1>))<EOL>s2_sub = s2.gapped_relative_subsequence(i + <NUM_LIT:1>, min(i + column_width + <NUM_LIT:1>, len(s2) + <NUM_LIT:1>))<EOL>s1_ug_len = s1_sub.ungapped_len<EOL>s2_ug_len = s2_sub.ungapped_len<EOL>s1_line_start_num = (s1_line_end_num - <NUM_LIT:1> if s1_neg<EOL>else s1_line_end_num + <NUM_LIT:1>)<EOL>s1_line_end_num = (s1_line_start_num - s1_ug_len + <NUM_LIT:1> if s1_neg<EOL>else s1_line_start_num + s1_ug_len - <NUM_LIT:1>)<EOL>s2_line_start_num = (s2_line_end_num - <NUM_LIT:1> if s2_neg<EOL>else s2_line_end_num + <NUM_LIT:1>)<EOL>s2_line_end_num = (s2_line_start_num - s2_ug_len + <NUM_LIT:1> if s2_neg<EOL>else s2_line_start_num + s2_ug_len - <NUM_LIT:1>)<EOL>res += (s1_comp + "<STR_LIT:U+0020>" + s1_n + "<STR_LIT:U+0020>")<EOL>s1_line_start_num_str = str(s1_line_start_num)<EOL>s1_num_padding = max_num_len - len(s1_line_start_num_str)<EOL>res += ('<STR_LIT:U+0020>' * s1_num_padding) + s1_line_start_num_str + "<STR_LIT:U+0020>"<EOL>res += pairwise_alignment.s1[i:i + column_width] + "<STR_LIT:U+0020>"<EOL>res += str(s1_line_end_num) + "<STR_LIT:\n>"<EOL>if ANNOTATION_KEY in pairwise_alignment.meta:<EOL><INDENT>res += (((f_len + max_num_len) * '<STR_LIT:U+0020>') + "<STR_LIT:U+0020>" +<EOL>pairwise_alignment.meta[ANNOTATION_KEY][i:i + column_width] + "<STR_LIT:\n>")<EOL><DEDENT>res += (s2_comp + "<STR_LIT:U+0020>" + s2_n + "<STR_LIT:U+0020>")<EOL>s2_line_start_num_str = str(s2_line_start_num)<EOL>s2_num_padding = max_num_len - len(s2_line_start_num_str)<EOL>res += ('<STR_LIT:U+0020>' * s2_num_padding) + s2_line_start_num_str + "<STR_LIT:U+0020>"<EOL>res += pairwise_alignment.s2[i:i + column_width] + "<STR_LIT:U+0020>"<EOL>res += str(s2_line_end_num) + "<STR_LIT:\n>"<EOL>res += "<STR_LIT:\n>"<EOL>i += column_width<EOL><DEDENT>if pairwise_alignment.meta is not None:<EOL><INDENT>for k in pairwise_alignment.meta:<EOL><INDENT>if k not in KNOWN_KEYS:<EOL><INDENT>if k is ROUNDTRIP_KEY:<EOL><INDENT>res += (pairwise_alignment.meta[k] + "<STR_LIT:\n>")<EOL><DEDENT>else:<EOL><INDENT>res += (k + "<STR_LIT>" + str(pairwise_alignment.meta[k]) + "<STR_LIT:\n>")<EOL><DEDENT><DEDENT><DEDENT><DEDENT>res = res.strip()<EOL>return res<EOL>
generate a repeatmasker formated representation of this pairwise alignment.

:param column_width: number of characters to output per line of alignment
:param m_name_width: truncate names on alignment lines to this length
                     (set to None for no truncation)