From 1313cca3568853cea3d59fc4ad7b4ca677c923f8 Mon Sep 17 00:00:00 2001 From: Damien Elmes Date: Fri, 21 Nov 2008 14:58:26 +0900 Subject: [PATCH] add help to display properties --- ankiqt/ui/displayproperties.py | 10 ++- designer/displayproperties.ui | 150 +++++++++++++++------------------ 2 files changed, 77 insertions(+), 83 deletions(-) diff --git a/ankiqt/ui/displayproperties.py b/ankiqt/ui/displayproperties.py index 14a62e925..6287417af 100644 --- a/ankiqt/ui/displayproperties.py +++ b/ankiqt/ui/displayproperties.py @@ -31,7 +31,7 @@ class DisplayProperties(QDialog): self.setupChooser() self.setupCards() self.setupFields() - self.setupPreview() + self.setupButtons() self.show() ui.dialogs.open("DisplayProperties", self) @@ -48,9 +48,11 @@ class DisplayProperties(QDialog): self.drawCards() self.drawFields() - def setupPreview(self): + def setupButtons(self): self.connect(self.dialog.preview, SIGNAL("clicked()"), self.previewClicked) + self.connect(self.dialog.helpButton, SIGNAL("clicked()"), + self.onHelp) if self.main.config['showFontPreview']: self.dialog.preview.setChecked(True) else: @@ -286,3 +288,7 @@ class DisplayProperties(QDialog): def reject(self): ui.dialogs.close("DisplayProperties") QDialog.reject(self) + + def onHelp(self): + QDesktopServices.openUrl(QUrl(ankiqt.appWiki + + "DisplayProperties")) diff --git a/designer/displayproperties.ui b/designer/displayproperties.ui index 2c833b9de..1816f5031 100644 --- a/designer/displayproperties.ui +++ b/designer/displayproperties.ui @@ -10,9 +10,7 @@ - - 5 - 3 + 0 0 @@ -24,18 +22,19 @@ - Fonts and colours + Fonts & Colours - :/icons/fonts.png + + :/icons/fonts.png:/icons/fonts.png - - 9 - 6 + + 9 + @@ -47,9 +46,7 @@ - - 0 - 5 + 0 0 @@ -73,28 +70,28 @@ QFrame::Raised - - 0 - 6 + + 0 + - - 0 - 7 + + 0 + - - 0 - 6 + + 0 + @@ -111,9 +108,7 @@ - - 0 - 5 + 0 0 @@ -134,12 +129,12 @@ Card properties - - 3 - 6 + + 3 + @@ -250,9 +245,7 @@ - - 5 - 5 + 0 0 @@ -270,18 +263,16 @@ Fields - - 3 - 6 + + 3 + - - 5 - 3 + 0 0 @@ -312,9 +303,7 @@ - - 1 - 1 + 0 0 @@ -343,9 +332,7 @@ - - 1 - 1 + 0 0 @@ -363,20 +350,18 @@ - - 300 - 5 + + 300 + - - 1 - 1 + 0 0 @@ -424,20 +409,18 @@ - - 300 - 5 + + 300 + - - 1 - 0 + 0 0 @@ -456,9 +439,7 @@ - - 1 - 0 + 0 0 @@ -468,9 +449,7 @@ - - 1 - 0 + 0 0 @@ -488,22 +467,36 @@ + + + + + + Help + + + false + + + + + + + Show preview + + + true + + + false + + + + + - - - - Show preview - - - true - - - false - - - @@ -515,18 +508,16 @@ Preview - + 6 - + 6 - - 7 - 3 + 0 0 @@ -545,9 +536,7 @@ - - 7 - 3 + 0 0 @@ -585,7 +574,6 @@ fontFamilyEdit useSizeEdit fontSizeEdit - preview question answer