mirror of
https://github.com/ankitects/anki.git
synced 2025-09-21 23:42:23 -04:00
bigger spacing for all but mac; mention httplib2>0.7
This commit is contained in:
parent
91cbd316b1
commit
be09087ffd
5 changed files with 11 additions and 10 deletions
1
README
1
README
|
@ -7,6 +7,7 @@ Prerequisites for Linux/FreeBSD/etc:
|
||||||
- Python-Qt/PyQt 4.6+
|
- Python-Qt/PyQt 4.6+
|
||||||
- SimpleJSON 1.7.3+
|
- SimpleJSON 1.7.3+
|
||||||
- Beautiful Soup
|
- Beautiful Soup
|
||||||
|
- Httplib2 0.7+
|
||||||
|
|
||||||
For audio playing support:
|
For audio playing support:
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
|
|
||||||
from aqt.qt import *
|
from aqt.qt import *
|
||||||
from aqt.utils import askUser, getOnlyText, openLink, showWarning
|
from aqt.utils import askUser, getOnlyText, openLink, showWarning
|
||||||
from anki.utils import isWin
|
from anki.utils import isMac
|
||||||
import aqt
|
import aqt
|
||||||
|
|
||||||
class DeckBrowser(object):
|
class DeckBrowser(object):
|
||||||
|
@ -149,7 +149,7 @@ Are you sure you wish to delete all of the cards in %s?""")%deck['name']):
|
||||||
for b in links:
|
for b in links:
|
||||||
buf += "<button onclick='py.link(\"%s\");'>%s</button>" % tuple(b)
|
buf += "<button onclick='py.link(\"%s\");'>%s</button>" % tuple(b)
|
||||||
self.bottom.draw(buf)
|
self.bottom.draw(buf)
|
||||||
self.bottom.web.setFixedHeight(isWin and 36 or 32)
|
self.bottom.web.setFixedHeight(isMac and 28 or 36)
|
||||||
self.bottom.web.setLinkHandler(self._linkHandler)
|
self.bottom.web.setLinkHandler(self._linkHandler)
|
||||||
|
|
||||||
def _onShared(self):
|
def _onShared(self):
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
|
|
||||||
from aqt.qt import *
|
from aqt.qt import *
|
||||||
import re, os, sys, urllib2, ctypes, simplejson, traceback
|
import re, os, sys, urllib2, ctypes, simplejson, traceback
|
||||||
from anki.utils import stripHTML, isWin, namedtmp
|
from anki.utils import stripHTML, isWin, isMac, namedtmp
|
||||||
from anki.sound import play
|
from anki.sound import play
|
||||||
from anki.hooks import runHook
|
from anki.hooks import runHook
|
||||||
from aqt.sound import getAudio
|
from aqt.sound import getAudio
|
||||||
|
@ -277,7 +277,7 @@ class Editor(object):
|
||||||
self.widget.setStyle(self.plastiqueStyle)
|
self.widget.setStyle(self.plastiqueStyle)
|
||||||
# icons
|
# icons
|
||||||
self.iconsBox = QHBoxLayout()
|
self.iconsBox = QHBoxLayout()
|
||||||
if isWin:
|
if not isMac:
|
||||||
self.iconsBox.setMargin(6)
|
self.iconsBox.setMargin(6)
|
||||||
else:
|
else:
|
||||||
self.iconsBox.setMargin(0)
|
self.iconsBox.setMargin(0)
|
||||||
|
|
|
@ -7,7 +7,7 @@ from aqt.qt import *
|
||||||
from anki.consts import NEW_CARDS_RANDOM
|
from anki.consts import NEW_CARDS_RANDOM
|
||||||
from anki.hooks import addHook
|
from anki.hooks import addHook
|
||||||
from aqt.utils import showInfo, openLink
|
from aqt.utils import showInfo, openLink
|
||||||
from anki.utils import isWin
|
from anki.utils import isMac
|
||||||
import aqt
|
import aqt
|
||||||
|
|
||||||
class Overview(object):
|
class Overview(object):
|
||||||
|
@ -150,5 +150,5 @@ text-align: left;
|
||||||
for b in links:
|
for b in links:
|
||||||
buf += "<button onclick='py.link(\"%s\");'>%s</button>" % tuple(b)
|
buf += "<button onclick='py.link(\"%s\");'>%s</button>" % tuple(b)
|
||||||
self.bottom.draw(buf)
|
self.bottom.draw(buf)
|
||||||
self.bottom.web.setFixedHeight(isWin and 36 or 32)
|
self.bottom.web.setFixedHeight(isMac and 28 or 36)
|
||||||
self.bottom.web.setLinkHandler(self._linkHandler)
|
self.bottom.web.setLinkHandler(self._linkHandler)
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
import time, os, stat, shutil, difflib, simplejson, re
|
import time, os, stat, shutil, difflib, simplejson, re
|
||||||
import unicodedata as ucd
|
import unicodedata as ucd
|
||||||
from aqt.qt import *
|
from aqt.qt import *
|
||||||
from anki.utils import fmtTimeSpan, stripHTML, isWin
|
from anki.utils import fmtTimeSpan, stripHTML, isMac
|
||||||
from anki.hooks import addHook, runHook, runFilter
|
from anki.hooks import addHook, runHook, runFilter
|
||||||
from anki.sound import playFromText, clearAudioQueue, hasSound
|
from anki.sound import playFromText, clearAudioQueue, hasSound
|
||||||
from aqt.utils import mungeQA, getBase, shortcut
|
from aqt.utils import mungeQA, getBase, shortcut
|
||||||
|
@ -30,10 +30,10 @@ class Reviewer(object):
|
||||||
self.mw.keyHandler = self._keyHandler
|
self.mw.keyHandler = self._keyHandler
|
||||||
self.web.setLinkHandler(self._linkHandler)
|
self.web.setLinkHandler(self._linkHandler)
|
||||||
self.web.setKeyHandler(self._catchEsc)
|
self.web.setKeyHandler(self._catchEsc)
|
||||||
if isWin:
|
if isMac:
|
||||||
self.bottom.web.setFixedHeight(52)
|
|
||||||
else:
|
|
||||||
self.bottom.web.setFixedHeight(46)
|
self.bottom.web.setFixedHeight(46)
|
||||||
|
else:
|
||||||
|
self.bottom.web.setFixedHeight(52)
|
||||||
self.bottom.web.setLinkHandler(self._linkHandler)
|
self.bottom.web.setLinkHandler(self._linkHandler)
|
||||||
self.nextCard()
|
self.nextCard()
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue