396 def convert_view_to_post(self, the_post):
397 for line in self.view.split_by_newlines(sublime.Region(self.end, self.size)):
398 self.size = line.end()
399 line = self.convert_line_to_post()
400 the_post.write(self.print_line(line, self.curr_row))
401 self.curr_row += 1
402
403 def format_text(self, line, text, the_colour, the_style, highlight=False):
404 code = (FORUM_CODE % {"color": the_colour, "content": text}).replace('\n', '')
405 line.append(code)
406
407 def convert_line_to_post(self):
408 line = []
409 hl_found = False
410
411 # Continue highlight form last line
412 if self.hl_continue != None:
413 self.curr_hl = self.hl_continue
414 self.hl_continue = None
def convert_view_to_post(self, the_post):
for line in self.view.split_by_newlines(sublime.Region(self.end, self.size)):
self.empty_space = None
self.size = line.end()
line = self.convert_line_to_post()
the_post.write(self.print_line(line, self.curr_row))
self.curr_row += 1
149 def convert_view_to_post(self, the_post):
150 for line in self.view.split_by_newlines(sublime.Region(self.end, self.size)):
151 self.empty_space = None
152 self.size = line.end()
153 line = self.convert_line_to_post()
154 the_post.write(self.print_line(line, self.curr_row))
155 self.curr_row += 1
Return to Plugin Announcements
Users browsing this forum: No registered users and 6 guests