From 37aefe13ffa9ef5e2641933ce248817d61a22bcc Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=BCrgen=20Spitzm=C3=BCller?= Date: Sat, 26 Apr 2008 08:07:46 +0000 Subject: [PATCH] improvements to the Citation UI. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@24507 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/BiblioInfo.cpp | 2 +- src/frontends/qt4/GuiCitation.cpp | 4 +- src/frontends/qt4/ui/CitationUi.ui | 583 ++++++++++++++++++----------- 3 files changed, 377 insertions(+), 212 deletions(-) diff --git a/src/BiblioInfo.cpp b/src/BiblioInfo.cpp index d83be514b5..0dd050a45c 100644 --- a/src/BiblioInfo.cpp +++ b/src/BiblioInfo.cpp @@ -435,7 +435,7 @@ unsigned int const nCiteCommands = CiteStyle const citeStylesArray[] = { CITE, NOCITE, CITET, CITEP, CITEALT, -CITEALP, CITEAUTHOR, CITEYEAR, CITEYEARPAR }; + CITEALP, CITEAUTHOR, CITEYEAR, CITEYEARPAR }; unsigned int const nCiteStyles = sizeof(citeStylesArray) / sizeof(CiteStyle); diff --git a/src/frontends/qt4/GuiCitation.cpp b/src/frontends/qt4/GuiCitation.cpp index c70b7c5938..01d1b92253 100644 --- a/src/frontends/qt4/GuiCitation.cpp +++ b/src/frontends/qt4/GuiCitation.cpp @@ -111,6 +111,8 @@ GuiCitation::GuiCitation(GuiView & lv) this, SLOT(on_okPB_clicked())); bc().setPolicy(ButtonPolicy::NoRepeatedApplyReadOnlyPolicy); + // FIXME: the sizeHint() for this is _way_ too high + infoML->setFixedHeight(60); } @@ -132,7 +134,7 @@ void GuiCitation::closeEvent(QCloseEvent * e) void GuiCitation::applyView() { - int const choice = max(0, citationStyleCO->currentIndex()); + int const choice = max(0, citationStyleCO->currentIndex()); style_ = choice; bool const full = fulllistCB->isChecked(); bool const force = forceuppercaseCB->isChecked(); diff --git a/src/frontends/qt4/ui/CitationUi.ui b/src/frontends/qt4/ui/CitationUi.ui index 66a5fc1c61..8d952be4f5 100644 --- a/src/frontends/qt4/ui/CitationUi.ui +++ b/src/frontends/qt4/ui/CitationUi.ui @@ -6,11 +6,13 @@ 0 0 467 - 692 + 572 - + + 1 + 1 0 0 @@ -22,131 +24,24 @@ true - - - - - - - 0 - 0 - - - - Move the selected citation up (try Ctrl-Up) - - - &Up - - - - - - false - - - - - - - - 0 - 0 - - - - Move the selected citation down (try Ctrl-Down) - - - &Down - - - - - - false - - - - - - - Qt::Vertical - - - - 77 - 16 - - - - - - - - The delete key works, too - - - D&elete - - - false - - - - - - - QAbstractItemView::NoEditTriggers - - - - - - - The Enter key works, too - - - &Add - - - false - - - - - - - &Selected Citations: - - - selectedLV - - - - - - - A&vailable Citations: - - - availableLV - - - - - - - QAbstractItemView::NoEditTriggers - - - - - + + 9 + + + 6 + - - - Qt::NoFocus + + + + 7 + 4 + 0 + 0 + + + + true @@ -159,6 +54,12 @@ true + + 9 + + + 6 + @@ -307,7 +208,7 @@ - Search As You Type + Search As You &Type @@ -323,100 +224,188 @@ true - - - - - 0 - 0 - - - - Natbib citation style to use - - - - - - - Citation st&yle: - - - citationStyleCO - - - - - - - List all authors - - - Full aut&hor list - - - - - - - Force upper case in citation - - - &Force upper case - - - - - - - &Text after: - - - textAfterED - - - - - - - - 0 - 0 - - - - Text to place after citation - - - + + 9 + + + 6 + - - - Text &before: + + + 0 - - textAfterED + + 6 - + + + + List all authors + + + Full aut&hor list + + + + + + + Force upper case in citation + + + Force u&pper case + + + + + + + Qt::Horizontal + + + + 21 + 20 + + + + + - - - - - 0 - 0 - + + + + 0 - - Text to place before citation + + 6 - + + + + 0 + + + 6 + + + + + Citation st&yle: + + + citationStyleCO + + + + + + + Text &before: + + + textBeforeED + + + + + + + + + 0 + + + 6 + + + + + 0 + + + 6 + + + + + + 3 + 0 + 0 + 0 + + + + Natbib citation style to use + + + + + + + + + 0 + + + 6 + + + + + + 3 + 0 + 0 + 0 + + + + Text to place before citation + + + + + + + Text a&fter: + + + textAfterED + + + + + + + + 3 + 0 + 0 + 0 + + + + Text to place after citation + + + + + + + + + + 0 + 6 @@ -459,7 +448,7 @@ - A&pply + App&ly false @@ -478,6 +467,180 @@ + + + + 0 + + + 6 + + + + + 0 + + + 6 + + + + + A&vailable Citations: + + + availableLV + + + + + + + Qt::Horizontal + + + + 71 + 20 + + + + + + + + &Selected Citations: + + + selectedLV + + + + + + + + + 0 + + + 6 + + + + + QAbstractItemView::NoEditTriggers + + + + + + + 0 + + + 6 + + + + + The Enter key works, too + + + &Add + + + false + + + + + + + The delete key works, too + + + D&elete + + + false + + + + + + + Qt::Vertical + + + + 77 + 20 + + + + + + + + + 1 + 0 + 0 + 0 + + + + Move the selected citation up (try Ctrl-Up) + + + &Up + + + + + + false + + + + + + + + 1 + 0 + 0 + 0 + + + + Move the selected citation down (try Ctrl-Down) + + + &Down + + + + + + false + + + + + + + + + QAbstractItemView::NoEditTriggers + + + + + + + -- 2.39.2