display.py 文件源码

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

项目:sshchan 作者: einchan 项目源码 文件源码
def reply_box(self, button, thr_id):
        subject = ur.Edit(("blue", "Subject: "), wrap="clip")
        name = ur.Edit(("blue", "Name: "), "Anonymous", wrap="clip")
        if thr_id == -1:
            text = ur.Edit(multiline=True)
        else:
            text = ur.Edit(edit_text=">>" + thr_id, multiline=True)
        post_btn = ur.AttrMap(ur.Button(
            "Post", self.add_post, (subject, name, text, thr_id)),
            "green", "b_green")

        box = ur.LineBox(ur.ListBox(ur.SimpleFocusListWalker(
            [name, subject, ur.LineBox(text, "Post text"),
             self.parent.div, post_btn])))

        self.loop.Widget = MyOverlay(
            box, self.loop.baseWidget,
            "center", ("relative", 100), "top", ("relative", 100),
            None, None,
            self.parent.margin, self.parent.margin,
            int(self.loop.dimensions[1] * 0.3),
            int(self.loop.dimensions[1] * 0.3),
            self.parent)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号