Commit 81ecf94b authored by Dominik Haumann's avatar Dominik Haumann

use popup menu in view space bar

Unfortuantely, the Oxygen (frameworks 5) style paints the "down"
arrow for a QToolButton without text behind the icon, which looks
wrong: http://wstaw.org/m/2014/01/23/plasma-desktopWX2364.png

Can we do anything about it? :-)
CCMAIL: hugo.pereira@free.fr
parent 2b6c02a5
......@@ -59,16 +59,12 @@ KateViewSpace::KateViewSpace( KateViewManager *viewManager,
// add vertical split view space
QToolButton * split = new QToolButton(this);
split->setAutoRaise(true);
split->setDefaultAction(m_viewManager->mainWindow()->actionCollection()->action(QStringLiteral("view_split_vert")));
split->setWhatsThis(i18n("Split this view horizontally into two views."));
split->installEventFilter(this); // on click, active this view space
hLayout->addWidget(split);
// add horizontally split view space
split = new QToolButton(this);
split->setAutoRaise(true);
split->setDefaultAction(m_viewManager->mainWindow()->actionCollection()->action(QStringLiteral("view_split_horiz")));
split->setWhatsThis(i18n("Split this view vertically into two views."));
split->setPopupMode(QToolButton::InstantPopup);
split->setIcon(QIcon::fromTheme(QStringLiteral("view-split-left-right")));
split->addAction(m_viewManager->mainWindow()->actionCollection()->action(QStringLiteral("view_split_vert")));
split->addAction(m_viewManager->mainWindow()->actionCollection()->action(QStringLiteral("view_split_horiz")));
split->addAction(m_viewManager->mainWindow()->actionCollection()->action(QStringLiteral("view_close_current_space")));
split->setWhatsThis(i18n("Control view space splitting"));
split->installEventFilter(this); // on click, active this view space
hLayout->addWidget(split);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment