Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[node editor] Use a timer to properly raise panel, improve hint label
  • Loading branch information
nirvn committed Jan 23, 2019
1 parent 0a239fa commit 5e56845
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
3 changes: 2 additions & 1 deletion src/app/vertextool/qgsvertexeditor.cpp
Expand Up @@ -309,7 +309,8 @@ QgsVertexEditor::QgsVertexEditor(
layout->setContentsMargins( 0, 0, 0, 0 );

mHintLabel = new QLabel( this );
mHintLabel->setText( tr( "Right click on the edge of an editable feature to show its table of vertices" ) );
mHintLabel->setText( QStringLiteral( "%1\n\n%2" ).arg( tr( "Right click on the edge of an editable feature to show its table of vertices." ),
tr( "When a feature is bound to this panel, dragging a rectangle to select vertices on the canvas will only select those of the bound feature." ) ) );
mHintLabel->setWordWrap( true );
mHintLabel->setAlignment( Qt::AlignHCenter | Qt::AlignVCenter );

Expand Down
5 changes: 2 additions & 3 deletions src/app/vertextool/qgsvertextool.cpp
Expand Up @@ -41,7 +41,7 @@

#include <QMenu>
#include <QRubberBand>

#include <QTimer>

uint qHash( const Vertex &v )
{
Expand Down Expand Up @@ -1096,8 +1096,7 @@ void QgsVertexTool::showVertexEditor() //#spellok
connect( mVertexEditor.get(), &QgsVertexEditor::deleteSelectedRequested, this, &QgsVertexTool::deleteVertexEditorSelection );
connect( mVertexEditor.get(), &QgsVertexEditor::editorClosed, this, &QgsVertexTool::cleanupVertexEditor );

mVertexEditor->show();
mVertexEditor->raise();
QTimer::singleShot( 100, this, [ = ] { mVertexEditor->show(); mVertexEditor->raise(); } );
}
else
{
Expand Down

0 comments on commit 5e56845

Please sign in to comment.