edit.py 文件源码

python
阅读 45 收藏 0 点赞 0 评论 0

项目:notex 作者: adiultra 项目源码 文件源码
def insert_char(self, c):
        """Given an integer character, insert that character in the current
        line. Stop when the maximum line length is reached.

        """
        if c not in string.printable:
            return
        para_idx, line_idx, char_idx = self.paragraph
        line = list(self.line)
        line.insert(char_idx, c)
        char_idx += 1
        self.line = "".join(line)
        self._char_index_to_yx(para_idx, char_idx)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号