mirror of
https://github.com/ankitects/anki.git
synced 2025-11-09 14:17:13 -05:00
add options & cram buttons
This commit is contained in:
parent
975f66e693
commit
6feafbb4ff
1 changed files with 18 additions and 5 deletions
|
|
@ -92,10 +92,13 @@ class Overview(object):
|
||||||
<tr><td>%s:</td><td><b><font color=#a00>%s</font></b></td></tr>
|
<tr><td>%s:</td><td><b><font color=#a00>%s</font></b></td></tr>
|
||||||
<tr><td>%s:</td><td><b><font color=#0a0>%s</font></b></td></tr>
|
<tr><td>%s:</td><td><b><font color=#0a0>%s</font></b></td></tr>
|
||||||
</table>
|
</table>
|
||||||
</td><td>%s</td></tr></table>''' % (_("New"), counts[0],
|
</td><td align=center>
|
||||||
_("In Learning"), counts[1],
|
%s</td></tr></table>''' % (
|
||||||
_("To Review"), counts[2],
|
_("New"), counts[0],
|
||||||
but("study", _("Study"), id="study"))
|
_("In Learning"), counts[1],
|
||||||
|
_("To Review"), counts[2],
|
||||||
|
but("study", _("Study Now"), id="study"))
|
||||||
|
|
||||||
|
|
||||||
_body = """
|
_body = """
|
||||||
<center>
|
<center>
|
||||||
|
|
@ -120,4 +123,14 @@ button { font-weight: bold; }
|
||||||
######################################################################
|
######################################################################
|
||||||
|
|
||||||
def _renderBottom(self):
|
def _renderBottom(self):
|
||||||
self.bottom.draw("hello")
|
links = [
|
||||||
|
["opts", _("Options")],
|
||||||
|
["cram", _("Cram")],
|
||||||
|
]
|
||||||
|
buf = ""
|
||||||
|
for b in links:
|
||||||
|
buf += "<button onclick='py.link(\"%s\");'>%s</button>" % tuple(b)
|
||||||
|
self.bottom.draw(buf)
|
||||||
|
self.bottom.web.setFixedHeight(32)
|
||||||
|
self.bottom.web.setLinkHandler(self._linkHandler)
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue