mirror of
https://github.com/ankitects/anki.git
synced 2025-09-19 14:32:22 -04:00
fix flicker, various ui tweaks
This commit is contained in:
parent
e21efd4802
commit
20ec3bef2b
3 changed files with 37 additions and 16 deletions
|
@ -939,13 +939,15 @@ To upgrade an old deck, download Anki 0.9.8.7."""))
|
||||||
ankiqt.appWiki + "StudyOptions")))
|
ankiqt.appWiki + "StudyOptions")))
|
||||||
|
|
||||||
def showStudyScreen(self):
|
def showStudyScreen(self):
|
||||||
self.switchToStudyScreen()
|
|
||||||
self.mainWin.optionsButton.setChecked(self.config['showStudyOptions'])
|
self.mainWin.optionsButton.setChecked(self.config['showStudyOptions'])
|
||||||
self.mainWin.optionsBox.setShown(self.config['showStudyOptions'])
|
self.mainWin.optionsBox.setShown(self.config['showStudyOptions'])
|
||||||
|
self.switchToStudyScreen()
|
||||||
initial = self.deck.sessionStartTime == 0
|
initial = self.deck.sessionStartTime == 0
|
||||||
if initial or not self.deck.sessionLimitReached():
|
if initial:
|
||||||
# deck just opened, or screen triggered manually
|
# deck just opened, or screen triggered manually
|
||||||
top = _("<h1>Welcome back!</h1>")
|
top = _("<h1>Welcome Back!</h1>")
|
||||||
|
elif not self.deck.sessionLimitReached():
|
||||||
|
top = _("<h1>Study Options</h1>")
|
||||||
else:
|
else:
|
||||||
top = _("<h1>Well done!</h1>")
|
top = _("<h1>Well done!</h1>")
|
||||||
# top label
|
# top label
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
<rect>
|
<rect>
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>335</width>
|
<width>391</width>
|
||||||
<height>400</height>
|
<height>400</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
|
@ -29,7 +29,7 @@
|
||||||
<rect>
|
<rect>
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>319</width>
|
<width>375</width>
|
||||||
<height>334</height>
|
<height>334</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
|
|
|
@ -164,8 +164,8 @@
|
||||||
<rect>
|
<rect>
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>550</width>
|
<width>542</width>
|
||||||
<height>413</height>
|
<height>504</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QVBoxLayout" name="verticalLayout_5" >
|
<layout class="QVBoxLayout" name="verticalLayout_5" >
|
||||||
|
@ -186,8 +186,8 @@
|
||||||
<rect>
|
<rect>
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>550</width>
|
<width>542</width>
|
||||||
<height>413</height>
|
<height>504</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QVBoxLayout" name="verticalLayout_2" >
|
<layout class="QVBoxLayout" name="verticalLayout_2" >
|
||||||
|
@ -216,6 +216,9 @@
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_4" >
|
<layout class="QHBoxLayout" name="horizontalLayout_4" >
|
||||||
<item>
|
<item>
|
||||||
<layout class="QVBoxLayout" name="verticalLayout_11" >
|
<layout class="QVBoxLayout" name="verticalLayout_11" >
|
||||||
|
<property name="topMargin" >
|
||||||
|
<number>4</number>
|
||||||
|
</property>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QLabel" name="optionsLabel" >
|
<widget class="QLabel" name="optionsLabel" >
|
||||||
<property name="text" >
|
<property name="text" >
|
||||||
|
@ -229,7 +232,7 @@
|
||||||
<enum>Qt::Vertical</enum>
|
<enum>Qt::Vertical</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizeType" >
|
<property name="sizeType" >
|
||||||
<enum>QSizePolicy::Preferred</enum>
|
<enum>QSizePolicy::Fixed</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizeHint" stdset="0" >
|
<property name="sizeHint" stdset="0" >
|
||||||
<size>
|
<size>
|
||||||
|
@ -246,7 +249,7 @@
|
||||||
<item>
|
<item>
|
||||||
<widget class="QPushButton" name="optionsButton" >
|
<widget class="QPushButton" name="optionsButton" >
|
||||||
<property name="text" >
|
<property name="text" >
|
||||||
<string>Review &Options>></string>
|
<string>Options>></string>
|
||||||
</property>
|
</property>
|
||||||
<property name="checkable" >
|
<property name="checkable" >
|
||||||
<bool>true</bool>
|
<bool>true</bool>
|
||||||
|
@ -308,7 +311,7 @@
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="1" column="1" >
|
<item row="1" column="2" >
|
||||||
<widget class="QLineEdit" name="minuteLimit" >
|
<widget class="QLineEdit" name="minuteLimit" >
|
||||||
<property name="sizePolicy" >
|
<property name="sizePolicy" >
|
||||||
<sizepolicy vsizetype="Fixed" hsizetype="Maximum" >
|
<sizepolicy vsizetype="Fixed" hsizetype="Maximum" >
|
||||||
|
@ -331,7 +334,7 @@
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="2" column="1" >
|
<item row="2" column="2" >
|
||||||
<widget class="QLineEdit" name="questionLimit" >
|
<widget class="QLineEdit" name="questionLimit" >
|
||||||
<property name="sizePolicy" >
|
<property name="sizePolicy" >
|
||||||
<sizepolicy vsizetype="Fixed" hsizetype="Preferred" >
|
<sizepolicy vsizetype="Fixed" hsizetype="Preferred" >
|
||||||
|
@ -347,7 +350,7 @@
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="1" column="2" >
|
<item row="1" column="3" >
|
||||||
<spacer name="horizontalSpacer_3" >
|
<spacer name="horizontalSpacer_3" >
|
||||||
<property name="orientation" >
|
<property name="orientation" >
|
||||||
<enum>Qt::Horizontal</enum>
|
<enum>Qt::Horizontal</enum>
|
||||||
|
@ -373,7 +376,7 @@
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="0" column="1" >
|
<item row="0" column="2" >
|
||||||
<widget class="QLineEdit" name="newPerDay" >
|
<widget class="QLineEdit" name="newPerDay" >
|
||||||
<property name="sizePolicy" >
|
<property name="sizePolicy" >
|
||||||
<sizepolicy vsizetype="Fixed" hsizetype="Preferred" >
|
<sizepolicy vsizetype="Fixed" hsizetype="Preferred" >
|
||||||
|
@ -389,6 +392,22 @@
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
<item row="0" column="1" >
|
||||||
|
<spacer name="horizontalSpacer_5" >
|
||||||
|
<property name="orientation" >
|
||||||
|
<enum>Qt::Horizontal</enum>
|
||||||
|
</property>
|
||||||
|
<property name="sizeType" >
|
||||||
|
<enum>QSizePolicy::Preferred</enum>
|
||||||
|
</property>
|
||||||
|
<property name="sizeHint" stdset="0" >
|
||||||
|
<size>
|
||||||
|
<width>10</width>
|
||||||
|
<height>20</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
</spacer>
|
||||||
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
|
@ -1673,7 +1692,7 @@
|
||||||
<normaloff>:/icons/chronometer.png</normaloff>:/icons/chronometer.png</iconset>
|
<normaloff>:/icons/chronometer.png</normaloff>:/icons/chronometer.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text" >
|
<property name="text" >
|
||||||
<string>&Study Options</string>
|
<string>&Study Options...</string>
|
||||||
</property>
|
</property>
|
||||||
</action>
|
</action>
|
||||||
</widget>
|
</widget>
|
||||||
|
|
Loading…
Reference in a new issue