Release 2.8.17

This commit is contained in:
Yeison Cardona 2021-12-25 11:13:11 -05:00
parent 1d7a3a60da
commit 44b81a9115
30 changed files with 50 additions and 34 deletions

View File

@ -219,11 +219,11 @@ self.main.pushButton.setProperty('class', 'big_button')
A window with almost all widgets (see the previous screenshots) are available to test all themes and **create new ones**.
```
```python
git clone https://github.com/UN-GCPDS/qt-material.git
cd qt-material
python setup.py install
cd examples/full_features
cd test
python main.py --pyside6
```

Binary file not shown.

Before

Width:  |  Height:  |  Size: 959 KiB

After

Width:  |  Height:  |  Size: 2.2 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 MiB

After

Width:  |  Height:  |  Size: 1.0 MiB

View File

@ -196,7 +196,7 @@ There is an ``extra`` argument for accent colors and custom fonts.
'success': '#17a2b8',
# Font
'font-family': 'Roboto',
'font_family': 'Roboto',
}
apply_stylesheet(app, 'light_cyan.xml', invert_secondary=True, extra=extra)

View File

@ -175,11 +175,15 @@ if __name__ == "__main__":
pixmap.save(os.path.join('screenshots', f'{theme}.png'))
print(f'Saving {theme}')
try:
if len(sys.argv) > 2:
theme = sys.argv[2]
QTimer.singleShot(T0, take_screenshot)
QTimer.singleShot(T0 * 2, app.closeAllWindows)
except:
try:
QTimer.singleShot(T0, take_screenshot)
QTimer.singleShot(T0 * 2, app.closeAllWindows)
except:
QTimer.single_shot(T0, take_screenshot)
QTimer.single_shot(T0 * 2, app.closeAllWindows)
else:
theme = 'default'
# Set theme on in itialization
@ -189,7 +193,11 @@ if __name__ == "__main__":
extra=extra)
frame = RuntimeStylesheets()
frame.main.show()
try:
frame.main.showMaximized()
except:
frame.main.show_maximized()
if hasattr(app, 'exec'):
app.exec()

View File

@ -6,7 +6,7 @@
<rect>
<x>0</x>
<y>0</y>
<width>1318</width>
<width>1501</width>
<height>806</height>
</rect>
</property>
@ -21,7 +21,7 @@
<enum>QTabWidget::West</enum>
</property>
<property name="currentIndex">
<number>2</number>
<number>0</number>
</property>
<widget class="QWidget" name="tab_11">
<attribute name="title">
@ -835,7 +835,7 @@
<item row="0" column="0">
<widget class="QTabWidget" name="tabWidget">
<property name="currentIndex">
<number>3</number>
<number>0</number>
</property>
<property name="tabsClosable">
<bool>true</bool>
@ -1808,8 +1808,8 @@
<rect>
<x>0</x>
<y>0</y>
<width>446</width>
<height>266</height>
<width>96</width>
<height>26</height>
</rect>
</property>
<attribute name="label">
@ -1832,7 +1832,7 @@
<rect>
<x>0</x>
<y>0</y>
<width>425</width>
<width>404</width>
<height>328</height>
</rect>
</property>
@ -1878,7 +1878,7 @@
<rect>
<x>0</x>
<y>0</y>
<width>425</width>
<width>608</width>
<height>408</height>
</rect>
</property>
@ -2527,7 +2527,7 @@ Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor i
<rect>
<x>0</x>
<y>0</y>
<width>1318</width>
<width>1501</width>
<height>30</height>
</rect>
</property>
@ -2722,7 +2722,8 @@ Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor i
</action>
<action name="actionsubmenu">
<property name="icon">
<iconset theme="document-new"/>
<iconset theme="document-new">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="text">
<string>New...</string>
@ -2730,7 +2731,8 @@ Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor i
</action>
<action name="actionsubmenu_2">
<property name="icon">
<iconset theme="folder"/>
<iconset theme="folder">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="text">
<string>Open...</string>
@ -2738,7 +2740,8 @@ Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor i
</action>
<action name="actionsubmenu_3">
<property name="icon">
<iconset theme="document-save-as"/>
<iconset theme="document-save-as">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="text">
<string>Save as...</string>
@ -2746,7 +2749,8 @@ Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor i
</action>
<action name="actionsubmenu_4">
<property name="icon">
<iconset theme="document-save"/>
<iconset theme="document-save">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="text">
<string>Save</string>
@ -2759,7 +2763,8 @@ Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor i
</action>
<action name="actionClose">
<property name="icon">
<iconset theme="window-close"/>
<iconset theme="window-close">
<normaloff>.</normaloff>.</iconset>
</property>
<property name="text">
<string>Close</string>

View File

@ -1,11 +1,11 @@
<resources>
<color name="primaryColor">#00ff00</color>
<color name="primaryLightColor">#6effe8</color>
<color name="secondaryColor">#232629</color>
<color name="secondaryLightColor">#4f5b62</color>
<color name="secondaryDarkColor">#31363b</color>
<color name="primaryTextColor">#000000</color>
<color name="secondaryTextColor">#ffffff</color>
<color name="primaryColor">#ff4081</color>
<color name="primaryLightColor">#ff79b0</color>
<color name="secondaryColor">#f5f5f5</color>
<color name="secondaryLightColor">#ffffff</color>
<color name="secondaryDarkColor">#e6e6e6</color>
<color name="primaryTextColor">#3c3c3c</color>
<color name="secondaryTextColor">#555555</color>
</resources>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 959 KiB

After

Width:  |  Height:  |  Size: 2.2 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 165 KiB

After

Width:  |  Height:  |  Size: 184 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 165 KiB

After

Width:  |  Height:  |  Size: 185 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 166 KiB

After

Width:  |  Height:  |  Size: 186 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 164 KiB

After

Width:  |  Height:  |  Size: 184 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 164 KiB

After

Width:  |  Height:  |  Size: 184 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 165 KiB

After

Width:  |  Height:  |  Size: 185 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 160 KiB

After

Width:  |  Height:  |  Size: 181 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 163 KiB

After

Width:  |  Height:  |  Size: 184 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 166 KiB

After

Width:  |  Height:  |  Size: 186 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 MiB

After

Width:  |  Height:  |  Size: 1.0 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 158 KiB

After

Width:  |  Height:  |  Size: 175 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 160 KiB

After

Width:  |  Height:  |  Size: 177 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 155 KiB

After

Width:  |  Height:  |  Size: 172 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 161 KiB

After

Width:  |  Height:  |  Size: 178 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 163 KiB

After

Width:  |  Height:  |  Size: 180 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 160 KiB

After

Width:  |  Height:  |  Size: 176 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 155 KiB

After

Width:  |  Height:  |  Size: 174 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 160 KiB

After

Width:  |  Height:  |  Size: 177 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 159 KiB

After

Width:  |  Height:  |  Size: 178 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 154 KiB

After

Width:  |  Height:  |  Size: 172 KiB

View File

@ -229,7 +229,10 @@ def apply_stylesheet(app, theme='', style=None, save_as=None, invert_secondary=F
with open(save_as, 'w') as file:
file.writelines(stylesheet)
return app.setStyleSheet(stylesheet)
try:
app.setStyleSheet(stylesheet)
except:
app.style_sheet = stylesheet
# ----------------------------------------------------------------------
@ -254,11 +257,11 @@ def density(value, density_scale, border=0, scale=1, density_interval=4):
if isinstance(value, str):
value = float(value.replace('px', ''))
density = (value + (density_interval * int(density_scale))
- (border * 2)) * scale
density = (value + (density_interval * int(density_scale)) -
(border * 2)) * scale
# if density < 4:
# density = 4
if density < 0:
density = 0
return density

View File

@ -9,7 +9,7 @@ os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='qt-material',
version='2.8.16',
version='2.8.17',
packages=['qt_material',
'qt_material.resources',
'qt_material.resources.source'],