[Gui][Mod]: uniform spin button step size to 5%
- as discussed here: https://github.com/FreeCAD/FreeCAD/pull/7103 we have different transparency spin button step sizes. This PR uniforms them all to 5%.
This commit is contained in:
@@ -26,7 +26,16 @@
|
||||
<string>Material</string>
|
||||
</property>
|
||||
<layout class="QGridLayout">
|
||||
<property name="margin">
|
||||
<property name="leftMargin">
|
||||
<number>9</number>
|
||||
</property>
|
||||
<property name="topMargin">
|
||||
<number>9</number>
|
||||
</property>
|
||||
<property name="rightMargin">
|
||||
<number>9</number>
|
||||
</property>
|
||||
<property name="bottomMargin">
|
||||
<number>9</number>
|
||||
</property>
|
||||
<property name="spacing">
|
||||
@@ -46,7 +55,7 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<item row="1" column="0">
|
||||
<widget class="QLabel" name="textLabel1">
|
||||
<property name="text">
|
||||
<string>Diffuse color:</string>
|
||||
@@ -93,7 +102,16 @@
|
||||
<property name="spacing">
|
||||
<number>6</number>
|
||||
</property>
|
||||
<property name="margin">
|
||||
<property name="leftMargin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="topMargin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="rightMargin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="bottomMargin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<item>
|
||||
@@ -124,11 +142,14 @@
|
||||
<property name="suffix">
|
||||
<string>%</string>
|
||||
</property>
|
||||
<property name="singleStep">
|
||||
<number>5</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
|
||||
@@ -53,7 +53,7 @@ using namespace Gui;
|
||||
|
||||
PROPERTY_SOURCE(Gui::ViewProviderGeometryObject, Gui::ViewProviderDragger)
|
||||
|
||||
const App::PropertyIntegerConstraint::Constraints intPercent = {0, 100, 1};
|
||||
const App::PropertyIntegerConstraint::Constraints intPercent = {0, 100, 5};
|
||||
|
||||
ViewProviderGeometryObject::ViewProviderGeometryObject()
|
||||
: pcBoundSwitch(nullptr)
|
||||
@@ -65,9 +65,9 @@ ViewProviderGeometryObject::ViewProviderGeometryObject()
|
||||
|
||||
if (randomColor){
|
||||
auto fMax = (float)RAND_MAX;
|
||||
r = (float)rand()/fMax;
|
||||
g = (float)rand()/fMax;
|
||||
b = (float)rand()/fMax;
|
||||
r = (float)rand() / fMax;
|
||||
g = (float)rand() / fMax;
|
||||
b = (float)rand() / fMax;
|
||||
}
|
||||
else {
|
||||
unsigned long shcol = hGrp->GetUnsigned("DefaultShapeColor", 3435973887UL); // light gray (204,204,204)
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -234,7 +234,7 @@ QIcon ViewProviderExport::getIcon() const
|
||||
|
||||
App::PropertyFloatConstraint::Constraints ViewProviderMesh::floatRange = {1.0f, 64.0f, 1.0f};
|
||||
App::PropertyFloatConstraint::Constraints ViewProviderMesh::angleRange = {0.0f, 180.0f, 1.0f};
|
||||
App::PropertyIntegerConstraint::Constraints ViewProviderMesh::intPercent = {0, 100, 1};
|
||||
App::PropertyIntegerConstraint::Constraints ViewProviderMesh::intPercent = {0, 100, 5};
|
||||
const char* ViewProviderMesh::LightingEnums[]= {"One side", "Two side", nullptr};
|
||||
|
||||
PROPERTY_SOURCE(MeshGui::ViewProviderMesh, Gui::ViewProviderGeometryObject)
|
||||
|
||||
@@ -96,7 +96,7 @@
|
||||
<number>100</number>
|
||||
</property>
|
||||
<property name="singleStep">
|
||||
<number>10</number>
|
||||
<number>5</number>
|
||||
</property>
|
||||
<property name="prefEntry" stdset="0">
|
||||
<cstring>DefaultShapeTransparency</cstring>
|
||||
|
||||
Reference in New Issue
Block a user