use custom icons for checkboxes
This commit is contained in:
8
icons/myicons/rect-checked.svg
Normal file
8
icons/myicons/rect-checked.svg
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
<svg xmlns="http://www.w3.org/2000/svg" width="512" height="512" viewBox="0 0 16 16">
|
||||||
|
<rect x="1.5" y="1.5" width="13" height="13" rx="2"
|
||||||
|
style="fill:none;stroke-width:1;stroke:black;"/>
|
||||||
|
<path style="stroke-width: 2; stroke:black;fill:none;stroke-linecap:round;stroke-linejoin:round;"
|
||||||
|
d="M4,8 L6,10 L11,5"
|
||||||
|
transform="translate(0.5,0.5)"
|
||||||
|
/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 389 B |
4
icons/myicons/rect.svg
Normal file
4
icons/myicons/rect.svg
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
<svg xmlns="http://www.w3.org/2000/svg" width="512" height="512" viewBox="0 0 16 16">
|
||||||
|
<rect x="1.5" y="1.5" width="13" height="13" rx="2"
|
||||||
|
style="fill:none;stroke-width:1;stroke:black;"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 208 B |
@@ -67,9 +67,9 @@ class RAction():
|
|||||||
def _update_check_state(self):
|
def _update_check_state(self):
|
||||||
if self._action:
|
if self._action:
|
||||||
if self.checked:
|
if self.checked:
|
||||||
self._action.setIcon(Icon("icons/ionicons/checkbox-outline.svg"))
|
self._action.setIcon(Icon("icons/myicons/rect-checked.svg"))
|
||||||
else:
|
else:
|
||||||
self._action.setIcon(Icon("icons/ionicons/square-outline.svg"))
|
self._action.setIcon(Icon("icons/myicons/rect.svg"))
|
||||||
|
|
||||||
def set_label(self, label: str):
|
def set_label(self, label: str):
|
||||||
if self._action:
|
if self._action:
|
||||||
|
|||||||
Reference in New Issue
Block a user