gui-utilities 1.1.1__tar.gz → 1.1.3__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of gui-utilities might be problematic. Click here for more details.

@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: gui_utilities
3
- Version: 1.1.1
3
+ Version: 1.1.3
4
4
  Summary: Librería de utilidades gráficas en PyQt6
5
5
  Author-email: Guido Iván Gross <grossguidoivan@gmail.com>
6
6
  Requires-Python: >=3.8
@@ -1,5 +1,5 @@
1
1
  from PyQt6.QtCore import Qt, QObject, QEvent, QSize
2
- from PyQt6.QtWidgets import QWidget, QVBoxLayout, QHBoxLayout, QLabel, QPushButton, QLineEdit, QComboBox, QDialog, QToolButton, QWidgetAction
2
+ from PyQt6.QtWidgets import QWidget, QVBoxLayout, QHBoxLayout, QLabel, QPushButton, QLineEdit, QComboBox, QDialog, QToolButton, QWidgetAction, QCheckBox
3
3
  from PyQt6.QtGui import QIcon
4
4
  import re
5
5
  import requests
@@ -353,6 +353,56 @@ def create_combo_box(
353
353
  change_color(-1)
354
354
  return combo_box
355
355
 
356
+ def create_checkbox(
357
+ text,
358
+ font_family = "Segoe UI",
359
+ font_size = 14,
360
+ font_color = "#ffffff",
361
+ background_color = "#1e1e1e",
362
+ padding = 15,
363
+ indicator_background_color = "#ffffff",
364
+ indicator_border_width = 1,
365
+ indicator_border_color = "#5c5c5c",
366
+ indicator_border_radius = 0,
367
+ hover_indicator_background_color = "#333333",
368
+ hover_indicator_border_width = 2,
369
+ hover_indicator_border_color = "#777777",
370
+ pressed_indicator_color = "#0078d7",
371
+ pressed_indicator_background_color = "#4a4a4a",
372
+ pressed_indicator_border_width = 2,
373
+ pressed_indicator_border_color = "#0078d7",
374
+ checked_indicator_color = "#0078d7"
375
+ ):
376
+ checkbox = QCheckBox(text)
377
+ style_sheet = f"""
378
+ QCheckBox {{
379
+ font-family: {font_family};
380
+ font-size: {font_size}px;
381
+ color: {font_color};
382
+ background-color: {background_color};
383
+ padding: {padding}px;
384
+ }}
385
+ QCheckBox::indicator {{
386
+ background-color: {indicator_background_color};
387
+ border: {indicator_border_width}px solid {indicator_border_color};
388
+ border-radius: {indicator_border_radius}px;
389
+ }}
390
+ QCheckBox::indicator:hover {{
391
+ background-color: {hover_indicator_background_color};
392
+ border: {hover_indicator_border_width}px solid {hover_indicator_border_color};
393
+ }}
394
+ QCheckBox::indicator:pressed {{
395
+ color: {pressed_indicator_color};
396
+ background-color: {pressed_indicator_background_color};
397
+ border: {pressed_indicator_border_width}px solid {pressed_indicator_border_color};
398
+ }}
399
+ QCheckBox::indicator:checked {{
400
+ color: {checked_indicator_color};
401
+ }}
402
+ """
403
+ checkbox.setStyleSheet(style_sheet)
404
+ return checkbox
405
+
356
406
  def create_information_message_box(
357
407
  text,
358
408
  top_margin = 25,
@@ -0,0 +1 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="white" viewBox="0 0 16 16"><path d="M13.822 3.322l-8.471 8.44a.75.75 0 01-1.06 0L1.535 8.982a.75.75 0 011.06-1.06l2.894 2.894 7.94-7.94a.75.75 0 011.06 0z"/></svg>
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: gui_utilities
3
- Version: 1.1.1
3
+ Version: 1.1.3
4
4
  Summary: Librería de utilidades gráficas en PyQt6
5
5
  Author-email: Guido Iván Gross <grossguidoivan@gmail.com>
6
6
  Requires-Python: >=3.8
@@ -7,6 +7,7 @@ gui_utilities.egg-info/SOURCES.txt
7
7
  gui_utilities.egg-info/dependency_links.txt
8
8
  gui_utilities.egg-info/requires.txt
9
9
  gui_utilities.egg-info/top_level.txt
10
+ gui_utilities/icons/check.svg
10
11
  gui_utilities/icons/focused_hide_text_icon.png
11
12
  gui_utilities/icons/focused_show_text_icon.png
12
13
  gui_utilities/icons/hide_text_icon.png
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "gui_utilities"
3
- version = "1.1.1"
3
+ version = "1.1.3"
4
4
  description = "Librería de utilidades gráficas en PyQt6"
5
5
  authors = [{name = "Guido Iván Gross", email = "grossguidoivan@gmail.com"}]
6
6
  requires-python = ">=3.8"
File without changes
File without changes
File without changes