示例#1
0
文件: OptionPage.py 项目: aboes/Rigor
    def save_and_back(self):
        """Automatisches Sichern beim Verlassen."""
        self.options = [
            self.var_capitalize.get(),
            self.var_hilfe1.get(),
            self.var_hilfe2.get(),
            self.var_alternative.get(),
            self.var_bemerkungen.get(),
            self.var_hilfe3.get(),
            self.var_time.get()]

        GL.savefile("varia/options.opt", self.options)
        self.controller.show_frame("StartPage")
示例#2
0
    def save_patience(self):
        """Speichert gezielt das benutzte Subthema."""
        self.korpus = [item for sublist in self.patience for item in sublist]

        fname = "data/" + self.topic + ".korp"
        rawread = GL.readfile(fname)
        korpus = GL.loads(rawread)

        for ele in korpus:
            if ele["subset"]["name"] == self.subtopic:
                ele["subset"]["data"] = self.korpus

        GL.savefile(fname, korpus)
示例#3
0
    def save_patience(self):
        """Speichert gezielt das benutzte Subthema."""
        self.korpus = [item for sublist in self.patience for item in sublist]

        fname = "data/" + self.topic + ".korp"
        rawread = GL.readfile(fname)
        korpus = GL.loads(rawread)

        for ele in korpus:
            if ele["subset"]["name"] == self.subtopic:
                ele["subset"]["data"] = self.korpus

        GL.savefile(fname, korpus)
示例#4
0
    def save_and_back(self):
        """Automatisches Sichern beim Verlassen."""
        self.options = [
            self.var_capitalize.get(),
            self.var_hilfe1.get(),
            self.var_hilfe2.get(),
            self.var_alternative.get(),
            self.var_bemerkungen.get(),
            self.var_hilfe3.get(),
            self.var_time.get()
        ]

        GL.savefile("varia/options.opt", self.options)
        self.controller.show_frame("StartPage")