Exemple #1
0
	def _getLines(self):
		if Util.isPython():
			return ['', 'mock line 1', 'mock line 2', 'mock line 3']
		else:
			import vim
			result = ['']
			for line in vim.current.buffer:
				result.append(line)

			return result
Exemple #2
0
	def setLines(self, lines):
		self.lines = ['']
		self.lines.extend(lines)
		if Util.isPython():
			pass
		else:
			import vim
			vim.command(':normal ggdG')
			for line in self.loop():
				vim.command(':normal o%s' % line)
			vim.command(':normal ggdd')
Exemple #3
0
	def _getName(self):
		if Util.isPython():
			return 'mock'
		else:
			import vim
			return vim.current.buffer.name