selected color icon was no longer visible

preferencesAboutTextFull
Clément Fauconnier 4 years ago
parent 497e826476
commit 47446798d8
  1. 41
      resources/forms/mainWindow.ui
  2. 3
      src/board/UBBoardController.cpp

@ -370,7 +370,7 @@
<string>Eraser</string> <string>Eraser</string>
</property> </property>
<property name="toolTip"> <property name="toolTip">
<string>Smalle Eraser</string> <string>Small Eraser</string>
</property> </property>
</action> </action>
<action name="actionEraserMedium"> <action name="actionEraserMedium">
@ -407,51 +407,78 @@
</property> </property>
</action> </action>
<action name="actionColor0"> <action name="actionColor0">
<property name="checkable">
<bool>true</bool>
</property>
<property name="icon"> <property name="icon">
<iconset resource="../OpenBoard.qrc"> <iconset resource="../OpenBoard.qrc">
<normaloff>:/images/toolbar/color.png</normaloff>:/images/toolbar/color.png</iconset> <normaloff>:/images/toolbar/color.png</normaloff>:/images/toolbar/color.png</iconset>
</property> </property>
<property name="text"> <property name="text">
<string>Color</string> <string>Color0</string>
</property> </property>
<property name="toolTip"> <property name="toolTip">
<string>Color</string> <string>Color 1</string>
</property> </property>
</action> </action>
<action name="actionColor1"> <action name="actionColor1">
<property name="checkable">
<bool>true</bool>
</property>
<property name="icon"> <property name="icon">
<iconset resource="../OpenBoard.qrc"> <iconset resource="../OpenBoard.qrc">
<normaloff>:/images/toolbar/color.png</normaloff>:/images/toolbar/color.png</iconset> <normaloff>:/images/toolbar/color.png</normaloff>:/images/toolbar/color.png</iconset>
</property> </property>
<property name="text"> <property name="text">
<string>Color</string> <string>Color1</string>
</property>
<property name="toolTip">
<string>Color 2</string>
</property> </property>
</action> </action>
<action name="actionColor2"> <action name="actionColor2">
<property name="checkable">
<bool>true</bool>
</property>
<property name="icon"> <property name="icon">
<iconset resource="../OpenBoard.qrc"> <iconset resource="../OpenBoard.qrc">
<normaloff>:/images/toolbar/color.png</normaloff>:/images/toolbar/color.png</iconset> <normaloff>:/images/toolbar/color.png</normaloff>:/images/toolbar/color.png</iconset>
</property> </property>
<property name="text"> <property name="text">
<string>Color</string> <string>Color2</string>
</property>
<property name="toolTip">
<string>Color 3</string>
</property> </property>
</action> </action>
<action name="actionColor3"> <action name="actionColor3">
<property name="checkable">
<bool>true</bool>
</property>
<property name="icon"> <property name="icon">
<iconset resource="../OpenBoard.qrc"> <iconset resource="../OpenBoard.qrc">
<normaloff>:/images/toolbar/color.png</normaloff>:/images/toolbar/color.png</iconset> <normaloff>:/images/toolbar/color.png</normaloff>:/images/toolbar/color.png</iconset>
</property> </property>
<property name="text"> <property name="text">
<string>Color</string> <string>Color3</string>
</property>
<property name="toolTip">
<string>Color 4</string>
</property> </property>
</action> </action>
<action name="actionColor4"> <action name="actionColor4">
<property name="checkable">
<bool>true</bool>
</property>
<property name="icon"> <property name="icon">
<iconset resource="../OpenBoard.qrc"> <iconset resource="../OpenBoard.qrc">
<normaloff>:/images/toolbar/color.png</normaloff>:/images/toolbar/color.png</iconset> <normaloff>:/images/toolbar/color.png</normaloff>:/images/toolbar/color.png</iconset>
</property> </property>
<property name="text"> <property name="text">
<string>Color</string> <string>Color4</string>
</property>
<property name="toolTip">
<string>Color 5</string>
</property> </property>
</action> </action>
<action name="actionWebBack"> <action name="actionWebBack">

@ -319,11 +319,14 @@ void UBBoardController::setupToolbar()
connect(settings->appToolBarDisplayText, SIGNAL(changed(QVariant)), colorChoice, SLOT(displayText(QVariant))); connect(settings->appToolBarDisplayText, SIGNAL(changed(QVariant)), colorChoice, SLOT(displayText(QVariant)));
connect(colorChoice, SIGNAL(activated(int)), this, SLOT(setColorIndex(int))); connect(colorChoice, SIGNAL(activated(int)), this, SLOT(setColorIndex(int)));
connect(UBDrawingController::drawingController(), SIGNAL(colorIndexChanged(int)), colorChoice, SLOT(setCurrentIndex(int))); connect(UBDrawingController::drawingController(), SIGNAL(colorIndexChanged(int)), colorChoice, SLOT(setCurrentIndex(int)));
connect(UBDrawingController::drawingController(), SIGNAL(colorIndexChanged(int)), UBDrawingController::drawingController(), SIGNAL(colorPaletteChanged()));
connect(UBDrawingController::drawingController(), SIGNAL(colorPaletteChanged()), colorChoice, SLOT(colorPaletteChanged())); connect(UBDrawingController::drawingController(), SIGNAL(colorPaletteChanged()), colorChoice, SLOT(colorPaletteChanged()));
connect(UBDrawingController::drawingController(), SIGNAL(colorPaletteChanged()), this, SLOT(colorPaletteChanged())); connect(UBDrawingController::drawingController(), SIGNAL(colorPaletteChanged()), this, SLOT(colorPaletteChanged()));
colorChoice->displayText(QVariant(settings->appToolBarDisplayText->get().toBool())); colorChoice->displayText(QVariant(settings->appToolBarDisplayText->get().toBool()));
colorChoice->colorPaletteChanged(); colorChoice->colorPaletteChanged();
colorChoice->setCurrentIndex(settings->penColorIndex());
colorActions.at(settings->penColorIndex())->setChecked(true);
// Setup line width choice widget // Setup line width choice widget
QList<QAction *> lineWidthActions; QList<QAction *> lineWidthActions;

Loading…
Cancel
Save