Skip to content

Commit

Permalink
Show default color option in code editor color buttons
Browse files Browse the repository at this point in the history
So that if you start tweaking a standard color scheme you can undo
the changes you've made to one class of color
  • Loading branch information
nyalldawson committed Oct 5, 2020
1 parent 425dfcc commit 5e3214f
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/app/options/qgscodeeditoroptions.cpp
Expand Up @@ -69,6 +69,7 @@ QgsCodeEditorOptionsWidget::QgsCodeEditorOptionsWidget( QWidget *parent )
for ( auto it = mColorButtonMap.constBegin(); it != mColorButtonMap.constEnd(); ++it )
{
it.value()->setColor( QgsCodeEditor::color( it.key() ) );
it.value()->setDefaultColor( it.value()->color() );
}

mColorSchemeComboBox->addItem( tr( "Default" ), QString() );
Expand Down Expand Up @@ -96,6 +97,7 @@ QgsCodeEditorOptionsWidget::QgsCodeEditorOptionsWidget( QWidget *parent )
for ( auto it = mColorButtonMap.constBegin(); it != mColorButtonMap.constEnd(); ++it )
{
it.value()->setColor( QgsCodeEditor::defaultColor( it.key(), theme ) );
it.value()->setDefaultColor( it.value()->color() );
}
mBlockCustomColorChange = false;
}
Expand Down

0 comments on commit 5e3214f

Please sign in to comment.