Skip to content

Commit

Permalink
Icon size in parts bin 32->42 . Icon size Inspector 32->80
Browse files Browse the repository at this point in the history
  • Loading branch information
KjellMorgenstern committed Jul 19, 2022
1 parent 4558d64 commit c5063d6
Show file tree
Hide file tree
Showing 8 changed files with 19 additions and 17 deletions.
3 changes: 0 additions & 3 deletions phoenixresources.qrc
Original file line number Diff line number Diff line change
Expand Up @@ -161,9 +161,6 @@
<file>resources/images/icons/zoomSliderPlus.png</file>
<file>resources/images/icons/zoomSliderPlusPressed.png</file>
<file>resources/images/icons/searchField.png</file>
<file>resources/images/icons/noicon.png</file>
<file>resources/images/icons/parts_plural_v3_plur.png</file>
<file>resources/images/icons/parts_plural_v3_sing.png</file>
<file>resources/images/icons/asterisk.png</file>
<file>resources/images/icons/partsBinCombinedMenu_icon.png</file>
<file>resources/images/icons/partsBinCombinedMenuPressed_icon.png</file>
Expand Down
Binary file removed resources/images/icons/noicon.png
Binary file not shown.
Binary file removed resources/images/icons/parts_plural_v3_plur.png
Binary file not shown.
Binary file removed resources/images/icons/parts_plural_v3_sing.png
Binary file not shown.
4 changes: 2 additions & 2 deletions resources/styles/fritzing.qss
Original file line number Diff line number Diff line change
Expand Up @@ -1566,8 +1566,8 @@ HtmlInfoView QScrollBar:vertical {

#iconFrame { /*background-color in the icon-row*/
background-color: #d9d9d9;
max-height: 34px;
min-height: 34px;
max-height: 82px;
min-height: 82px;
margin: 0px 0px 0px 5px;
padding: 0px;
}
Expand Down
7 changes: 4 additions & 3 deletions src/infoview/htmlinfoview.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ along with Fritzing. If not, see <http://www.gnu.org/licenses/>.

QPixmap * NoIcon = NULL;

const int HtmlInfoView::STANDARD_ICON_IMG_WIDTH = 32;
const int HtmlInfoView::STANDARD_ICON_IMG_HEIGHT = 32;
const int HtmlInfoView::STANDARD_ICON_IMG_WIDTH = 80;
const int HtmlInfoView::STANDARD_ICON_IMG_HEIGHT = 80;
const int IconSpace = 0;

static const int MaxSpinBoxWidth = 60;
Expand Down Expand Up @@ -177,7 +177,8 @@ void HtmlInfoView::init(bool tinyMode) {
/* Part Icons */

if (NoIcon == NULL) {
NoIcon = new QPixmap(":/resources/images/icons/noicon.png");
NoIcon = new QPixmap(STANDARD_ICON_IMG_WIDTH, STANDARD_ICON_IMG_HEIGHT);
NoIcon->fill(QColorConstants::White);
}

QFrame * iconFrame = new QFrame(mainFrame);
Expand Down
14 changes: 9 additions & 5 deletions src/partsbinpalette/svgiconwidget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,9 @@ const QColor SectionHeaderColor(80, 80, 80);

#define SELECTION_THICKNESS 2
#define HALF_SELECTION_THICKNESS 1
#define ICON_SIZE 32
#define SINGULAR_OFFSET 3
#define PLURAL_OFFSET 2
#define ICON_SIZE 42
#define SINGULAR_OFFSET 0
#define PLURAL_OFFSET 0

static QPixmap * PluralImage = nullptr;
static QPixmap * SingularImage = nullptr;
Expand Down Expand Up @@ -111,10 +111,14 @@ SvgIconWidget::SvgIconWidget(ModelPart * modelPart, ViewLayer::ViewID viewID, It

void SvgIconWidget::initNames() {
if (!PluralImage) {
PluralImage = new QPixmap(":/resources/images/icons/parts_plural_v3_plur.png");
int r = ICON_SIZE;
PluralImage = new QPixmap(r, r);
PluralImage->fill(QColorConstants::White);
}
if (!SingularImage) {
SingularImage = new QPixmap(":/resources/images/icons/parts_plural_v3_sing.png");
int r = ICON_SIZE;
SingularImage = new QPixmap(r, r);
SingularImage->fill(QColorConstants::White);
}
}

Expand Down
8 changes: 4 additions & 4 deletions src/utils/misc.h
Original file line number Diff line number Diff line change
Expand Up @@ -88,10 +88,10 @@ Qt::KeyboardModifier altOrMetaModifier();

static QRegExp IntegerFinder("\\d+");

static const int PartsBinHeightDefault = 240;
static const int PartsBinHeightDefault = 300;
static const int InfoViewHeightDefault = 220;
static const int InfoViewMinHeight = 50;
static const int DockWidthDefault = 300;
static const int DockHeightDefault = 50;
static const int InfoViewMinHeight = 100;
static const int DockWidthDefault = 360;


#endif

0 comments on commit c5063d6

Please sign in to comment.