From 8b6190eec517f8c30e0a7a5384aed8a45b80df06 Mon Sep 17 00:00:00 2001 From: sln Date: Wed, 20 Oct 2010 10:02:22 +0000 Subject: [PATCH] subControlRect() for editor of spin-box fixed; gap between editor and arrows --- src/Style/Style_Salome.cxx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Style/Style_Salome.cxx b/src/Style/Style_Salome.cxx index 990761b91..60870cf63 100644 --- a/src/Style/Style_Salome.cxx +++ b/src/Style/Style_Salome.cxx @@ -2049,7 +2049,9 @@ QRect Style_Salome::subControlRect( ComplexControl cc, const QStyleOptionComplex res.setWidth( h ); } else if ( sc==QStyle::SC_SpinBoxEditField ) { - res.setWidth( w-h ); + //res.setWidth( w-h ); + QRect arrowsRect = subControlRect( cc, opt, SC_SpinBoxUp, wid ); + res.setWidth( arrowsRect.x() - x ); res.setTopLeft( QPoint( res.x(), res.y()-SHADOW ) ); } break; -- 2.39.2