diff options
author | Ken Moore <moorekou@gmail.com> | 2016-02-18 08:39:42 -0500 |
---|---|---|
committer | Ken Moore <moorekou@gmail.com> | 2016-02-18 08:39:42 -0500 |
commit | dac025f2af09bff6269233ee634cc82e2ba01265 (patch) | |
tree | bc086627030fb91f8726d25db788cba17511f88f /lumina-desktop | |
parent | Make sure the new windows are registeres with the Lumina session so we can se... (diff) | |
download | lumina-dac025f2af09bff6269233ee634cc82e2ba01265.tar.gz lumina-dac025f2af09bff6269233ee634cc82e2ba01265.tar.bz2 lumina-dac025f2af09bff6269233ee634cc82e2ba01265.zip |
Remove the 80-pixel limit to the text shown on task manager buttons (non-grouped). This allows the buttons to be as large as needed to fit the text, then shrink down automatically when more windows/buttons are opened up.
Diffstat (limited to 'lumina-desktop')
-rw-r--r-- | lumina-desktop/panel-plugins/taskmanager/LTaskButton.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lumina-desktop/panel-plugins/taskmanager/LTaskButton.cpp b/lumina-desktop/panel-plugins/taskmanager/LTaskButton.cpp index 7dba1352..1692b8a5 100644 --- a/lumina-desktop/panel-plugins/taskmanager/LTaskButton.cpp +++ b/lumina-desktop/panel-plugins/taskmanager/LTaskButton.cpp @@ -126,8 +126,8 @@ void LTaskButton::UpdateButton(){ //single window this->setPopupMode(QToolButton::DelayedPopup); this->setMenu(actMenu); - if(showText){ this->setToolButtonStyle(Qt::ToolButtonTextBesideIcon); this->setText( this->fontMetrics().elidedText(WINLIST[0].text(), Qt::ElideRight,80) ); } - else if(noicon){ this->setToolButtonStyle(Qt::ToolButtonTextBesideIcon); this->setText( this->fontMetrics().elidedText(cname, Qt::ElideRight ,80) ); } + if(showText){ this->setToolButtonStyle(Qt::ToolButtonTextBesideIcon); this->setText( WINLIST[0].text()); } + else if(noicon){ this->setToolButtonStyle(Qt::ToolButtonTextBesideIcon); this->setText( cname ); } else{ this->setToolButtonStyle(Qt::ToolButtonIconOnly); this->setText(""); } this->setToolTip(WINLIST[0].text()); }else if(WINLIST.length() > 1){ @@ -135,7 +135,7 @@ void LTaskButton::UpdateButton(){ this->setPopupMode(QToolButton::InstantPopup); this->setMenu(winMenu); this->setToolButtonStyle(Qt::ToolButtonTextBesideIcon); - if(noicon || showText){ this->setText( this->fontMetrics().elidedText(cname, Qt::ElideRight ,80) +" ("+QString::number(WINLIST.length())+")" ); } + if(noicon || showText){ "("+QString::number(WINLIST.length())+") "+cname; } else{ this->setText("("+QString::number(WINLIST.length())+")"); } } this->setState(showstate); //Make sure this is after the button setup so that it properly sets the margins/etc |