From 7e4b15542de650e4ae7afe706d709cea250710ae Mon Sep 17 00:00:00 2001 From: Pino Toscano Date: Mon, 20 Aug 2007 20:25:22 +0000 Subject: [PATCH] Usability work on the toolbar: - shorten the toolbar labels of the Previous/Next Page actions, and put them into the toolbar by default instead of the Back/Forward [history control] - shorten the toolbar labels of the tool buttons - remove the Open/Open recent button from the shell toolbar svn path=/trunk/KDE/kdegraphics/okular/; revision=702549 --- part.cpp | 4 ++++ part.rc | 5 ++--- shell/shell.rc | 2 +- ui/pageview.cpp | 4 ++++ 4 files changed, 11 insertions(+), 4 deletions(-) diff --git a/part.cpp b/part.cpp index 44ad0e14c..7f0118ba7 100644 --- a/part.cpp +++ b/part.cpp @@ -274,6 +274,8 @@ m_searchStarted(false), m_cliPresentation(false) m_prevPage = KStandardAction::prior(this, SLOT(slotPreviousPage()), ac); ac->addAction("previous_page", m_prevPage); + m_prevPage->setIconText( i18nc( "Previous page", "Previous" ) ); + m_prevPage->setToolTip( i18n( "Go back to the Previous Page" ) ); m_prevPage->setWhatsThis( i18n( "Moves to the previous page of the document" ) ); m_prevPage->setShortcut( 0 ); // dirty way to activate prev page when pressing miniBar's button @@ -282,6 +284,8 @@ m_searchStarted(false), m_cliPresentation(false) m_nextPage = KStandardAction::next(this, SLOT(slotNextPage()), ac ); ac->addAction("next_page", m_nextPage); + m_nextPage->setIconText( i18nc( "Next page", "Next" ) ); + m_nextPage->setToolTip( i18n( "Advance to the Next Page" ) ); m_nextPage->setWhatsThis( i18n( "Moves to the next page of the document" ) ); m_nextPage->setShortcut( 0 ); // dirty way to activate next page when pressing miniBar's button diff --git a/part.rc b/part.rc index e9b8c8f1f..a9b6b5593 100644 --- a/part.rc +++ b/part.rc @@ -76,9 +76,8 @@ Main Toolbar - - - + + diff --git a/shell/shell.rc b/shell/shell.rc index 4b04f1bdb..e8e8cff30 100644 --- a/shell/shell.rc +++ b/shell/shell.rc @@ -16,7 +16,7 @@ Main Toolbar - + diff --git a/ui/pageview.cpp b/ui/pageview.cpp index 247bda9fd..beff98b99 100644 --- a/ui/pageview.cpp +++ b/ui/pageview.cpp @@ -419,6 +419,7 @@ void PageView::setupActions( KActionCollection * ac ) d->aMouseNormal = new KAction( KIcon( "input-mouse" ), i18n( "&Browse Tool" ), this ); ac->addAction("mouse_drag", d->aMouseNormal ); connect( d->aMouseNormal, SIGNAL( triggered() ), this, SLOT( slotSetMouseNormal() ) ); + d->aMouseNormal->setIconText( i18nc( "Browse Tool", "Browse" ) ); d->aMouseNormal->setCheckable( true ); d->aMouseNormal->setShortcut( Qt::CTRL + Qt::Key_1 ); d->aMouseNormal->setActionGroup( actGroup ); @@ -427,6 +428,7 @@ void PageView::setupActions( KActionCollection * ac ) KAction * mz = new KAction(KIcon( "zoom-original" ), i18n("&Zoom Tool"), this); ac->addAction("mouse_zoom", mz ); connect( mz, SIGNAL( triggered() ), this, SLOT( slotSetMouseZoom() ) ); + mz->setIconText( i18nc( "Zoom Tool", "Zoom" ) ); mz->setCheckable( true ); mz->setShortcut( Qt::CTRL + Qt::Key_2 ); mz->setActionGroup( actGroup ); @@ -434,6 +436,7 @@ void PageView::setupActions( KActionCollection * ac ) d->aMouseSelect = new KAction(KIcon( "frame-edit" ), i18n("&Select Tool"), this); ac->addAction("mouse_select", d->aMouseSelect ); connect( d->aMouseSelect, SIGNAL( triggered() ), this, SLOT( slotSetMouseSelect() ) ); + d->aMouseSelect->setIconText( i18nc( "Select Tool", "Select" ) ); d->aMouseSelect->setCheckable( true ); d->aMouseSelect->setShortcut( Qt::CTRL + Qt::Key_3 ); d->aMouseSelect->setActionGroup( actGroup ); @@ -441,6 +444,7 @@ void PageView::setupActions( KActionCollection * ac ) d->aMouseTextSelect = new KAction(KIcon( "text" ), i18n("&Text Selection Tool"), this); ac->addAction("mouse_textselect", d->aMouseTextSelect ); connect( d->aMouseTextSelect, SIGNAL( triggered() ), this, SLOT( slotSetMouseTextSelect() ) ); + d->aMouseTextSelect->setIconText( i18nc( "Text Selection Tool", "Text Selection" ) ); d->aMouseTextSelect->setCheckable( true ); d->aMouseTextSelect->setShortcut( Qt::CTRL + Qt::Key_4 ); d->aMouseTextSelect->setActionGroup( actGroup );